Skip to content

Commit dceb49c

Browse files
committed
Do the things in the build
1 parent f5049c2 commit dceb49c

File tree

3 files changed

+15
-5
lines changed

3 files changed

+15
-5
lines changed

.github/workflows/platform-docker-publish-all-features-image.yml

+1-5
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,6 @@ jobs:
9898
username: ${{ secrets.DOCKERHUB_USERNAME }}
9999
password: ${{ secrets.DOCKERHUB_TOKEN }}
100100

101-
- name: Git credentials
102-
run: |
103-
echo "https://${{ secrets.GH_PRIVATE_ACCESS_TOKEN }}:@github.com" > $HOME/.git-credentials
104-
git config --global credential.helper store
105-
106101
- name: Build and push images
107102
id: docker_build
108103
uses: docker/build-push-action@v3
@@ -115,3 +110,4 @@ jobs:
115110
build-args: |
116111
SAML_INSTALLED=1
117112
POETRY_OPTS=--with saml,auth-controller,ldap
113+
GH_TOKEN=${{ secrets.GH_PRIVATE_ACCESS_TOKEN }}

Dockerfile

+7
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,13 @@ ARG POETRY_VIRTUALENVS_CREATE=false
2828
RUN make install-poetry
2929
ENV PATH="$PATH:/root/.local/bin"
3030

31+
ARG GH_TOKEN
32+
RUN if [ -z "${GH_TOKEN}" ]; \
33+
then echo "https://${GH_TOKEN}:@github.com" > ${HOME}/.git-credentials \
34+
&& git config --global credential.helper store \
35+
&& python -m pip install . \
36+
&& rm -rf ${HOME}/.git-credentials; fi;
37+
3138
ARG POETRY_OPTS
3239
RUN make install-packages opts="${POETRY_OPTS}"
3340

api/Dockerfile

+7
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,13 @@ ARG POETRY_VIRTUALENVS_CREATE=false
99
RUN make install-poetry
1010
ENV PATH="$PATH:/root/.local/bin"
1111

12+
ARG GH_TOKEN
13+
RUN if [ -z "${GH_TOKEN}" ]; \
14+
then echo "https://${GH_TOKEN}:@github.com" > ${HOME}/.git-credentials \
15+
&& git config --global credential.helper store \
16+
&& python -m pip install . \
17+
&& rm -rf ${HOME}/.git-credentials; fi;
18+
1219
ARG POETRY_OPTS
1320
RUN make install-packages opts="${POETRY_OPTS}"
1421

0 commit comments

Comments
 (0)