Update Dockerfile
Browse files- Dockerfile +2 -3
Dockerfile
CHANGED
|
@@ -1,7 +1,8 @@
|
|
| 1 |
FROM golang:alpine AS builder
|
| 2 |
WORKDIR /app
|
| 3 |
RUN apk add --no-cache git
|
| 4 |
-
RUN --mount=type=secret,id=GITHUB_REPO,required=true
|
|
|
|
| 5 |
# RUN git clone https://github.com/Rippanteq7/telerealm .
|
| 6 |
RUN go mod download
|
| 7 |
RUN CGO_ENABLED=0 GOOS=linux go build -o server main.go
|
|
@@ -10,7 +11,5 @@ FROM alpine:latest
|
|
| 10 |
WORKDIR /app
|
| 11 |
RUN apk --no-cache add ca-certificates
|
| 12 |
COPY --from=builder /app/server ./server
|
| 13 |
-
COPY --from=builder /app/postman_collection.json ./postman_collection.json
|
| 14 |
-
RUN sed -i 's/7777/7860/g' postman_collection.json
|
| 15 |
EXPOSE 7860
|
| 16 |
CMD ["./server"]
|
|
|
|
| 1 |
FROM golang:alpine AS builder
|
| 2 |
WORKDIR /app
|
| 3 |
RUN apk add --no-cache git
|
| 4 |
+
RUN --mount=type=secret,id=GITHUB_REPO,required=true \
|
| 5 |
+
git clone -b hf --single-branch $(cat /run/secrets/GITHUB_REPO) .
|
| 6 |
# RUN git clone https://github.com/Rippanteq7/telerealm .
|
| 7 |
RUN go mod download
|
| 8 |
RUN CGO_ENABLED=0 GOOS=linux go build -o server main.go
|
|
|
|
| 11 |
WORKDIR /app
|
| 12 |
RUN apk --no-cache add ca-certificates
|
| 13 |
COPY --from=builder /app/server ./server
|
|
|
|
|
|
|
| 14 |
EXPOSE 7860
|
| 15 |
CMD ["./server"]
|