Skip to content

Commit f8302ec

Browse files
fix: clone repo from GH action to avoid unwanted caching
1 parent 96e0f44 commit f8302ec

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.github/workflows/docker-image.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ jobs:
3535
username: ${{ github.actor }}
3636
password: ${{ secrets.GITHUB_TOKEN }}
3737

38+
- name: Clone repo to build
39+
run: git clone https://github.com/davidecavestro/gphotos-cdp.git repo
40+
3841
- name: Build and push image
3942
uses: docker/build-push-action@v5
4043
with:

Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
FROM golang:1.20.5-bullseye AS build
22

33
ENV GO111MODULE=on
4-
RUN git clone https://github.com/davidecavestro/gphotos-cdp.git /ws
5-
WORKDIR /ws
4+
COPY repo /repo
5+
WORKDIR /repo
66
RUN go build
77

88
FROM chromedp/headless-shell:latest
@@ -30,7 +30,7 @@ ENV LANGUAGE en_US:en
3030
ENV LC_ALL en_US.UTF-8
3131

3232
# copy tool binary
33-
COPY --from=build /ws/gphotos-cdp /usr/local/bin/
33+
COPY --from=build /repo/gphotos-cdp /usr/local/bin/
3434
# copy default script
3535
COPY save.sh /usr/local/bin/
3636

0 commit comments

Comments
 (0)