Skip to content

Commit

Permalink
feat(image): Building project as a container image.
Browse files Browse the repository at this point in the history
  • Loading branch information
otaviof committed Oct 30, 2019
1 parent 0b950e4 commit 551438e
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .dockerignore
@@ -0,0 +1,9 @@
.*
_output/
docs/
examples/
images/
*.md
AUTHORS
LICENSE
OWNERS
23 changes: 23 additions & 0 deletions Dockerfile
@@ -0,0 +1,23 @@
FROM openshift/origin-release:golang-1.13 AS builder

ENV S2I_GIT_VERSION="" \
S2I_GIT_MAJOR="" \
S2I_GIT_MINOR=""

ENV GOARCH="amd64"

COPY . $GOPATH/src/github.com/openshift/source-to-image

RUN cd $GOPATH/src/github.com/openshift/source-to-image && \
make && \
install _output/local/bin/linux/${GOARCH}/s2i /usr/local/bin

#
# Runner Image
#

FROM registry.redhat.io/ubi8/ubi

COPY --from=builder /usr/local/bin/s2i /usr/local/bin

ENTRYPOINT [ "/usr/local/bin/s2i" ]

0 comments on commit 551438e

Please sign in to comment.