- Clone this repo
- Install terraform
- Install doctl
- Run
terraform init
in this repo. This will initialize Terraform and get us ready to run Terraform plans. - Run
doctl auth init
to login to DigitalOcean. This will get us ready to pull data from DigitalOcean. - Get an API token from your DigitalOcean account from https://cloud.digitalocean.com/account/api/tokens
- Set it to
DIGITALOCEAN_TOKEN
in your terminal environment withexport DIGITALOCEAN_TOKEN=<your token>
. This will be used by Terraform. - Run
terraform plan -out plan.tfplan
to plan this Terraform application. - Run
terraform apply "plan.tfplan"
to apply this to your DigitalOcean account. This will launch a K8s cluster, a Postgres DB, and a Redis DB. This can take a long time to run. Note the Postgres and Redis databases are just for show, nothing is setup to use them. - Run
doctl kubernetes cluster kubeconfig save dcsil-cluster
to download the kubernetes config for the cluster we just launched (named dcsil-cluster). - Run
./launch.sh
to launch nginx/load balancers on your Kubernetes Cluster. This script will set up a DCSIL namespace, then launch our nginx application on Kubernetes. Next it will launch a LoadBalancer that is set up to serve data from any apps with the label "nginx". This script can take a while to run. - Go to the IP Address the script prints out. This should show the nginx page.
This repository has been archived by the owner on Mar 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
dcsil/do_terraform
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published