forked from TrueCloudLab/frostfs-dev-env
[#208] Download contracts and neofs-adm
These artifacts are required for environment deploy. Signed-off-by: Alex Vanin <a.vanin@yadro.com>
This commit is contained in:
parent
dff6b86f96
commit
8c6f321e5f
2 changed files with 41 additions and 0 deletions
10
.env
10
.env
|
@ -43,3 +43,13 @@ LOCODE_DB_URL=https://github.com/nspcc-dev/neofs-locode-db/releases/download/v0.
|
||||||
# NeoFS CLI binary
|
# NeoFS CLI binary
|
||||||
NEOFS_CLI_URL=https://github.com/nspcc-dev/neofs-node/releases/download/v0.31.0/neofs-cli-amd64.tar.gz
|
NEOFS_CLI_URL=https://github.com/nspcc-dev/neofs-node/releases/download/v0.31.0/neofs-cli-amd64.tar.gz
|
||||||
#NEOFS_CLI_PATH=/path/to/neofs-cli-binary
|
#NEOFS_CLI_PATH=/path/to/neofs-cli-binary
|
||||||
|
|
||||||
|
# NeoFS ADM tool binary
|
||||||
|
NEOFS_ADM_VERSION=v0.31.0
|
||||||
|
NEOFS_ADM_URL=https://github.com/nspcc-dev/neofs-node/releases/download/${NEOFS_ADM_VERSION}/neofs-adm-amd64.tar.gz
|
||||||
|
#NEOFS_ADM_PATH=/path/to/neofs-adm
|
||||||
|
|
||||||
|
# Compiled NeoFS Smart Contracts
|
||||||
|
NEOFS_CONTRACTS_VERSION=v0.15.5
|
||||||
|
NEOFS_CONTRACTS_URL=https://github.com/nspcc-dev/neofs-contract/releases/download/${NEOFS_CONTRACTS_VERSION}/neofs-contract-${NEOFS_CONTRACTS_VERSION}.tar.gz
|
||||||
|
#NEOFS_CONTRACTS_PATH=/path/to/neofs-contracts
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
# Download NeoFS sidechain dump with pre-deployed NeoFS contracts
|
# Download NeoFS sidechain dump with pre-deployed NeoFS contracts
|
||||||
|
get.morph_chain: get.contracts get.adm
|
||||||
get.morph_chain: MORPH_CHAIN_DUMP_NAME=neo.morph.dump.
|
get.morph_chain: MORPH_CHAIN_DUMP_NAME=neo.morph.dump.
|
||||||
get.morph_chain: MORPH_CHAIN_PATH?=
|
get.morph_chain: MORPH_CHAIN_PATH?=
|
||||||
get.morph_chain:
|
get.morph_chain:
|
||||||
|
@ -13,3 +14,33 @@ else
|
||||||
@echo "⇒ Copy local archive ${MORPH_CHAIN_PATH}"
|
@echo "⇒ Copy local archive ${MORPH_CHAIN_PATH}"
|
||||||
@cp ${MORPH_CHAIN_PATH} ./vendor/morph_chain.gz
|
@cp ${MORPH_CHAIN_PATH} ./vendor/morph_chain.gz
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
get.contracts: NEOFS_CONTRACTS_DEST=./vendor/contracts
|
||||||
|
get.contracts: NEOFS_CONTRACTS_ARCHIVE=neofs-contracts.tar.gz
|
||||||
|
get.contracts:
|
||||||
|
@mkdir -p ${NEOFS_CONTRACTS_DEST}
|
||||||
|
|
||||||
|
ifeq (${NEOFS_CONTRACTS_PATH},)
|
||||||
|
@echo "⇒ Download compiled NeoFS contracts from ${NEOFS_CONTRACTS_URL}"
|
||||||
|
@curl -sSL ${NEOFS_CONTRACTS_URL} -o ${NEOFS_CONTRACTS_ARCHIVE}
|
||||||
|
@tar -xf ${NEOFS_CONTRACTS_ARCHIVE} -C ${NEOFS_CONTRACTS_DEST} --strip-components 1
|
||||||
|
@rm ${NEOFS_CONTRACTS_ARCHIVE}
|
||||||
|
else
|
||||||
|
@echo "⇒ Copy compiled contracts from ${NEOFS_CONTRACTS_PATH}"
|
||||||
|
@cp -r ${NEOFS_CONTRACTS_PATH} ${NEOFS_CONTRACTS_DEST}
|
||||||
|
endif
|
||||||
|
|
||||||
|
get.adm: NEOFS_ADM_DEST=./vendor/neofs-adm
|
||||||
|
get.adm: NEOFS_ADM_ARCHIVE=neofs-adm.tar.gz
|
||||||
|
get.adm:
|
||||||
|
|
||||||
|
ifeq (${NEOFS_ADM_PATH},)
|
||||||
|
@echo "⇒ Download NeoFS ADM binary from ${NEOFS_ADM_URL}"
|
||||||
|
@curl -sSL ${NEOFS_ADM_URL} -o ${NEOFS_ADM_ARCHIVE}
|
||||||
|
@tar -xvf ${NEOFS_ADM_ARCHIVE} -C ./vendor | xargs -I {} \
|
||||||
|
mv ./vendor/{} ${NEOFS_ADM_DEST}
|
||||||
|
@rm ${NEOFS_ADM_ARCHIVE}
|
||||||
|
else
|
||||||
|
@echo "⇒ Copy neofs-adm binary from ${NEOFS_ADM_PATH}"
|
||||||
|
@cp ${NEOFS_ADM_PATH} ${NEOFS_ADM_DEST}
|
||||||
|
endif
|
||||||
|
|
Loading…
Reference in a new issue