cord-776 create build / runtime containers for autmation uservices
Change-Id: I246973192adef56a250ffe93a5f65fff488840c1
diff --git a/config-generator/Dockerfile b/config-generator/Dockerfile
index 917c8ab..58dc80a 100644
--- a/config-generator/Dockerfile
+++ b/config-generator/Dockerfile
@@ -11,27 +11,17 @@
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
## See the License for the specific language governing permissions and
## limitations under the License.
-FROM golang:alpine
-
+FROM golang:1.7-alpine
MAINTAINER Open Networking Laboratory <info@onlab.us>
-RUN apk --update add git
+RUN mkdir /service
-# install godep
WORKDIR /go
-RUN go get github.com/tools/godep
ADD . /go/src/gerrit.opencord.org/maas/config-generator
-
-# restore dependancies
-WORKDIR /go/src/gerrit.opencord.org/maas/config-generator
-RUN /go/bin/godep restore || true
-
-# generate the binary
-WORKDIR /go/
-RUN go install gerrit.opencord.org/maas/config-generator
+RUN go build -o /service/entry-point gerrit.opencord.org/maas/config-generator
# copy templates to the image
-COPY netconfig.tpl /go/
+COPY netconfig.tpl /service/netconfig.tpl
EXPOSE 1337
@@ -41,4 +31,5 @@
org.label-schema.vendor="Open Networking Laboratory" \
org.label-schema.schema-version="1.0"
-ENTRYPOINT ["/go/bin/config-generator"]
+WORKDIR /service
+ENTRYPOINT ["/service/entry-point"]