diff --git a/README.md b/README.md index 05ca099..94329d9 100644 --- a/README.md +++ b/README.md @@ -82,6 +82,7 @@ Option | Description `--local-nile-node` | Runs a node of the `nile` network and connects the node to the `nile` network. `--local-kovan-node` | Runs a light node of the `kovan` network and connects the node to the `kovan` network. `--reuse-ganache-database` | Configures a running `ganache` node to use a persistent database. +`--acl-contract` | Configures secret-store `acl_contract` option to enable secret-store authorization. `--purge` | Removes the containers, volumes, artifact folder and networks used by the script. ## Docker Building Blocks diff --git a/compose-files/secret_store.yml b/compose-files/secret_store.yml index 692873f..70d8a39 100644 --- a/compose-files/secret_store.yml +++ b/compose-files/secret_store.yml @@ -1,8 +1,10 @@ version: '2.1' services: secret-store: - image: oceanprotocol/parity-ethereum:master - entrypoint: /opt/parity/parity + image: oceanprotocol/parity-ethereum:acl_docker + entrypoint: /entrypoint.sh + environment: + CONFIGURE_ACL: "${CONFIGURE_ACL}" command: --config /etc/parity/secretstore/config.toml --jsonrpc-cors all @@ -14,6 +16,7 @@ services: - ../networks/secret-store/config/:/etc/parity/secretstore/ - secret-store:/secret-store/ - ../networks/secret-store/keys/:/secret-store/keys/secretstore/ + - ${KEEPER_ARTIFACTS_FOLDER}:/contracts ports: - 12000:12000 - 12001 diff --git a/start_ocean.sh b/start_ocean.sh index d0f0e12..df4bd50 100755 --- a/start_ocean.sh +++ b/start_ocean.sh @@ -28,6 +28,9 @@ export KEEPER_RPC_HOST='keeper-node' export KEEPER_RPC_PORT='8545' export KEEPER_RPC_URL="http://"${KEEPER_RPC_HOST}:${KEEPER_RPC_PORT} +# Enable acl-contract validation in Secret-store +export CONFIGURE_ACL="false" + # colors COLOR_R="\033[0;31m" # red COLOR_G="\033[0;32m" # green @@ -95,7 +98,14 @@ while :; do ################################################# --reuse-ganache-database) export GANACHE_REUSE_DATABASE="true" - printf $COLOR_Y'Starting and reusing the database ...\n\n'$COLOR_RESET + printf $COLOR_Y'Starting and reusing the database...\n\n'$COLOR_RESET + ;; + ################################################# + # Secret-Store validation switch + ################################################# + --acl-contract) + export CONFIGURE_ACL="true" + printf $COLOR_Y'Enabling acl validation in secret-store...\n\n'$COLOR_RESET ;; ################################################# # Node type switches