From 2b10865ab83f45e5945591c56ce91bb62a4b2893 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:32:46 +0100 Subject: [PATCH 01/12] wip --- .github/workflows/code-style.yml | 2 +- .github/workflows/docker-test.yml | 30 ++++++++++++++++++++++++++++++ .github/workflows/tests.yml | 2 +- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/docker-test.yml diff --git a/.github/workflows/code-style.yml b/.github/workflows/code-style.yml index e77a00857..d731bb14f 100644 --- a/.github/workflows/code-style.yml +++ b/.github/workflows/code-style.yml @@ -6,7 +6,7 @@ on: - main - 1.x - 2.x - pull_request: +# pull_request: jobs: code-style: diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml new file mode 100644 index 000000000..24259c2b5 --- /dev/null +++ b/.github/workflows/docker-test.yml @@ -0,0 +1,30 @@ +name: Docker Test + +on: + pull_request: + +jobs: + build-and-push: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up QEMU + uses: docker/setup-qemu-action@v3 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + + - name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + + - name: Build + run: | + docker buildx build . \ + -f docker/Dockerfile \ + -t vitodeploy/vito:latest \ + --platform linux/arm64 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index d89c2a245..a978de719 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -6,7 +6,7 @@ on: - main - 1.x - 2.x - pull_request: +# pull_request: jobs: tests: From 971bc3d261a5f89bdb6e08d303eff5a5d1a648c1 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:34:12 +0100 Subject: [PATCH 02/12] downgrade ubuntu --- docker/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 5e3b176a2..4cc4c50df 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:24.04 +FROM ubuntu:22.04 WORKDIR /var/www/html From d2fc283442bcdec3cc598156c65d9c397d773515 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:37:45 +0100 Subject: [PATCH 03/12] wip --- docker/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 4cc4c50df..8f7a3b0e8 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -5,7 +5,7 @@ WORKDIR /var/www/html ENV DEBIAN_FRONTEND noninteractive # upgrade -RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y +RUN apt-get clean && apt-get update && apt-get upgrade -y && apt-get autoremove -y # requirements RUN apt-get install -y software-properties-common curl zip unzip gcc From 660b72fb39f590e1f59b865f36d9d4a746844111 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:39:38 +0100 Subject: [PATCH 04/12] wip --- .github/workflows/docker-latest.yml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/docker-latest.yml b/.github/workflows/docker-latest.yml index e10838d11..105460338 100644 --- a/.github/workflows/docker-latest.yml +++ b/.github/workflows/docker-latest.yml @@ -25,10 +25,9 @@ jobs: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - - name: Build and push to the latest tag - run: | - docker buildx build . \ - -f docker/Dockerfile \ - -t vitodeploy/vito:latest \ - --platform linux/amd64,linux/arm64 \ - --push + - name: Build + uses: docker/build-push-action@v6 + with: + platforms: linux/amd64,linux/arm64 + push: false + tags: vitodeploy/vito:latest From 6c3e5423a680c8fb88f6ae83b047bc042fb8cefa Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:40:54 +0100 Subject: [PATCH 05/12] wip --- .github/workflows/docker-latest.yml | 13 +++++++------ .github/workflows/docker-test.yml | 10 +++++----- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/.github/workflows/docker-latest.yml b/.github/workflows/docker-latest.yml index 105460338..e10838d11 100644 --- a/.github/workflows/docker-latest.yml +++ b/.github/workflows/docker-latest.yml @@ -25,9 +25,10 @@ jobs: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - - name: Build - uses: docker/build-push-action@v6 - with: - platforms: linux/amd64,linux/arm64 - push: false - tags: vitodeploy/vito:latest + - name: Build and push to the latest tag + run: | + docker buildx build . \ + -f docker/Dockerfile \ + -t vitodeploy/vito:latest \ + --platform linux/amd64,linux/arm64 \ + --push diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml index 24259c2b5..d1371b11c 100644 --- a/.github/workflows/docker-test.yml +++ b/.github/workflows/docker-test.yml @@ -23,8 +23,8 @@ jobs: password: ${{ secrets.DOCKER_PASSWORD }} - name: Build - run: | - docker buildx build . \ - -f docker/Dockerfile \ - -t vitodeploy/vito:latest \ - --platform linux/arm64 + uses: docker/build-push-action@v6 + with: + platforms: linux/amd64,linux/arm64 + push: false + tags: vitodeploy/vito:latest From dfe9544eb2dda144195ee4f5a92ee440525171d2 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:42:27 +0100 Subject: [PATCH 06/12] wip --- .github/workflows/docker-test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml index d1371b11c..29e7a010d 100644 --- a/.github/workflows/docker-test.yml +++ b/.github/workflows/docker-test.yml @@ -25,6 +25,7 @@ jobs: - name: Build uses: docker/build-push-action@v6 with: + file: ./docker/Dockerfile platforms: linux/amd64,linux/arm64 push: false tags: vitodeploy/vito:latest From bd9435f6abaf6eb5f5041f15dc44f6974a9f82d5 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:44:27 +0100 Subject: [PATCH 07/12] wip --- .github/workflows/docker-test.yml | 2 +- docker/Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml index 29e7a010d..e06c5c3af 100644 --- a/.github/workflows/docker-test.yml +++ b/.github/workflows/docker-test.yml @@ -26,6 +26,6 @@ jobs: uses: docker/build-push-action@v6 with: file: ./docker/Dockerfile - platforms: linux/amd64,linux/arm64 + platforms: linux/arm64 push: false tags: vitodeploy/vito:latest diff --git a/docker/Dockerfile b/docker/Dockerfile index 8f7a3b0e8..00a5cb7a4 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:22.04 +FROM ubuntu:24.04 WORKDIR /var/www/html From e38d6d2198be609dc5ef327fc5b74d032e814605 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:51:04 +0100 Subject: [PATCH 08/12] wip --- docker/Dockerfile | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 00a5cb7a4..f99b34b92 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -4,23 +4,20 @@ WORKDIR /var/www/html ENV DEBIAN_FRONTEND noninteractive +# Add repositories +RUN add-apt-repository ppa:ondrej/php -y + # upgrade -RUN apt-get clean && apt-get update && apt-get upgrade -y && apt-get autoremove -y +RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y # requirements -RUN apt-get install -y software-properties-common curl zip unzip gcc - -# nginx -RUN apt-get install -y nginx +RUN apt-get install -y software-properties-common curl zip unzip gcc nginx \ + cron gnupg gosu curl ca-certificates zip unzip supervisor libcap2-bin libpng-dev \ + dnsutils librsvg2-bin fswatch wget openssh-client \ + php8.2 php8.2-fpm php8.2-mbstring php8.2-mcrypt php8.2-gd php8.2-xml \ + php8.2-curl php8.2-gettext php8.2-zip php8.2-bcmath php8.2-soap php8.2-redis php8.2-sqlite3 php8.2-intl # php -RUN apt-get update \ - && apt-get install -y cron gnupg gosu curl ca-certificates zip unzip supervisor libcap2-bin libpng-dev \ - dnsutils librsvg2-bin fswatch wget openssh-client \ - && add-apt-repository ppa:ondrej/php -y \ - && apt-get update \ - && apt-get install -y php8.2 php8.2-fpm php8.2-mbstring php8.2-mcrypt php8.2-gd php8.2-xml \ - php8.2-curl php8.2-gettext php8.2-zip php8.2-bcmath php8.2-soap php8.2-redis php8.2-sqlite3 php8.2-intl COPY docker/php.ini /etc/php/8.2/cli/conf.d/99-vito.ini # composer From 1e9b838545e5eb91f3acdf61048e0fd6610e7be4 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:53:34 +0100 Subject: [PATCH 09/12] wip --- docker/Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index f99b34b92..6fdce973c 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -4,6 +4,8 @@ WORKDIR /var/www/html ENV DEBIAN_FRONTEND noninteractive +RUN apt-get install -y software-properties-common + # Add repositories RUN add-apt-repository ppa:ondrej/php -y @@ -11,7 +13,7 @@ RUN add-apt-repository ppa:ondrej/php -y RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y # requirements -RUN apt-get install -y software-properties-common curl zip unzip gcc nginx \ +RUN apt-get install -y curl zip unzip gcc nginx \ cron gnupg gosu curl ca-certificates zip unzip supervisor libcap2-bin libpng-dev \ dnsutils librsvg2-bin fswatch wget openssh-client \ php8.2 php8.2-fpm php8.2-mbstring php8.2-mcrypt php8.2-gd php8.2-xml \ From 3100cc4bfa913a848eb4410da6ab378fe8e28b6a Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 15:55:10 +0100 Subject: [PATCH 10/12] wip --- docker/Dockerfile | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 6fdce973c..a9f57e0c6 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -4,14 +4,11 @@ WORKDIR /var/www/html ENV DEBIAN_FRONTEND noninteractive -RUN apt-get install -y software-properties-common +RUN apt-get update && apt-get install -y software-properties-common # Add repositories RUN add-apt-repository ppa:ondrej/php -y -# upgrade -RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y - # requirements RUN apt-get install -y curl zip unzip gcc nginx \ cron gnupg gosu curl ca-certificates zip unzip supervisor libcap2-bin libpng-dev \ From 21d0c6070eed5741daa87e4710fa20bd3ded4124 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 16:12:09 +0100 Subject: [PATCH 11/12] disable docker actions --- .github/workflows/docker-latest.yml | 6 +++--- .github/workflows/docker-release.yml | 4 ++-- .github/workflows/docker-test.yml | 31 ---------------------------- docker/Dockerfile | 14 ++++++------- 4 files changed, 12 insertions(+), 43 deletions(-) delete mode 100644 .github/workflows/docker-test.yml diff --git a/.github/workflows/docker-latest.yml b/.github/workflows/docker-latest.yml index e10838d11..38a6fe9a2 100644 --- a/.github/workflows/docker-latest.yml +++ b/.github/workflows/docker-latest.yml @@ -2,9 +2,9 @@ name: Docker Latest on: workflow_dispatch: - push: - branches: - - 2.x +# push: +# branches: +# - 2.x jobs: build-and-push: diff --git a/.github/workflows/docker-release.yml b/.github/workflows/docker-release.yml index 3321e5107..f50824370 100644 --- a/.github/workflows/docker-release.yml +++ b/.github/workflows/docker-release.yml @@ -2,8 +2,8 @@ name: Docker Release on: workflow_dispatch: - release: - types: [ created ] +# release: +# types: [ created ] jobs: build-and-push: diff --git a/.github/workflows/docker-test.yml b/.github/workflows/docker-test.yml deleted file mode 100644 index e06c5c3af..000000000 --- a/.github/workflows/docker-test.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: Docker Test - -on: - pull_request: - -jobs: - build-and-push: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Set up QEMU - uses: docker/setup-qemu-action@v3 - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v3 - - - name: Login to Docker Hub - uses: docker/login-action@v2 - with: - username: ${{ secrets.DOCKER_USERNAME }} - password: ${{ secrets.DOCKER_PASSWORD }} - - - name: Build - uses: docker/build-push-action@v6 - with: - file: ./docker/Dockerfile - platforms: linux/arm64 - push: false - tags: vitodeploy/vito:latest diff --git a/docker/Dockerfile b/docker/Dockerfile index a9f57e0c6..e8bc45bcd 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -4,17 +4,17 @@ WORKDIR /var/www/html ENV DEBIAN_FRONTEND noninteractive -RUN apt-get update && apt-get install -y software-properties-common - -# Add repositories -RUN add-apt-repository ppa:ondrej/php -y +# upgrade +RUN apt-get update && apt-get upgrade -y && apt-get autoremove -y # requirements -RUN apt-get install -y curl zip unzip gcc nginx \ +RUN apt-get install -y software-properties-common curl zip unzip gcc nginx \ cron gnupg gosu curl ca-certificates zip unzip supervisor libcap2-bin libpng-dev \ dnsutils librsvg2-bin fswatch wget openssh-client \ - php8.2 php8.2-fpm php8.2-mbstring php8.2-mcrypt php8.2-gd php8.2-xml \ - php8.2-curl php8.2-gettext php8.2-zip php8.2-bcmath php8.2-soap php8.2-redis php8.2-sqlite3 php8.2-intl + && add-apt-repository ppa:ondrej/php -y \ + && apt-get update \ + && apt-get install -y php8.2 php8.2-fpm php8.2-mbstring php8.2-mcrypt php8.2-gd php8.2-xml \ + php8.2-curl php8.2-gettext php8.2-zip php8.2-bcmath php8.2-soap php8.2-redis php8.2-sqlite3 php8.2-intl # php COPY docker/php.ini /etc/php/8.2/cli/conf.d/99-vito.ini From a133da72f4c0b7b4d6a776aae4c9750ae37e3e63 Mon Sep 17 00:00:00 2001 From: Saeed Vaziry Date: Sun, 16 Feb 2025 16:12:50 +0100 Subject: [PATCH 12/12] fix --- .github/workflows/code-style.yml | 2 +- .github/workflows/tests.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/code-style.yml b/.github/workflows/code-style.yml index d731bb14f..e77a00857 100644 --- a/.github/workflows/code-style.yml +++ b/.github/workflows/code-style.yml @@ -6,7 +6,7 @@ on: - main - 1.x - 2.x -# pull_request: + pull_request: jobs: code-style: diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a978de719..d89c2a245 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -6,7 +6,7 @@ on: - main - 1.x - 2.x -# pull_request: + pull_request: jobs: tests: