resolve issues with release action

This commit is contained in:
Casey Lee 2019-02-07 09:50:30 -08:00
parent 7b012832b4
commit de62a2eece
No known key found for this signature in database
GPG key ID: 1899120ECD0A1784
4 changed files with 29 additions and 1 deletions

12
.github/actions/integration/Dockerfile vendored Normal file
View file

@ -0,0 +1,12 @@
FROM golangci/golangci-lint:v1.12.5
LABEL "com.github.actions.name"="Check"
LABEL "com.github.actions.description"="Run integration tests"
LABEL "com.github.actions.icon"="check-circle"
LABEL "com.github.actions.color"="green"
COPY "entrypoint.sh" "/entrypoint.sh"
RUN chmod +x /entrypoint.sh
ENV GOFLAGS -mod=vendor
ENTRYPOINT ["/entrypoint.sh"]

View file

@ -0,0 +1,3 @@
#!/bin/sh
set -e
go test -cover ./actions

13
.github/main.workflow vendored
View file

@ -33,3 +33,16 @@ action "vendor" {
uses = "docker://golang:1.11.4"
args = "go mod vendor"
}
action "integration-tests" {
needs = ["check"]
uses = "./.github/actions/integration"
}
# local release
action "local-release" {
needs = ["integration-tests"]
uses = "docker://goreleaser/goreleaser:v0.98"
args = "release"
secrets = ["GITHUB_TOKEN"]
}

View file

@ -25,7 +25,7 @@ build: check
$(ACT) -ra build
release:
$(ACT) -ra release
$(ACT) -ra local-release
install: build
@cp dist/$(shell go env GOOS)_$(shell go env GOARCH)/act /usr/local/bin/act