Added docker-compose install.
Co-authored-by: jmhbnz <mail@jamesblair.net>
This commit is contained in:
committed by
Daljit Singh
parent
14bda35e09
commit
7eea9bb11b
@ -11,3 +11,8 @@ export gcp_machine_name=$(gcloud compute instances list --limit=1 --format='valu
|
||||
|
||||
# Connect to the machine using ssh
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "curl -fsSL https://get.docker.com -o get-docker.sh && sudo sh get-docker.sh"
|
||||
|
||||
# Install docker compose
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "sudo curl -L https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose"
|
||||
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "sudo chmod +x /usr/local/bin/docker-compose"
|
||||
|
||||
@ -1,7 +1,9 @@
|
||||
#!/bin/bash
|
||||
# Step 5 - Teardown cloud resources
|
||||
|
||||
# The Google Cloud Platform resources created by this process come at a cost, so it's important we have an easy way to teardown those resources as soon as we're finished with them.
|
||||
# The Google Cloud Platform resources created by this process come at a cost, so it's important we have an easy way to teardown those resources as soon as we're finished with them!
|
||||
|
||||
# The script below will delete any projects containing ~gitlab~ in the name along with any compute instances running in those projects.
|
||||
|
||||
# Tangle the shell block below to a shell script by pressing *, b t* in emacs command mode:
|
||||
|
||||
|
||||
@ -99,6 +99,11 @@ export gcp_machine_name=$(gcloud compute instances list --limit=1 --format='valu
|
||||
|
||||
# Connect to the machine using ssh
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "curl -fsSL https://get.docker.com -o get-docker.sh && sudo sh get-docker.sh"
|
||||
|
||||
# Install docker compose
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "sudo curl -L https://github.com/docker/compose/releases/download/1.27.4/docker-compose-$(uname -s)-$(uname -m) -o /usr/local/bin/docker-compose"
|
||||
|
||||
gcloud compute ssh $gcp_machine_name --ssh-key-file ~/.ssh/$USER -- "sudo chmod +x /usr/local/bin/docker-compose"
|
||||
#+end_src
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user