From bf160a071e660d7144ca64bacf0ebd6f9fbaf3f9 Mon Sep 17 00:00:00 2001 From: Paramtamtam <7326800+tarampampam@users.noreply.github.com> Date: Tue, 20 Jul 2021 15:03:19 +0500 Subject: [PATCH] Update CI --- .github/workflows/release.yml | 19 +++++++++++++------ .github/workflows/tests.yml | 1 + 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 03a7b4d..2b16e66 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -12,11 +12,18 @@ jobs: - name: Check out code uses: actions/checkout@v2 - - name: Docker login in default registry - run: echo "${{ secrets.DOCKER_PASSWORD }}" | docker login -u "${{ secrets.DOCKER_LOGIN }}" --password-stdin &> /dev/null + - name: Login to default Container Registry + uses: docker/login-action@v1 # Action page: + with: + username: ${{ secrets.DOCKER_LOGIN }} + password: ${{ secrets.DOCKER_PASSWORD }} - - name: Docker login in ghcr.io # Auth docs: - run: echo "${{ secrets.GHCR_PASSWORD }}" | docker login ghcr.io -u tarampampam --password-stdin + - name: Login to GitHub Container Registry + uses: docker/login-action@v1 # Action page: + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GHCR_PASSWORD }} - name: Generate image tag value id: tag @@ -27,8 +34,8 @@ jobs: docker build \ --tag "tarampampam/3proxy:${{ steps.tag.outputs.value }}" \ --tag "tarampampam/3proxy:latest" \ - --tag "ghcr.io/tarampampam/3proxy:${{ steps.tag.outputs.value }}" \ - --tag "ghcr.io/tarampampam/3proxy:latest" \ + --tag "ghcr.io/${{ github.actor }}/3proxy:${{ steps.tag.outputs.value }}" \ + --tag "ghcr.io/${{ github.actor }}/3proxy:latest" \ -f ./Dockerfile . - name: Push into default registry diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f65ea30..3d36b8e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -34,6 +34,7 @@ jobs: # Docs: with: name: docker-image path: ./docker-image.tar + retention-days: 1 try-to-use: name: Build and use docker image (auth ${{ matrix.auth }})