Skip to content

Commit

Permalink
remove change directory in the script
Browse files Browse the repository at this point in the history
  • Loading branch information
yuetloo committed Jan 2, 2024
1 parent 1ba175e commit 4930f8d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions contracts/sh/upload-tally.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,14 @@ set -e


# Upload the tally.json file in the contracts directory to IPFS
# Run the script in the contracts directory as follow:
#
# Usage: ./upload-tally.sh
# sh/upload-tally.sh
#
# Make sure the PINATA_JWT secret is set in the AWS secrets manager
# aws scretsmanager create-secret --name PINATA_JWT --secret-string "SECRET_VALUE"
#

CONTRACTS_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && cd .. && pwd )

cd $CONTRACT_DIR
PINATA_JWT=$(aws secretsmanager get-secret-value --secret-id PINATA_JWT | jq -r '.SecretString')
curl --location --request POST 'https://api.pinata.cloud/pinning/pinFileToIPFS' \
--header "Authorization: Bearer ${PINATA_JWT}" \
Expand Down

0 comments on commit 4930f8d

Please sign in to comment.