From 533e00853c6135a407ddfb87073210bb44d49ee1 Mon Sep 17 00:00:00 2001 From: Federico Stagni Date: Wed, 13 Mar 2024 15:17:02 +0100 Subject: [PATCH] checkoutv4 and github_token --- .github/workflows/images-creator.yml | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.github/workflows/images-creator.yml b/.github/workflows/images-creator.yml index 27fd796..c6d0b90 100644 --- a/.github/workflows/images-creator.yml +++ b/.github/workflows/images-creator.yml @@ -18,7 +18,7 @@ jobs: dirac-distribution: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: | echo $PWD @@ -36,7 +36,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/dirac-distribution:latest; docker push ghcr.io/diracgrid/management/dirac-distribution:latest; else @@ -47,7 +47,7 @@ jobs: docker-compose-dirac: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: docker build -t docker-compose-dirac docker-compose-dirac/ - name: tag @@ -62,7 +62,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/docker-compose-dirac:latest; docker push ghcr.io/diracgrid/management/docker-compose-dirac:latest; else @@ -72,7 +72,7 @@ jobs: el9-dirac: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: docker build -t el9-dirac el9-dirac/ - name: tag @@ -87,7 +87,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/el9-dirac:latest; docker push ghcr.io/diracgrid/management/el9-dirac:latest; else @@ -97,7 +97,7 @@ jobs: c8-dirac: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: docker build -t c8-dirac c8-dirac/ - name: tag @@ -112,7 +112,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/c8-dirac:latest; docker push ghcr.io/diracgrid/management/c8-dirac:latest; else @@ -122,7 +122,7 @@ jobs: cc7-dirac: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: docker build -t cc7-dirac cc7-dirac/ - name: tag @@ -137,7 +137,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/cc7-dirac:latest; docker push ghcr.io/diracgrid/management/cc7-dirac:latest; else @@ -148,7 +148,7 @@ jobs: dirac-cvmfs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: | echo $PWD @@ -166,7 +166,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/dirac-cvmfs:latest; docker push ghcr.io/diracgrid/management/dirac-cvmfs:latest; else @@ -177,7 +177,7 @@ jobs: centos6: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: build run: | echo $PWD @@ -195,7 +195,7 @@ jobs: run: | if [ ! -z ${deploy_secret} ]; then echo ${{ secrets.DOCKER_HUB_PASSWORD }} | docker login --username ${{ secrets.DOCKER_HUB_USERNAME }} --password-stdin; - echo ${{ secrets.CR_PAT }} | docker login ghcr.io --username ${{ github.actor }} --password-stdin; + echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin docker push diracgrid/centos6:latest; docker push ghcr.io/diracgrid/management/centos6:latest; else