From 339289008529e8f243a90a79c703e8f8be7873f5 Mon Sep 17 00:00:00 2001 From: Arnfinn Hykkerud Steindal Date: Thu, 10 Oct 2024 13:57:41 +0200 Subject: [PATCH] Mat inn GITHUB_PAT slik at dev-kontainere kan laste ned pakker fra github (#104) Sender inn organisasjonshemmeligheten GH_TOKEN, som er en token uten rettigheter. GH_TOKEN ble samtidig oppdatert. --- .github/workflows/docker.yml | 2 ++ ablanor-dev/Dockerfile | 4 ++-- code-server/Dockerfile | 4 ++-- deformitet-dev/Dockerfile | 4 ++-- muskel-dev/Dockerfile | 4 ++-- nnrr-dev/Dockerfile | 4 ++-- norgast-dev/Dockerfile | 4 ++-- norspis-dev/Dockerfile | 4 ++-- nra-dev/Dockerfile | 4 ++-- pilot-dev/Dockerfile | 4 ++-- rapregtemplate-dev/Dockerfile | 4 ++-- 11 files changed, 22 insertions(+), 20 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index 95e5a56..4ba0612 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -88,5 +88,7 @@ jobs: push: ${{ github.event_name != 'pull_request' }} tags: ${{ steps.docker_meta.outputs.tags }} labels: ${{ steps.docker_meta.outputs.labels }} + build-args: | + GITHUB_PAT=${{ secrets.GH_TOKEN }} cache-from: type=gha cache-to: type=gha,mode=max diff --git a/ablanor-dev/Dockerfile b/ablanor-dev/Dockerfile index 297efd0..60cee7f 100644 --- a/ablanor-dev/Dockerfile +++ b/ablanor-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer="Arnfinn Hykkerud Steindal " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} COPY --chown=rstudio:rstudio db.yml /home/rstudio/ RUN cat /home/rstudio/db.yml >> /home/rstudio/dbConfig.yml \ diff --git a/code-server/Dockerfile b/code-server/Dockerfile index 435141c..0b29e21 100644 --- a/code-server/Dockerfile +++ b/code-server/Dockerfile @@ -2,8 +2,8 @@ FROM codercom/code-server:4.21.1 WORKDIR /home/coder -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} USER root diff --git a/deformitet-dev/Dockerfile b/deformitet-dev/Dockerfile index fb6e876..d43334e 100644 --- a/deformitet-dev/Dockerfile +++ b/deformitet-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer "Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/muskel-dev/Dockerfile b/muskel-dev/Dockerfile index 6688ddb..440ed4d 100644 --- a/muskel-dev/Dockerfile +++ b/muskel-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer="Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/nnrr-dev/Dockerfile b/nnrr-dev/Dockerfile index 4125816..16ce084 100644 --- a/nnrr-dev/Dockerfile +++ b/nnrr-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer = "Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/norgast-dev/Dockerfile b/norgast-dev/Dockerfile index 4428c95..798b70f 100644 --- a/norgast-dev/Dockerfile +++ b/norgast-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer "Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/norspis-dev/Dockerfile b/norspis-dev/Dockerfile index 6f198e8..9824e60 100644 --- a/norspis-dev/Dockerfile +++ b/norspis-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer="Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/nra-dev/Dockerfile b/nra-dev/Dockerfile index 669dcbd..689bf05 100644 --- a/nra-dev/Dockerfile +++ b/nra-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer = "Kevin Thon " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/ diff --git a/pilot-dev/Dockerfile b/pilot-dev/Dockerfile index 0853a31..87c1932 100644 --- a/pilot-dev/Dockerfile +++ b/pilot-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer="Arnfinn Hykkerud Steindal " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} RUN R -e "remotes::install_github(c('Rapporteket/rapbase', 'Rapporteket/rapFigurer', \ 'Rapporteket/pilot'))" diff --git a/rapregtemplate-dev/Dockerfile b/rapregtemplate-dev/Dockerfile index 460341c..dad8ac2 100644 --- a/rapregtemplate-dev/Dockerfile +++ b/rapregtemplate-dev/Dockerfile @@ -2,8 +2,8 @@ FROM rapporteket/dev:weekly LABEL maintainer="Arnfinn Hykkerud Steindal " -ARG GH_PAT -ENV GITHUB_PAT=${GH_PAT} +ARG GITHUB_PAT +ENV GITHUB_PAT=${GITHUB_PAT} # add registry dev config and R pkg dependencies COPY --chown=rstudio:rstudio db.yml /home/rstudio/rap_config/