# Passage marketplace migration All the setup is based on Ubuntu OS ## Prerequisites - jq - sed - python3 ## Passage binary setup Clone passage repository and install binary ``` sh git clone https://github.com/envadiv/Passage3D.git cd Passage3D make install ``` verify passage binary is installed ``` sh passage version ``` create a new key and send few passage tokens. If you already has a created created, ignore this step. ``` sh passage keys add migration-key --keyring-backend test ``` After new key created. Send some PASG tokens to above address. ## Setting up contract migration environment Clone migration scripts ``` sh git clone https://github.com/aleem1314/cw-migration.git git fetch git checkout aleem/update-scripts cd cw-migration ``` ## setup python environment Install python3 if not installed Install python pip3 ```bash! python3 -m pip install --upgrade pip ``` Setup python virtual environment ```bash! pip3 install virtualenv virtualenv -p python3 .venv source .venv/bin/activate ``` Install all python dependencies ```sh pip3 install -r requirements.txt ``` ## setting up passage config NOTE: `chain-id` and `node` flags are set for passage mainnet. ``` sh passage config chain-id passage-2 passage config node https://rpc.passage.vitwit.com:443 passage config broadcast-mode block passage config output json passage config keyring-backend test # if your key is stored in os backend, then use os backend. ``` Confirm all the config parameters are correct ``` sh passage config ``` Verify valid keyring-backend is used ``` sh passage keys list ``` ## setting up source code path - Open contracts.json file verify all contract details. adminKey is the name of the contract admin key-name in the keyring. - Open passage/.env file and update PATH_TO_CONTRACTS and CURRENT_DIR. - In `passage/init_msgs/` Verify initial message content for all marketplace contracts. ## running migrations ``` sh ./migrate_all.sh 2>&1 | tee output.json ``` NOTE: Please don’t execute this script multiple times, as doing so could complicate resuming from previous failed state.