Skip to content

Instantly share code, notes, and snippets.

@kaspernissen
Created January 10, 2019 13:03
Show Gist options
  • Save kaspernissen/dcf22cb9ca49edd306b28d2505f2bca1 to your computer and use it in GitHub Desktop.
Save kaspernissen/dcf22cb9ca49edd306b28d2505f2bca1 to your computer and use it in GitHub Desktop.
Simple example of a shuttle plan for Go.
scripts:
build:
description: Build the docker image
actions:
- shell: shuttle template -o Dockerfile Dockerfile.tmpl
- shell: docker build -f $tmp/Dockerfile -t $(shuttle get docker.destImage):$(shuttle get docker.destTag) .
push:
description: Push the docker image
actions:
- shell: docker push $(shuttle get docker.destImage):$(shuttle get docker.destTag)
test:
description: Run test for the project
actions:
- shell: go test
deploy:
description: Deploys the image to a kubernetes environment
actions:
- shell: shuttle template -o deployment.yaml deployment.tmpl
- shell: kubectl apply -f $tmp/deployment.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment