Prerequisites
- Install Docker (version 19.03.xx or higher)
- Install Docker Compose (version 1.25.5 or higher)
- AWS account
- AWS Profile
- Create an envfile '.env.dev' from the example '.env.dev.example'
- Chrome - Allows requests to localhost over HTTPS even when an invalid certificate is presented. `chrome://flags/#allow-insecure-localhost`
Spin DEV environment
Execute the following commands:make up
- Browse:
https://localhost:8443
Teardown DEV environment
Execute the following commands:./build/build.sh dev
source .env.dev
docker run --rm -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --action destroy
docker image prune -af
docker volume prune -f
Prerequisites
- Dockerhub account
- AWS account
- AWS Profile
- Terraform
- Docker
- Docker Compose
- AWS ~/.aws or %UserProfile%\.aws folder
- subnet ID
- Security Group with inbound ports for SSH (22), HTTP (80), HTTPS (443), and 8200
- AWS S3 Bucket
- Create an envfile '.env.stage' from the example '.env.stage.example'
Spin STAGE environment
Execute the following:
./build/build.sh stage
source .env.stage
terraform -chdir=deploy init
terraform -chdir=deploy apply --var-file=aws-stage.tfvars
docker run --rm -v $HOME/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT
- Locate the EC2 instance Public DNS: AWS Consule->EC2->Insance->Public DNS (IPv4)
- Browse
Teardown STAGE environment
Execute the following:
./build/build.sh stage
docker run --rm -v ~/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT --action destroy
docker image prune -af
Prerequisites
- Dockerhub account
- AWS account
- AWS Profile
- AWS ~/.aws or %UserProfile%\.aws folder
- keypair
- subnet ID
- Security Group with inbound ports for SSH (22), HTTP (80), HTTPS (443), and 8200
- AWS S3 Bucket
- Elastic IP Address (EIP)
- Create an envfile '.env.prod' from the example '.env.prod.example'
Teardown PROD environment
Execute the following:
./build/build.sh prod
source .env.prod
docker run --rm -v ~/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT --action destroy
docker image prune -af
Spin PROD environment
Execute the following:
./build/build.sh prod
terraform -chdir=deploy init
terraform apply -chdir=deploy --var-file=aws-prod.tfvars
docker run --rm -v $HOME/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT
- Browse www.devopsloft.org