Browse code

New release images locked to Go versions

Clayton Coleman authored on 2016/06/11 03:14:15
Showing 3 changed files
... ...
@@ -27,7 +27,7 @@ RUN mkdir $TMPDIR && \
27 27
 COPY openshift-origin-build.sh /usr/bin/openshift-origin-build.sh
28 28
 
29 29
 WORKDIR /go/src/github.com/openshift/origin
30
-LABEL io.k8s.display-name="OpenShift Origin Release Environment" \
30
+LABEL io.k8s.display-name="OpenShift Origin Release Environment (golang-$VERSION)" \
31 31
       io.k8s.description="This is the standard release image for OpenShift Origin and contains the necessary build tools to build the platform."
32 32
 
33 33
 # Expect a tar with the source of OpenShift Origin (and /os-version-defs in the root)
34 34
new file mode 100644
... ...
@@ -0,0 +1,34 @@
0
+#
1
+# This is the image that controls the standard build environment for releasing OpenShift Origin.
2
+# It is responsible for performing a cross platform build of OpenShift.
3
+#
4
+# The standard name for this image is openshift/origin-release
5
+#
6
+FROM openshift/origin-base
7
+
8
+ENV VERSION=1.4.2 \
9
+    GOARM=5 \
10
+    GOPATH=/go \
11
+    GOROOT=/usr/local/go \
12
+    OS_VERSION_FILE=/go/src/github.com/openshift/origin/os-version-defs \
13
+    TMPDIR=/openshifttmp
14
+ENV PATH=$PATH:$GOROOT/bin:$GOPATH/bin
15
+
16
+RUN mkdir $TMPDIR && \
17
+    INSTALL_PKGS="gcc zip mercurial" && \
18
+    yum install -y $INSTALL_PKGS && \
19
+    rpm -V $INSTALL_PKGS && \
20
+    yum clean all && \
21
+    curl https://storage.googleapis.com/golang/go$VERSION.linux-amd64.tar.gz | tar -C /usr/local -xzf - && \
22
+    go get golang.org/x/tools/cmd/cover github.com/tools/godep github.com/golang/lint/golint && \
23
+    touch /os-build-image
24
+
25
+# Allows building Origin sources mounted using volume
26
+COPY openshift-origin-build.sh /usr/bin/openshift-origin-build.sh
27
+
28
+WORKDIR /go/src/github.com/openshift/origin
29
+LABEL io.k8s.display-name="OpenShift Origin Release Environment (golang-$VERSION)" \
30
+      io.k8s.description="This is the standard release image for OpenShift Origin and contains the necessary build tools to build the platform."
31
+
32
+# Expect a tar with the source of OpenShift Origin (and /os-version-defs in the root)
33
+CMD hack/build-cross.sh
0 34
new file mode 100644
... ...
@@ -0,0 +1,34 @@
0
+#
1
+# This is the image that controls the standard build environment for releasing OpenShift Origin.
2
+# It is responsible for performing a cross platform build of OpenShift.
3
+#
4
+# The standard name for this image is openshift/origin-release
5
+#
6
+FROM openshift/origin-base
7
+
8
+ENV VERSION=1.6.2 \
9
+    GOARM=5 \
10
+    GOPATH=/go \
11
+    GOROOT=/usr/local/go \
12
+    OS_VERSION_FILE=/go/src/github.com/openshift/origin/os-version-defs \
13
+    TMPDIR=/openshifttmp
14
+ENV PATH=$PATH:$GOROOT/bin:$GOPATH/bin
15
+
16
+RUN mkdir $TMPDIR && \
17
+    INSTALL_PKGS="gcc zip mercurial" && \
18
+    yum install -y $INSTALL_PKGS && \
19
+    rpm -V $INSTALL_PKGS && \
20
+    yum clean all && \
21
+    curl https://storage.googleapis.com/golang/go$VERSION.linux-amd64.tar.gz | tar -C /usr/local -xzf - && \
22
+    go get golang.org/x/tools/cmd/cover github.com/tools/godep github.com/golang/lint/golint && \
23
+    touch /os-build-image
24
+
25
+# Allows building Origin sources mounted using volume
26
+COPY openshift-origin-build.sh /usr/bin/openshift-origin-build.sh
27
+
28
+WORKDIR /go/src/github.com/openshift/origin
29
+LABEL io.k8s.display-name="OpenShift Origin Release Environment (golang-$VERSION)" \
30
+      io.k8s.description="This is the standard release image for OpenShift Origin and contains the necessary build tools to build the platform."
31
+
32
+# Expect a tar with the source of OpenShift Origin (and /os-version-defs in the root)
33
+CMD bsdtar mxzf - && hack/build-cross.sh