Fix 0xorg/ganache-cli docker image not supporting re-runs (#2420)

* Overwrite existing snapshot when unzipping

* Don't re-download snapshot if it isn't updated

* Update CHANGELOG.json
This commit is contained in:
F. Eugene Aumson 2020-01-02 20:19:06 -05:00 committed by GitHub
parent 784d23ec87
commit 9d5724e1a0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -5,6 +5,10 @@
{ {
"note": "Added DydxBridge Contract to ContractAddresses", "note": "Added DydxBridge Contract to ContractAddresses",
"pr": 2401 "pr": 2401
},
{
"note": "Changed docker image command to overwrite any existing snapshot when unzipping the image downloaded from S3.",
"pr": 2420
} }
] ]
}, },

View File

@ -11,5 +11,5 @@ ENV SNAPSHOT_HOST "http://ganache-snapshots.0x.org.s3-website.us-east-2.amazonaw
ENV SNAPSHOT_NAME "0x_ganache_snapshot" ENV SNAPSHOT_NAME "0x_ganache_snapshot"
EXPOSE 8545 EXPOSE 8545
CMD [ "sh", "-c", "echo downloading snapshot version: $VERSION; wget $SNAPSHOT_HOST/$SNAPSHOT_NAME-$VERSION.zip -O snapshot.zip && unzip snapshot.zip && ganache-cli --gasLimit 10000000 --db $SNAPSHOT_NAME --noVMErrorsOnRPCResponse -p 8545 --keepAliveTimeout=40000 --networkId \"$NETWORK_ID\" -m \"$MNEMONIC\" -h 0.0.0.0"] CMD [ "sh", "-c", "echo downloading snapshot version: $VERSION; wget --timestamping $SNAPSHOT_HOST/$SNAPSHOT_NAME-$VERSION.zip -O snapshot.zip && unzip -o snapshot.zip && ganache-cli --gasLimit 10000000 --db $SNAPSHOT_NAME --noVMErrorsOnRPCResponse -p 8545 --keepAliveTimeout=40000 --networkId \"$NETWORK_ID\" -m \"$MNEMONIC\" -h 0.0.0.0"]