mirror of
https://github.com/stefanprodan/podinfo.git
synced 2026-03-04 19:10:26 +00:00
- add custom Dockerfile - use GitHub actions env vars as docker build args - remove .gh from Makefile and Dockerfile in destination project
36 lines
619 B
HCL
36 lines
619 B
HCL
workflow "Publish container" {
|
|
on = "push"
|
|
resolves = ["Push"]
|
|
}
|
|
|
|
action "Lint" {
|
|
uses = "./.github/actions/golang"
|
|
args = "fmt"
|
|
}
|
|
|
|
action "Test" {
|
|
needs = ["Lint"]
|
|
uses = "./.github/actions/golang"
|
|
args = "test"
|
|
}
|
|
|
|
action "Build" {
|
|
needs = ["Test"]
|
|
uses = "./.github/actions/docker"
|
|
secrets = ["DOCKER_IMAGE"]
|
|
args = ["build", "Dockerfile.gh"]
|
|
}
|
|
|
|
action "Login" {
|
|
needs = ["Build"]
|
|
uses = "actions/docker/login@master"
|
|
secrets = ["DOCKER_USERNAME", "DOCKER_PASSWORD"]
|
|
}
|
|
|
|
action "Push" {
|
|
needs = ["Login"]
|
|
uses = "./.github/actions/docker"
|
|
secrets = ["DOCKER_IMAGE"]
|
|
args = "push"
|
|
}
|