-
Notifications
You must be signed in to change notification settings - Fork 58
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Based docker build on alpine:edge image and included tests for the build
in the Dockerfile. Updated README.md to include developer and testing instructions. Removed old files and scripts for building and testing. Signed-off-by: Joris Melchior <jmelchior@pivotal.io>
- Loading branch information
Showing
6 changed files
with
50 additions
and
65 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,23 @@ | ||
FROM concourse/buildroot:base | ||
FROM golang:alpine as builder | ||
COPY . /go/src/github.com/concourse/github-release-resource | ||
ENV CGO_ENABLED 0 | ||
ENV GOPATH /go/src/github.com/concourse/github-release-resource/Godeps/_workspace:${GOPATH} | ||
ENV PATH /go/src/github.com/concourse/github-release-resource/Godeps/_workspace/bin:${PATH} | ||
RUN go build -o /assets/out github.com/concourse/github-release-resource/cmd/out | ||
RUN go build -o /assets/in github.com/concourse/github-release-resource/cmd/in | ||
RUN go build -o /assets/check github.com/concourse/github-release-resource/cmd/check | ||
RUN set -e; for pkg in $(go list ./...); do \ | ||
go test -o "/tests/$(basename $pkg).test" -c $pkg; \ | ||
done | ||
|
||
ADD assets/check /opt/resource/check | ||
ADD assets/in /opt/resource/in | ||
ADD assets/out /opt/resource/out | ||
FROM alpine:edge AS resource | ||
RUN apk add --update bash tzdata | ||
COPY --from=builder /assets /opt/resource | ||
|
||
FROM resource AS tests | ||
COPY --from=builder /tests /tests | ||
RUN set -e; for test in /tests/*.test; do \ | ||
$test; \ | ||
done | ||
|
||
FROM resource |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.