File tree Expand file tree Collapse file tree 2 files changed +23
-4
lines changed Expand file tree Collapse file tree 2 files changed +23
-4
lines changed Original file line number Diff line number Diff line change @@ -16,13 +16,32 @@ jobs:
16
16
uses : docker/setup-qemu-action@v2
17
17
- name : Set up Docker Buildx
18
18
uses : docker/setup-buildx-action@v2
19
+
19
20
- name : Login to Docker Hub
20
21
uses : docker/login-action@v2
21
22
with :
22
23
username : ${{ secrets.DOCKERHUB_USERNAME }}
23
24
password : ${{ secrets.DOCKERHUB_TOKEN }}
25
+
26
+ - name : Login to the GPR
27
+ uses : docker/login-action@v2
28
+ with :
29
+ registry : ghcr.io
30
+ username : ${{ github.repository_owner }}
31
+ password : ${{ secrets.GITHUB_TOKEN }}
32
+
24
33
- name : Build and push
25
34
uses : docker/build-push-action@v4
26
35
with :
36
+ platforms : linux/amd64
27
37
push : true
28
- tags : stulzq/azure-openai-proxy:${{ github.event.inputs.tags }}
38
+ pull : true
39
+ labels : |
40
+ org.opencontainers.image.source=${{ github.server_url }}/${{ github.repository }}
41
+ org.opencontainers.image.revision=${{ github.sha }}
42
+ org.opencontainers.image.licenses=Apache-2.0
43
+ tags : |
44
+ ${{ github.repository }}:${{ github.event.inputs.tags }}
45
+ # https://docs.docker.com/build/cache/backends/gha/
46
+ cache-from : type=gha
47
+ cache-to : type=gha,mode=max
Original file line number Diff line number Diff line change 1
1
FROM golang:1.19 AS building
2
2
3
- COPY . /building
4
- WORKDIR /building
3
+ COPY . /builder
4
+ WORKDIR /builder
5
5
6
6
RUN make build
7
7
@@ -10,6 +10,6 @@ FROM alpine:3
10
10
WORKDIR /app
11
11
12
12
EXPOSE 8080
13
- COPY --from=building /building /bin .
13
+ COPY --from=builder /builder /bin .
14
14
15
15
ENTRYPOINT ["/app/azure-openai-proxy" ]
You can’t perform that action at this time.
0 commit comments