From 770e568c816813c2b0079b02e0257d08920f098a Mon Sep 17 00:00:00 2001 From: Aditya Prima Date: Sat, 23 Mar 2024 20:34:24 +0700 Subject: [PATCH] Added dockerio workflow --- .gitea/workflows/ubuntu-dockerio.yaml | 124 ++++++++++++++++++ .../{ubuntu.yaml => ubuntu-winter.yaml} | 6 + 2 files changed, 130 insertions(+) create mode 100644 .gitea/workflows/ubuntu-dockerio.yaml rename .gitea/workflows/{ubuntu.yaml => ubuntu-winter.yaml} (94%) diff --git a/.gitea/workflows/ubuntu-dockerio.yaml b/.gitea/workflows/ubuntu-dockerio.yaml new file mode 100644 index 0000000..9544f40 --- /dev/null +++ b/.gitea/workflows/ubuntu-dockerio.yaml @@ -0,0 +1,124 @@ +name: Build and Push Ubuntu Image +on: + push: + branches: + - master + +jobs: + build: + name: Build and push image + runs-on: ubuntu-latest + container: + image: ghcr.io/catthehacker/ubuntu:act-latest + steps: + - name: Check out repository code + uses: actions/checkout@v3 + - name: Login to Docker Winter Access Git Registry + uses: docker/login-action@v3 + with: + registry: docker.io + username: aprimediet + password: ${{ secrets.DOCKER_TOKEN }} + - name: Login to Docker Registry + uses: docker/login-action@v3 + with: + registry: docker.io + username: aprimediet + password: ${{ secrets.DOCKER_TOKEN }} + - name: Build and push 5.6 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=5.6 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:5.6 + aprimediet/php-fpm:5.6-ubuntu + - name: Build and push 7.2 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=7.2 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:7.2 + aprimediet/php-fpm:7.2-ubuntu + - name: Build and push 7.3 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=7.3 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:7.3 + aprimediet/php-fpm:7.3-ubuntu + - name: Build and push 7.4 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=7.4 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:7.4 + aprimediet/php-fpm:7.4-ubuntu + - name: Build and push 8.0 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=8.0 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:8.0 + aprimediet/php-fpm:8.0-ubuntu + - name: Build and push 8.1 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=8.1 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:8.1 + aprimediet/php-fpm:8.1-ubuntu + - name: Build and push 8.2 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=8.2 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:8.2 + aprimediet/php-fpm:8.2-ubuntu + - name: Build and push 8.3 Images + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.ubuntu + build-args: | + PHP_VERSION=8.3 + BASE_REPO=aprimediet/php + push: true + tags: | + aprimediet/php-fpm:8.3 + aprimediet/php-fpm:8.3-ubuntu + aprimediet/php-fpm:latest diff --git a/.gitea/workflows/ubuntu.yaml b/.gitea/workflows/ubuntu-winter.yaml similarity index 94% rename from .gitea/workflows/ubuntu.yaml rename to .gitea/workflows/ubuntu-winter.yaml index 92fbb6d..f9adc15 100644 --- a/.gitea/workflows/ubuntu.yaml +++ b/.gitea/workflows/ubuntu-winter.yaml @@ -19,6 +19,12 @@ jobs: registry: git.winteraccess.id username: aditya.prima password: ${{ secrets.PATOKEN }} + - name: Login to Docker Registry + uses: docker/login-action@v3 + with: + registry: docker.io + username: aprimediet + password: ${{ secrets.DOCKER_TOKEN }} - name: Build and push 5.6 Images uses: docker/build-push-action@v5 with: