-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
45 lines (24 loc) · 826 Bytes
/
Dockerfile
File metadata and controls
45 lines (24 loc) · 826 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Use an official Python runtime as a parent image
FROM golang:latest AS builder
LABEL maintainer="Vojtěch Hromádka<hromadkavojta@gmail.com>"
#RUN mkdir -p /go/src/app
#WORKDIR /go/src/app
WORKDIR /go/src/github.com/Harticon/gRPCproj
# Copy everything from present working dir
COPY . .
#Golang dependencies go get/go mod init
#RUN GO111MODULE=on go mod vendor
#WORKDIR /go/src/app/user/cmd/user
RUN CGO_ENABLED=0 GOOS=linux go install -a -installsuffix cgo ./user/cmd/user
#RUN ls
# Run app.py when the container launches
#ENTRYPOINT ["./grpcProj"]
# Make port 80 available to the world outside this container
#EXPOSE 8080
FROM alpine:latest
WORKDIR /go/bin
ENV PATH=/bin
COPY --from=builder /go/src/github.com/Harticon/gRPCproj/grpc.db .
COPY --from=builder /go/bin/user .
RUN ls
ENTRYPOINT ["./user"]