cd ~
sudo apt update
curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add -
sudo apt-add-repository "deb [arch=$(dpkg --print-architecture)] https://apt.releases.hashicorp.com $(lsb_release -cs) main"
sudo apt install terraform
sudo apt install ansible
git clone https://github.com/compound-finance/gateway.git
cd gateway/ops
Create an AWS account and also create an S3 bucket i.e. a new bucket called compound-gateway
.
Install the necessary AWS CLI software for your Ubuntu machine, so that you can authorize AWS when executing terraform commands.
sudo apt install python3-pip
pip3 install awscli
aws configure
The last command shown above will require that you input your AWS Access Key ID
, AWS Secret Access Key
, as well as Default region name
and Default output format
. These can all be obtained from security credentials section of your AWS account.
Please see this Terraform S3 backend config site for more information about configuration required.
terraform init -upgrade \
-backend-config="bucket=compound-gateway" \
-backend-config="key=tfstate" \
-backend-config="region=ap-southeast-2"
The output will be similar to the following