Skip to content

Instantly share code, notes, and snippets.

@jonmorehouse
Created December 9, 2022 19:22
Show Gist options
  • Save jonmorehouse/7458c559ee746b85b8c68c12500997ab to your computer and use it in GitHub Desktop.
Save jonmorehouse/7458c559ee746b85b8c68c12500997ab to your computer and use it in GitHub Desktop.
project = "13kd9sg15ereb28247anowbbek"
#
# thoughts:
# build config - public image, dockerfile or buildpack
# deploy config - select a "preset", use a private helm chart, use a public helm chart
# listener config - derived from the preset config (ie: has a probe path, listener port, domain stuff in the future)
#
#
# https://developer.hashicorp.com/waypoint/plugins/kubernetes
# this uses yaml-less k8s
app "httpbin" {
build {
use "docker-pull" {
image = "{{.InputImage}}"
tag = "{{.InputVersion}}"
}
registry {
use "aws-ecr" {
repository = "{{.OutputRepository}}"
tag = "{{.OutputVersion}}"
region = "us-west-2"
}
}
}
deploy {
use "kubernetes" {}
}
}
# https://developer.hashicorp.com/waypoint/plugins/pack
app "build-pack" {
build {
use "pack" {
builder = "heroku/buildpacks:20"
disable_entrypoint = false
registry {
use "aws-ecr" {
repository = "{{.OutputRepository}}"
tag = "{{.OutputVersion}}"
region = "us-west-2"
}
}
}
deploy {
use "kubernetes" {
service_port = 80
}
}
}
# https://developer.hashicorp.com/waypoint/plugins/helm
app "helm-chart" {
build {
use "docker" {}
registry {
use "docker" {
}
}
}
deploy {
use "helm" {
name = "foo-bar"
# NOTE: we can't support helm chart paths until we support "private" helm charts, because we don't want to ship
# actual source code into customer accounts.
chart = "https://your-helm-chart-somewhere.com"
set {
name = "image.repository"
value = artifact.image
}
set {
name = "image.tag"
value = artifact.tag
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment