Skip to content

Commit

Permalink
Merge pull request #305 from 0xPolygonHermez/feature/fix-build-docker
Browse files Browse the repository at this point in the history
fix build docker
  • Loading branch information
invocamanman authored Aug 2, 2024
2 parents 6e81fd5 + 30714da commit 1eeaff6
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
14 changes: 7 additions & 7 deletions docker/scripts/v2/deploy-docker.sh
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
#!/bin/bash
sudo rm -rf docker/gethData/geth_data
DEV_PERIOD=1 docker-compose -f docker/docker-compose.yml up -d geth
sudo DEV_PERIOD=1 docker-compose -f docker/docker-compose.yml up -d geth
sleep 5
node docker/scripts/fund-accounts.js
cp docker/scripts/v2/deploy_parameters_docker.json deployment/v2/deploy_parameters.json
cp docker/scripts/v2/create_rollup_parameters_docker.json deployment/v2/create_rollup_parameters.json
npm run deploy:testnet:v2:localhost
mkdir docker/deploymentOutput
mv deployment/v2/deploy_output.json docker/deploymentOutput
mv deployment/v2/genesis.json docker/deploymentOutput
mv deployment/v2/create_rollup_output.json docker/deploymentOutput
DEV_PERIOD=1 docker-compose -f docker/docker-compose.yml down
docker build -t hermeznetwork/geth-zkevm-contracts -f docker/Dockerfile .
sudo mv deployment/v2/deploy_output.json docker/deploymentOutput
sudo mv deployment/v2/genesis.json docker/deploymentOutput
sudo mv deployment/v2/create_rollup_output.json docker/deploymentOutput
sudo DEV_PERIOD=1 docker-compose -f docker/docker-compose.yml down
sudo docker build -t hermeznetwork/geth-zkevm-contracts -f docker/Dockerfile .
# Let it readable for the multiplatform build coming later!
sudo chmod -R go+rxw docker/gethData
sudo chmod -R go+rxw docker/gethData
12 changes: 6 additions & 6 deletions docker/scripts/v2/deploy-dockerv2.sh
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
#!/bin/bash
sudo rm -rf docker/gethData/geth_data
DEV_PERIOD=1 docker compose -f docker/docker-compose.yml up -d geth
sudo DEV_PERIOD=1 docker compose -f docker/docker-compose.yml up -d geth
sleep 5
node docker/scripts/fund-accounts.js
cp docker/scripts/v2/deploy_parameters_docker.json deployment/v2/deploy_parameters.json
cp docker/scripts/v2/create_rollup_parameters_docker.json deployment/v2/create_rollup_parameters.json
npm run deploy:testnet:v2:localhost
mkdir docker/deploymentOutput
mv deployment/v2/deploy_output.json docker/deploymentOutput
mv deployment/v2/genesis.json docker/deploymentOutput
mv deployment/v2/create_rollup_output.json docker/deploymentOutput
DEV_PERIOD=1 docker compose -f docker/docker-compose.yml down
docker build -t hermeznetwork/geth-zkevm-contracts -f docker/Dockerfile .
sudo mv deployment/v2/deploy_output.json docker/deploymentOutput
sudo mv deployment/v2/genesis.json docker/deploymentOutput
sudo mv deployment/v2/create_rollup_output.json docker/deploymentOutput
sudo DEV_PERIOD=1 docker compose -f docker/docker-compose.yml down
sudo docker build -t hermeznetwork/geth-zkevm-contracts -f docker/Dockerfile .
# Let it readable for the multiplatform build coming later!
sudo chmod -R go+rxw docker/gethData
2 changes: 1 addition & 1 deletion hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ const config: HardhatUserConfig = {
settings: {
optimizer: {
enabled: true,
runs: 500,
runs: 200,
},
evmVersion: "shanghai",
}, // try yul optimizer
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
"lint:fix": "npx eslint ./test --fix && npx eslint ./docker/scripts --fix && npx eslint ./deployment --fix && npx eslint ./src --fix",
"compile": "npx hardhat compile",
"docker:contracts": "./docker/scripts/v2/deploy-docker.sh",
"dockerv2:contracts": "sudo ./docker/scripts/v2/deploy-dockerv2.sh",
"dockerv2:contracts": "./docker/scripts/v2/deploy-dockerv2.sh",
"push:docker:contracts": "docker push hermeznetwork/geth-zkevm-contracts",
"update:genesis": "node deployment/1_createGenesis.js && node deployment/1_createGenesis.js --test --input ../docker/scripts/deploy_parameters_docker.json --out ../docker/scripts/genesis_docker.json",
"coverage": "npx hardhat coverage --testfiles \"test/contractsv2/*.ts\"",
Expand Down

0 comments on commit 1eeaff6

Please sign in to comment.