Compare commits
	
		
			No commits in common. "a23642af34d93d705b70d275c537c079a892c23c" and "7b340cc6f4ab4ac9bd688d906e6d139125d54e3e" have entirely different histories.
		
	
	
		
			a23642af34
			...
			7b340cc6f4
		
	
		|  | @ -1,4 +1,7 @@ | ||||||
| .vscode | .vscode | ||||||
| .git | .git | ||||||
|  | go.mod | ||||||
|  | go.sum | ||||||
|  | *.go | ||||||
| helm | helm | ||||||
| .*ignore | .*ignore | ||||||
|  |  | ||||||
							
								
								
									
										22
									
								
								Dockerfile
								
								
								
								
							
							
						
						
									
										22
									
								
								Dockerfile
								
								
								
								
							|  | @ -1,35 +1,19 @@ | ||||||
| FROM golang:1.18.5 as builder | FROM alpine:3.11.6 | ||||||
| 
 | 
 | ||||||
| ARG GOOS="linux" | ARG GOOS="linux" | ||||||
| ARG GOARCH="amd64" | ARG GOARCH="amd64" | ||||||
| 
 | 
 | ||||||
| WORKDIR /workspace |  | ||||||
| 
 |  | ||||||
| COPY go.mod go.sum /workspace/ |  | ||||||
| 
 |  | ||||||
| RUN go mod download |  | ||||||
| 
 |  | ||||||
| COPY . . |  | ||||||
| RUN CGO_ENABLED=0 go build -a -o hugo-mx-gateway |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| FROM alpine:3.16.2 |  | ||||||
| 
 |  | ||||||
| ARG RUNTIME_USER="mxgateway" | ARG RUNTIME_USER="mxgateway" | ||||||
| ARG RUNTIME_USER_UID=4583 | ARG RUNTIME_USER_UID=4583 | ||||||
| 
 | 
 | ||||||
| RUN apk update && apk add --no-cache ca-certificates |  | ||||||
| 
 |  | ||||||
| RUN addgroup -g $RUNTIME_USER_UID $RUNTIME_USER && \ | RUN addgroup -g $RUNTIME_USER_UID $RUNTIME_USER && \ | ||||||
|     adduser --disabled-password --no-create-home  --gecos "" \ |     adduser --disabled-password --no-create-home  --gecos "" \ | ||||||
|     --home /app --ingroup $RUNTIME_USER --uid $RUNTIME_USER_UID  $RUNTIME_USER |     --home /app --ingroup $RUNTIME_USER --uid $RUNTIME_USER_UID  $RUNTIME_USER | ||||||
| 
 | 
 | ||||||
| WORKDIR /app | COPY entrypoint.sh bin/hugo-mx-gateway  LICENSE /app/ | ||||||
| 
 |  | ||||||
| COPY --from=builder /workspace/hugo-mx-gateway . |  | ||||||
| COPY entrypoint.sh LICENSE /app/ |  | ||||||
| COPY templates /app/templates | COPY templates /app/templates | ||||||
| 
 | 
 | ||||||
| RUN chown -R $RUNTIME_USER:$RUNTIME_USER /app | RUN chown -R $RUNTIME_USER:$RUNTIME_USER /app | ||||||
| 
 | 
 | ||||||
|  | WORKDIR /app | ||||||
| ENTRYPOINT ["sh", "./entrypoint.sh"] | ENTRYPOINT ["sh", "./entrypoint.sh"] | ||||||
|  |  | ||||||
		Reference in New Issue