New-Mexico-Water-Resources / Water-Rights-Visualizer

New Mexico Water Rights Visualizer
1 stars 1 forks source link

Create configuration tool for new cloud formation deployments #57

Open scottdavidoff opened 3 weeks ago

scottdavidoff commented 3 weeks ago

Here are my notes on the configuration that we performed, that will need to be automated


#install docker-compose on ec2
sudo curl -L https://github.com/docker/compose/releases/latest/download/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose

#install git
sudo yum install git

# install app
git clone https://github.com/New-Mexico-Water-Resources/Water-Rights-Visualizer
# go into the downloaded code directory
cd Water-Rights-Visualizer
# build docker container
docker-compose build
# create data directory
mkdir -p /home/ec2-user/data/water_rights_runs
# set environment variables for docker container
export WATER_RIGHTS_SOURCE=S3
export HOST_DATA_DIRECTORY=/home/ec2-user/data
export CONTAINER_DATA_DIRECTORY=/root/data
# run the container
docker-compose up -d
# check that the docker container is running
docker ps
scottdavidoff commented 3 weeks ago

@pzimdars created this ticket to track the updates to the cloud formation that we learned from trying the clean install. We can leave this ticket in the todo list until we get ready to ask you to prep the next release of the cloud formation template. Let's hold off on that while we figure out if we need to update the app's architecture