From b74ec330939bb056b634b5803ecccbc23815e309 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 12 Jan 2026 09:55:41 +0100 Subject: [PATCH 01/64] initial commit gha --- .github/workflows/sonar-and-test-S3.yaml | 82 ++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 .github/workflows/sonar-and-test-S3.yaml diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml new file mode 100644 index 0000000..ccc4887 --- /dev/null +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -0,0 +1,82 @@ +name: Test Sonarqube Composer and S3 + +on: + workflow_dispatch: + push: + branches: + - '**' +env: + FOLDER: "dist" + foldersCache: "vendor/" + +jobs: + + test-sonarqube: + name: Test SonarQube Scan + uses: aplazame/.github/.github/workflows/test-reusable-sonarqube.yml@master + secrets: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + + test-composer: + name: Test Composer Install + runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/pro' || + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'pro') + && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + steps: + - name: Checkout code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 + with: + fetch-depth: 0 + + - name: Set up PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '5.3' + extensions: mbstring, intl, xml, curl, zip, json + tools: composer:v1 + + - name: Get cache + env: + s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz + run: | + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 + [ -f cache.tar.gz ] && tar -xf cache.tar.gz + aws s3 cp --quiet aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz cache.tar.gz + + - name: Composer Install + run: composer install --prefer-dist + + - name: Cache Composer dependencies + env: + foldersStr: '.' + s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz + run: | + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + MATCHES=$(aws s3 ls ${s3Path} | wc -l) + [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersStr} && aws s3 cp --quiet cache.tar.gz ${s3Path} + exit 0 + + - name: Check syntax + run: make syntax.checker + + - name: Make Styleci happy + run: make style + + - name: Create Bundle + run: make zip + + - name: Deply to S3 + env: + s3Path: aws s3 cp --quiet s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip + run: | + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} + + # - name: Create Release \ No newline at end of file From da890c6e88d3e0c1a565eb66f1482af587682be7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 13 Jan 2026 12:41:00 +0100 Subject: [PATCH 02/64] test1 --- .github/workflows/sonar-and-test-S3.yaml | 2 +- .github/workflows/test-reusable-sonarqube.yml | 26 +++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/test-reusable-sonarqube.yml diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index ccc4887..f3be08a 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -13,7 +13,7 @@ jobs: test-sonarqube: name: Test SonarQube Scan - uses: aplazame/.github/.github/workflows/test-reusable-sonarqube.yml@master + uses: ./.github/workflows/test-reusable-sonarqube.yml secrets: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/.github/workflows/test-reusable-sonarqube.yml b/.github/workflows/test-reusable-sonarqube.yml new file mode 100644 index 0000000..3662507 --- /dev/null +++ b/.github/workflows/test-reusable-sonarqube.yml @@ -0,0 +1,26 @@ +name: Test SonarQube Scan +on: + workflow_call: + secrets: + SONAR_TOKEN: + description: "Token for SonarQube" + required: true + + +jobs: + test-sonarqube: + name: Test SonarQube Scan + runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/pro' || + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'pro') + && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + steps: + - name: Checkout code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 + with: + fetch-depth: 0 + + - name: SonarQube Scan + uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9 #v7.0.0 + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + #SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} \ No newline at end of file From fa90936edb62ba55f51fbb931ff37d2c96c7dd12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 14:16:45 +0100 Subject: [PATCH 03/64] fix 1.0 --- .github/workflows/sonar-and-test-S3.yaml | 38 +++++++++++++++++-- ...ner.properties => sonar-project.properties | 2 +- 2 files changed, 35 insertions(+), 5 deletions(-) rename sonar-scanner.properties => sonar-project.properties (94%) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index f3be08a..564fa98 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -8,6 +8,12 @@ on: env: FOLDER: "dist" foldersCache: "vendor/" + AWS_REGION: 'eu-central-1' + AWS_ACCOUNT: '666356151544' + +permissions: + contents: read + id-token: write jobs: @@ -15,10 +21,11 @@ jobs: name: Test SonarQube Scan uses: ./.github/workflows/test-reusable-sonarqube.yml secrets: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_TOKEN: ${{ secrets.WZ_SONAR_TOKEN }} test-composer: name: Test Composer Install + needs: test-sonarqube runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/pro' || github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'pro') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} @@ -31,10 +38,31 @@ jobs: - name: Set up PHP uses: shivammathur/setup-php@v2 with: - php-version: '5.3' + php-version: '5.6' extensions: mbstring, intl, xml, curl, zip, json - tools: composer:v1 + tools: composer:v2 + - name: Install AWS CLI + run: | + sudo apt-get install unzip curl -y + curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" + unzip awscliv2.zip + sudo ./aws/install --update + aws --version + + - name: Configure aws credentials + uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 + with: + role-to-assume: ${{ env.ROLE_OIDC }} + role-session-name: ${{ github.run_id }} + aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} + + - name: Login to Amazon ECR + id: ecrlogin + uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 + with: + registries: ${{ env.AWS_ACCOUNT }} + - name: Get cache env: s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz @@ -68,10 +96,13 @@ jobs: run: make style - name: Create Bundle + env: + branch: master run: make zip - name: Deply to S3 env: + branch: master s3Path: aws s3 cp --quiet s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip run: | load-config @@ -79,4 +110,3 @@ jobs: set -e aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} - # - name: Create Release \ No newline at end of file diff --git a/sonar-scanner.properties b/sonar-project.properties similarity index 94% rename from sonar-scanner.properties rename to sonar-project.properties index c0abf70..db012f7 100644 --- a/sonar-scanner.properties +++ b/sonar-project.properties @@ -4,7 +4,7 @@ sonar.projectVersion=1.0 sonar.projectBaseDir=/usr/src sonar.python.coverage.reportPaths=/src/coverage.xml sonar.host.url=https://sonarqube.aplazame.org/ -sonar.password= +#sonar.password= sonar.ws.timeout=600 sonar.log.level=DEBUG ActiveQualityGate=false From b661ac9435723aff1b5d7395acf531baba65da75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 14:22:12 +0100 Subject: [PATCH 04/64] remove load-config --- .github/workflows/sonar-and-test-S3.yaml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 564fa98..c3a8ace 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -67,7 +67,6 @@ jobs: env: s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - load-config export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 @@ -82,7 +81,6 @@ jobs: foldersStr: '.' s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - load-config export AWS_PROFILE=AplazameSharedServices set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) @@ -105,7 +103,6 @@ jobs: branch: master s3Path: aws s3 cp --quiet s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip run: | - load-config export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} From 0c5d4f7de88453f6f1a0e8eb6e6570e8fc8000ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 17:08:56 +0100 Subject: [PATCH 05/64] change pro by master --- .github/workflows/sonar-and-test-S3.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index c3a8ace..ffe70e4 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -26,8 +26,8 @@ jobs: test-composer: name: Test Composer Install needs: test-sonarqube - runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/pro' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'pro') + runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} steps: - name: Checkout code From 76782b87559183a2f1b2edfa16dfb4e022a72565 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 17:40:53 +0100 Subject: [PATCH 06/64] fix gha --- .github/workflows/sonar-and-test-S3.yaml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index ffe70e4..e09ab6c 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -65,7 +65,7 @@ jobs: - name: Get cache env: - s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz + s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | export AWS_PROFILE=AplazameSharedServices set -e @@ -79,7 +79,7 @@ jobs: - name: Cache Composer dependencies env: foldersStr: '.' - s3Path: aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz + s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | export AWS_PROFILE=AplazameSharedServices set -e @@ -93,15 +93,16 @@ jobs: - name: Make Styleci happy run: make style - - name: Create Bundle - env: - branch: master - run: make zip + #- name: Create Bundle + # env: + # branch: master + # run: make zip - name: Deply to S3 env: branch: master - s3Path: aws s3 cp --quiet s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip + s3Path: s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip + FOLDER: '.' run: | export AWS_PROFILE=AplazameSharedServices set -e From f7562799985b2e52dbdc369de6cbcc661f51b896 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 17:46:58 +0100 Subject: [PATCH 07/64] coment AWS_PROFILE --- .github/workflows/sonar-and-test-S3.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index e09ab6c..e8dfbd4 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -67,7 +67,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - export AWS_PROFILE=AplazameSharedServices + #export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz @@ -81,7 +81,7 @@ jobs: foldersStr: '.' s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - export AWS_PROFILE=AplazameSharedServices + #export AWS_PROFILE=AplazameSharedServices set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersStr} && aws s3 cp --quiet cache.tar.gz ${s3Path} @@ -104,7 +104,7 @@ jobs: s3Path: s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip FOLDER: '.' run: | - export AWS_PROFILE=AplazameSharedServices + #export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} From 5bf49b802e234fcec6c31f9ede42b93107910e8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 17:57:10 +0100 Subject: [PATCH 08/64] remove comments --- .github/workflows/sonar-and-test-S3.yaml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index e8dfbd4..a5b53e6 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -67,12 +67,11 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - #export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz - aws s3 cp --quiet aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz cache.tar.gz - + aws s3 cp --quiet ${s3Path} cache.tar.gz + - name: Composer Install run: composer install --prefer-dist @@ -81,7 +80,6 @@ jobs: foldersStr: '.' s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - #export AWS_PROFILE=AplazameSharedServices set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersStr} && aws s3 cp --quiet cache.tar.gz ${s3Path} @@ -104,7 +102,6 @@ jobs: s3Path: s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip FOLDER: '.' run: | - #export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} From bb2649bdf9857bc190796b399f4e37ef03a8e856 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 18:00:45 +0100 Subject: [PATCH 09/64] change folder deploy --- .github/workflows/sonar-and-test-S3.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index a5b53e6..420c151 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -71,7 +71,7 @@ jobs: aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz aws s3 cp --quiet ${s3Path} cache.tar.gz - + - name: Composer Install run: composer install --prefer-dist @@ -100,8 +100,7 @@ jobs: env: branch: master s3Path: s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip - FOLDER: '.' run: | set -e - aws s3 cp --quiet ${FOLDER}/Aplazame-Prestashop.zip ${s3Path} + aws s3 cp --quiet ${s3Path}/Aplazame-Prestashop.zip From 3cd20496986773374d8459499ba8fd644fb7b1e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 18:28:43 +0100 Subject: [PATCH 10/64] fix gha --- .github/workflows/sonar-and-test-S3.yaml | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 420c151..30a20e5 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -91,16 +91,10 @@ jobs: - name: Make Styleci happy run: make style - #- name: Create Bundle - # env: - # branch: master - # run: make zip + - name: Create Bundle + run: make zip - - name: Deply to S3 - env: - branch: master - s3Path: s3://aplazameshared-deploys/Aplazame-Backend/prestashop/${{ github.sha }}.zip + - name: Deploy to S3 run: | - set -e - aws s3 cp --quiet ${s3Path}/Aplazame-Prestashop.zip + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From 274df587be67839202ad1f2036c6c304e6123bab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 18:40:31 +0100 Subject: [PATCH 11/64] fix Create bundle --- .github/workflows/sonar-and-test-S3.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 30a20e5..e37b9d1 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -8,6 +8,7 @@ on: env: FOLDER: "dist" foldersCache: "vendor/" + CODE_SOURCE_DEFAULT: "aplazame" AWS_REGION: 'eu-central-1' AWS_ACCOUNT: '666356151544' From 7ffb9a9a291a11279a04acabb3a3966e2d225475 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 18:50:14 +0100 Subject: [PATCH 12/64] fix folderCache --- .github/workflows/sonar-and-test-S3.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index e37b9d1..c641777 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -76,14 +76,13 @@ jobs: - name: Composer Install run: composer install --prefer-dist - - name: Cache Composer dependencies + - name: Upload cache env: - foldersStr: '.' s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) - [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersStr} && aws s3 cp --quiet cache.tar.gz ${s3Path} + [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} exit 0 - name: Check syntax From 161a0b8db0f2dbc708b6ff55de8b7d38eece7077 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 19:30:22 +0100 Subject: [PATCH 13/64] fix gha --- .github/workflows/sonar-and-test-S3.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index c641777..f675049 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -68,6 +68,8 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | + load-config + export AWS_PROFILE=AplazameSharedServices set -e aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz @@ -80,6 +82,8 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | + load-config + export AWS_PROFILE=AplazameSharedServices set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} @@ -96,5 +100,7 @@ jobs: - name: Deploy to S3 run: | - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ + load-config + export AWS_PROFILE=Aplazame + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From ac7a4695e3a2458a6bd3e09ba06703828a1dbb3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 20:08:07 +0100 Subject: [PATCH 14/64] add image php for load-config --- .github/workflows/sonar-and-test-S3.yaml | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index f675049..907e5ea 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -28,11 +28,11 @@ jobs: name: Test Composer Install needs: test-sonarqube runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') - && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') + && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} steps: - name: Checkout code - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 with: fetch-depth: 0 @@ -63,8 +63,15 @@ jobs: uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 with: registries: ${{ env.AWS_ACCOUNT }} - - - name: Get cache + + deploy: + name: Deploy to S3 + needs: test-composer + runs-on: ubuntu-latest + container: + image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 + steps: + - name: Get cache env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | From 11a5a23788acfec7672f994a2482c3dd52f357cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 20:26:28 +0100 Subject: [PATCH 15/64] steps --- .github/workflows/sonar-and-test-S3.yaml | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 907e5ea..a6ef849 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -70,7 +70,27 @@ jobs: runs-on: ubuntu-latest container: image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 - steps: + steps: + - name: Install AWS CLI + run: | + sudo apt-get install unzip curl -y + curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" + unzip awscliv2.zip + sudo ./aws/install --update + aws --version + + - name: Configure aws credentials + uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 + with: + role-to-assume: ${{ env.ROLE_OIDC }} + role-session-name: ${{ github.run_id }} + aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} + + - name: Login to Amazon ECR + id: ecrlogin + uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 + with: + registries: ${{ env.AWS_ACCOUNT }} - name: Get cache env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz From 422afd95632c13653424b66229745473705adc5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 14 Jan 2026 20:30:06 +0100 Subject: [PATCH 16/64] steps 2 --- .github/workflows/sonar-and-test-S3.yaml | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index a6ef849..973166e 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -42,27 +42,7 @@ jobs: php-version: '5.6' extensions: mbstring, intl, xml, curl, zip, json tools: composer:v2 - - - name: Install AWS CLI - run: | - sudo apt-get install unzip curl -y - curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" - unzip awscliv2.zip - sudo ./aws/install --update - aws --version - - - name: Configure aws credentials - uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 - with: - role-to-assume: ${{ env.ROLE_OIDC }} - role-session-name: ${{ github.run_id }} - aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} - - - name: Login to Amazon ECR - id: ecrlogin - uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 - with: - registries: ${{ env.AWS_ACCOUNT }} + deploy: name: Deploy to S3 @@ -91,6 +71,7 @@ jobs: uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 with: registries: ${{ env.AWS_ACCOUNT }} + - name: Get cache env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz From f284f5ec7db80b4c9197a670f48f97d9754842db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 09:02:35 +0100 Subject: [PATCH 17/64] refactor 1.0 --- .github/workflows/sonar-and-test-S3.yaml | 63 +++++++++---------- .github/workflows/test-reusable-sonarqube.yml | 4 +- 2 files changed, 31 insertions(+), 36 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 973166e..63c0942 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -24,33 +24,18 @@ jobs: secrets: SONAR_TOKEN: ${{ secrets.WZ_SONAR_TOKEN }} - test-composer: - name: Test Composer Install + setup-aws: + name: Setup AWS needs: test-sonarqube - runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') - && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} - steps: - - name: Checkout code - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 - with: - fetch-depth: 0 - - - name: Set up PHP - uses: shivammathur/setup-php@v2 - with: - php-version: '5.6' - extensions: mbstring, intl, xml, curl, zip, json - tools: composer:v2 - - - deploy: - name: Deploy to S3 - needs: test-composer runs-on: ubuntu-latest - container: - image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 steps: + - name: Configure aws credentials + uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 + with: + role-to-assume: ${{ env.ROLE_OIDC }} + role-session-name: ${{ github.run_id }} + aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} + - name: Install AWS CLI run: | sudo apt-get install unzip curl -y @@ -58,21 +43,31 @@ jobs: unzip awscliv2.zip sudo ./aws/install --update aws --version - - - name: Configure aws credentials - uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 - with: - role-to-assume: ${{ env.ROLE_OIDC }} - role-session-name: ${{ github.run_id }} - aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} - + - name: Login to Amazon ECR id: ecrlogin uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 with: registries: ${{ env.AWS_ACCOUNT }} - - - name: Get cache + + test-composer: + name: Test Composer Install + needs: setup-aws + runs-on: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 + steps: + - name: Checkout code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 + with: + fetch-depth: 0 + + - name: Set up PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '5.6' + extensions: mbstring, intl, xml, curl, zip, json + tools: composer:v2 + + - name: Get cache env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | diff --git a/.github/workflows/test-reusable-sonarqube.yml b/.github/workflows/test-reusable-sonarqube.yml index 3662507..26614ba 100644 --- a/.github/workflows/test-reusable-sonarqube.yml +++ b/.github/workflows/test-reusable-sonarqube.yml @@ -10,8 +10,8 @@ on: jobs: test-sonarqube: name: Test SonarQube Scan - runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/pro' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'pro') + runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} steps: - name: Checkout code From f27cb3af3419f502ee3112b89993e0e9bd81bfdd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 09:06:00 +0100 Subject: [PATCH 18/64] refactor 1.1 --- .github/workflows/sonar-and-test-S3.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 63c0942..c32920d 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -27,7 +27,9 @@ jobs: setup-aws: name: Setup AWS needs: test-sonarqube - runs-on: ubuntu-latest + runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || + github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') + && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} steps: - name: Configure aws credentials uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 From 24a63ae8f1451a9d2fd7bc110ae1a3fef73b9c92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 09:29:47 +0100 Subject: [PATCH 19/64] add container php image --- .github/workflows/sonar-and-test-S3.yaml | 54 ++++++++++++------------ 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index c32920d..8f8de3b 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -24,20 +24,25 @@ jobs: secrets: SONAR_TOKEN: ${{ secrets.WZ_SONAR_TOKEN }} - setup-aws: - name: Setup AWS + test-composer: + name: Test Composer Install needs: test-sonarqube runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} steps: - - name: Configure aws credentials - uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 + - name: Checkout code + uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 with: - role-to-assume: ${{ env.ROLE_OIDC }} - role-session-name: ${{ github.run_id }} - aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} - + fetch-depth: 0 + + - name: Set up PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '5.6' + extensions: mbstring, intl, xml, curl, zip, json + tools: composer:v2 + - name: Install AWS CLI run: | sudo apt-get install unzip curl -y @@ -45,34 +50,25 @@ jobs: unzip awscliv2.zip sudo ./aws/install --update aws --version - + + - name: Configure aws credentials + uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 + with: + role-to-assume: ${{ env.ROLE_OIDC }} + role-session-name: ${{ github.run_id }} + aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} + - name: Login to Amazon ECR id: ecrlogin uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 with: registries: ${{ env.AWS_ACCOUNT }} - - test-composer: - name: Test Composer Install - needs: setup-aws - runs-on: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 - steps: - - name: Checkout code - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 - with: - fetch-depth: 0 - - - name: Set up PHP - uses: shivammathur/setup-php@v2 - with: - php-version: '5.6' - extensions: mbstring, intl, xml, curl, zip, json - tools: composer:v2 - name: Get cache env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " load-config export AWS_PROFILE=AplazameSharedServices set -e @@ -87,6 +83,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " load-config export AWS_PROFILE=AplazameSharedServices set -e @@ -101,10 +98,13 @@ jobs: run: make style - name: Create Bundle - run: make zip + run: | + dockerrun --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " + make zip - name: Deploy to S3 run: | + dockerrun --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " load-config export AWS_PROFILE=Aplazame aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From 30b1c263ccd2c4e278913f33713e448b65bd7167 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 09:37:08 +0100 Subject: [PATCH 20/64] fix add container php image --- .github/workflows/sonar-and-test-S3.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 8f8de3b..9ba3e27 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -68,7 +68,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " load-config export AWS_PROFILE=AplazameSharedServices set -e @@ -83,7 +83,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " load-config export AWS_PROFILE=AplazameSharedServices set -e @@ -99,12 +99,12 @@ jobs: - name: Create Bundle run: | - dockerrun --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " make zip - name: Deploy to S3 run: | - dockerrun --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/awscli:2.7.18 bash -c " + docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " load-config export AWS_PROFILE=Aplazame aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From efec60bf20c690f88f0c6c2306defa32c7b7d0ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 09:55:33 +0100 Subject: [PATCH 21/64] fix add image container php --- .github/workflows/sonar-and-test-S3.yaml | 59 +++++++++++++++--------- 1 file changed, 38 insertions(+), 21 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 9ba3e27..0c6ed67 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -68,13 +68,18 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 - [ -f cache.tar.gz ] && tar -xf cache.tar.gz - aws s3 cp --quiet ${s3Path} cache.tar.gz + docker run --rm \ + -v ${{ github.workspace }}:/work \ + -w /work \ + 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ + bash -c ' + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 + [ -f cache.tar.gz ] && tar -xf cache.tar.gz + aws s3 cp --quiet ${s3Path} cache.tar.gz + ' - name: Composer Install run: composer install --prefer-dist @@ -83,13 +88,18 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - MATCHES=$(aws s3 ls ${s3Path} | wc -l) - [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} - exit 0 + docker run --rm \ + -v ${{ github.workspace }}:/work \ + -w /work \ + 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ + bash -c ' + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + MATCHES=$(aws s3 ls ${s3Path} | wc -l) + [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} + exit 0 + ' - name: Check syntax run: make syntax.checker @@ -99,13 +109,20 @@ jobs: - name: Create Bundle run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " - make zip + docker run --rm \ + -v ${{ github.workspace }}:/work \ + -w /work \ + 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ + bash -c 'make zip' - name: Deploy to S3 run: | - docker run --rm -v ${{ github.workspace }}:/work -w /work 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 bash -c " - load-config - export AWS_PROFILE=Aplazame - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ - + docker run --rm \ + -v ${{ github.workspace }}:/work \ + -w /work \ + 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ + bash -c ' + load-config + export AWS_PROFILE=Aplazame + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ + ' From 78d664949a1e0a089fd54fa6f5e7154fc848ccfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 12:11:44 +0100 Subject: [PATCH 22/64] add imagen to job --- .github/workflows/sonar-and-test-S3.yaml | 72 +++++++++--------------- 1 file changed, 26 insertions(+), 46 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 0c6ed67..e398476 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -30,18 +30,21 @@ jobs: runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + container: + image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 + options: --user 1000:1000 steps: - name: Checkout code uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 with: fetch-depth: 0 - - - name: Set up PHP - uses: shivammathur/setup-php@v2 - with: - php-version: '5.6' - extensions: mbstring, intl, xml, curl, zip, json - tools: composer:v2 + + # - name: Set up PHP + # uses: shivammathur/setup-php@v2 + # with: + # php-version: '5.6' + # extensions: mbstring, intl, xml, curl, zip, json + # tools: composer:v2 - name: Install AWS CLI run: | @@ -68,18 +71,12 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm \ - -v ${{ github.workspace }}:/work \ - -w /work \ - 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ - bash -c ' - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 - [ -f cache.tar.gz ] && tar -xf cache.tar.gz - aws s3 cp --quiet ${s3Path} cache.tar.gz - ' + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 + [ -f cache.tar.gz ] && tar -xf cache.tar.gz + aws s3 cp --quiet ${s3Path} cache.tar.gz - name: Composer Install run: composer install --prefer-dist @@ -88,18 +85,12 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - docker run --rm \ - -v ${{ github.workspace }}:/work \ - -w /work \ - 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ - bash -c ' - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - MATCHES=$(aws s3 ls ${s3Path} | wc -l) - [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} - exit 0 - ' + load-config + export AWS_PROFILE=AplazameSharedServices + set -e + MATCHES=$(aws s3 ls ${s3Path} | wc -l) + [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} + exit 0 - name: Check syntax run: make syntax.checker @@ -108,21 +99,10 @@ jobs: run: make style - name: Create Bundle - run: | - docker run --rm \ - -v ${{ github.workspace }}:/work \ - -w /work \ - 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ - bash -c 'make zip' + run: make zip - name: Deploy to S3 run: | - docker run --rm \ - -v ${{ github.workspace }}:/work \ - -w /work \ - 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 \ - bash -c ' - load-config - export AWS_PROFILE=Aplazame - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ - ' + load-config + export AWS_PROFILE=Aplazame + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From 13431d971f04751a859fc819fb14759a57317373 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 13:15:51 +0100 Subject: [PATCH 23/64] test2 --- .github/workflows/sonar-and-test-S3.yaml | 21 ++++++++------------- 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index e398476..ca078c6 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -30,21 +30,18 @@ jobs: runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} - container: - image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 - options: --user 1000:1000 steps: - name: Checkout code uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 with: fetch-depth: 0 - # - name: Set up PHP - # uses: shivammathur/setup-php@v2 - # with: - # php-version: '5.6' - # extensions: mbstring, intl, xml, curl, zip, json - # tools: composer:v2 + - name: Set up PHP + uses: shivammathur/setup-php@v2 + with: + php-version: '5.6' + extensions: mbstring, intl, xml, curl, zip, json + tools: composer:v2 - name: Install AWS CLI run: | @@ -71,8 +68,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - load-config - export AWS_PROFILE=AplazameSharedServices + set -e aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz @@ -85,8 +81,7 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - load-config - export AWS_PROFILE=AplazameSharedServices + set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} From bddd4348ba200d39ef75dba4401a9b244b79f979 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 13:25:03 +0100 Subject: [PATCH 24/64] add OICD --- .github/workflows/sonar-and-test-S3.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index ca078c6..2a4f35f 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -11,6 +11,8 @@ env: CODE_SOURCE_DEFAULT: "aplazame" AWS_REGION: 'eu-central-1' AWS_ACCOUNT: '666356151544' + ROLE_OIDC: 'arn:aws:iam::666356151544:role/ghaAdministratorAccessAplazameSharedServicesTf' + permissions: contents: read @@ -98,6 +100,4 @@ jobs: - name: Deploy to S3 run: | - load-config - export AWS_PROFILE=Aplazame aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From 265e3a31ffd5e74d9e296baff857c97f5b57520f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 15 Jan 2026 13:36:25 +0100 Subject: [PATCH 25/64] only pro --- .github/workflows/sonar-and-test-S3.yaml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 2a4f35f..8da3e7d 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -29,9 +29,7 @@ jobs: test-composer: name: Test Composer Install needs: test-sonarqube - runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') - && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + runs-on: ${{ vars.AWS_RG_NAME_PRO }} steps: - name: Checkout code uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 @@ -100,4 +98,4 @@ jobs: - name: Deploy to S3 run: | - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ \ No newline at end of file From 32ebcf65696e977fe242f817b35aee497fc0c9c6 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 13:49:55 +0100 Subject: [PATCH 26/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 8da3e7d..70a6f00 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -54,7 +54,7 @@ jobs: - name: Configure aws credentials uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 with: - role-to-assume: ${{ env.ROLE_OIDC }} + role-to-assume: ${{ vars.AWS_OIDC_ROLE_TF_PRO }} role-session-name: ${{ github.run_id }} aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} @@ -98,4 +98,4 @@ jobs: - name: Deploy to S3 run: | - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ \ No newline at end of file + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From f1ccdf645062be6d855b400ecb1e4a8476c450d4 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 13:54:36 +0100 Subject: [PATCH 27/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 70a6f00..1ac9bfb 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -57,6 +57,10 @@ jobs: role-to-assume: ${{ vars.AWS_OIDC_ROLE_TF_PRO }} role-session-name: ${{ github.run_id }} aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} + + - name: Export Variable + run: | + export AWS_PROFILE=AplazameSharedServices - name: Login to Amazon ECR id: ecrlogin From 5793d75025d296a6e651f5d5de642b7b1ff34f8f Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 15:31:43 +0100 Subject: [PATCH 28/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 1ac9bfb..b283231 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -62,14 +62,15 @@ jobs: run: | export AWS_PROFILE=AplazameSharedServices - - name: Login to Amazon ECR - id: ecrlogin - uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 - with: - registries: ${{ env.AWS_ACCOUNT }} + #- name: Login to Amazon ECR + # id: ecrlogin + # uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 + # with: + # registries: ${{ env.AWS_ACCOUNT }} - name: Get cache env: + AWS_PROFILE: AplazameSharedServices s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | @@ -83,6 +84,7 @@ jobs: - name: Upload cache env: + AWS_PROFILE: AplazameSharedServices s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | @@ -101,5 +103,7 @@ jobs: run: make zip - name: Deploy to S3 + env: + AWS_PROFILE: Aplazame run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ From 1ecb618100d85f169bf9d6984c70e6e0c008c8fe Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 15:39:06 +0100 Subject: [PATCH 29/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index b283231..ca8c288 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -19,9 +19,9 @@ permissions: id-token: write jobs: - test-sonarqube: name: Test SonarQube Scan + runs-on: ${{ vars.AWS_RG_NAME_PRO }} uses: ./.github/workflows/test-reusable-sonarqube.yml secrets: SONAR_TOKEN: ${{ secrets.WZ_SONAR_TOKEN }} From e6cf161da73ab6abd8b8d3ecd723aab0c28464b1 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 15:40:28 +0100 Subject: [PATCH 30/64] Update test-reusable-sonarqube.yml --- .github/workflows/test-reusable-sonarqube.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test-reusable-sonarqube.yml b/.github/workflows/test-reusable-sonarqube.yml index 26614ba..943769d 100644 --- a/.github/workflows/test-reusable-sonarqube.yml +++ b/.github/workflows/test-reusable-sonarqube.yml @@ -10,9 +10,7 @@ on: jobs: test-sonarqube: name: Test SonarQube Scan - runs-on: ${{ (github.event_name == 'push' && github.ref == 'refs/heads/master' || - github.event_name == 'pull_request' && github.event.pull_request.base.ref == 'master') - && vars.AWS_RG_NAME_PRO || vars.AWS_RG_NAME_NONPRO }} + runs-on: ${{ vars.AWS_RG_NAME_PRO }} steps: - name: Checkout code uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 #v6.0.1 @@ -23,4 +21,4 @@ jobs: uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9 #v7.0.0 env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - #SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} \ No newline at end of file + #SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} From 6d91594d81c42cbd6b42dc1c06c4a2d1d2a8e313 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 15:41:23 +0100 Subject: [PATCH 31/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index ca8c288..92db0ee 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -21,7 +21,6 @@ permissions: jobs: test-sonarqube: name: Test SonarQube Scan - runs-on: ${{ vars.AWS_RG_NAME_PRO }} uses: ./.github/workflows/test-reusable-sonarqube.yml secrets: SONAR_TOKEN: ${{ secrets.WZ_SONAR_TOKEN }} From 13d78a833a9190a4b9600617e749e468c31d0b13 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 15:59:33 +0100 Subject: [PATCH 32/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 92db0ee..c2aaf82 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -56,10 +56,6 @@ jobs: role-to-assume: ${{ vars.AWS_OIDC_ROLE_TF_PRO }} role-session-name: ${{ github.run_id }} aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} - - - name: Export Variable - run: | - export AWS_PROFILE=AplazameSharedServices #- name: Login to Amazon ECR # id: ecrlogin From 5bef3b79b35351e14fb0c39e312a1e9e7b4f11b6 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 16:03:10 +0100 Subject: [PATCH 33/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index c2aaf82..748ec8b 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -66,7 +66,7 @@ jobs: - name: Get cache env: AWS_PROFILE: AplazameSharedServices - s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz + s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz --profile AplazameSharedServices run: | set -e From d0e3e76ffd0348547915c3a356853bbeeec82741 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 16:10:55 +0100 Subject: [PATCH 34/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 748ec8b..83bcc17 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -85,7 +85,7 @@ jobs: set -e MATCHES=$(aws s3 ls ${s3Path} | wc -l) - [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} + [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} --profile AplazameSharedServices exit 0 - name: Check syntax @@ -101,4 +101,4 @@ jobs: env: AWS_PROFILE: Aplazame run: | - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame From 487ac3bf64253c371d5417560c0b6d056a1c9061 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 16:15:01 +0100 Subject: [PATCH 35/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 83bcc17..264f685 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -65,11 +65,11 @@ jobs: - name: Get cache env: - AWS_PROFILE: AplazameSharedServices - s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz --profile AplazameSharedServices + s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | set -e + export AWS_PROFILE=AplazameSharedServices aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz aws s3 cp --quiet ${s3Path} cache.tar.gz From 3a63857f38144686562491c6335262dd55501743 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 16:22:49 +0100 Subject: [PATCH 36/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 264f685..0747d95 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -67,12 +67,11 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - set -e - export AWS_PROFILE=AplazameSharedServices - aws s3 cp --quiet ${s3Path} cache.tar.gz || exit 0 + aws sts get-caller-identity --profile AplazameSharedServices + aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz - aws s3 cp --quiet ${s3Path} cache.tar.gz + aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices - name: Composer Install run: composer install --prefer-dist From fe7914398e974f46fb8ceefc4789149794e6a0ed Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Thu, 15 Jan 2026 16:58:01 +0100 Subject: [PATCH 37/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 0747d95..77291b7 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -56,12 +56,6 @@ jobs: role-to-assume: ${{ vars.AWS_OIDC_ROLE_TF_PRO }} role-session-name: ${{ github.run_id }} aws-region: ${{ vars.WZ_OIDC_AWS_REGION }} - - #- name: Login to Amazon ECR - # id: ecrlogin - # uses: aws-actions/amazon-ecr-login@062b18b96a7aff071d4dc91bc00c4c1a7945b076 #V2 - # with: - # registries: ${{ env.AWS_ACCOUNT }} - name: Get cache env: @@ -78,12 +72,11 @@ jobs: - name: Upload cache env: - AWS_PROFILE: AplazameSharedServices s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | set -e - MATCHES=$(aws s3 ls ${s3Path} | wc -l) + MATCHES=$(aws s3 ls ${s3Path} --profile AplazameSharedServices| wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} --profile AplazameSharedServices exit 0 @@ -97,7 +90,5 @@ jobs: run: make zip - name: Deploy to S3 - env: - AWS_PROFILE: Aplazame run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame From e832d890c798604781988418295bb18365f74d4c Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Fri, 16 Jan 2026 14:28:10 +0100 Subject: [PATCH 38/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 77291b7..5884127 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -44,7 +44,7 @@ jobs: - name: Install AWS CLI run: | - sudo apt-get install unzip curl -y + sudo apt-get install unzip zip curl -y curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" unzip awscliv2.zip sudo ./aws/install --update From 6165b9b314ed15fda2485c509c0cbe7c4f80876c Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Fri, 16 Jan 2026 14:32:05 +0100 Subject: [PATCH 39/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 5884127..5ed9ef0 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -87,8 +87,11 @@ jobs: run: make style - name: Create Bundle - run: make zip - - - name: Deploy to S3 run: | - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame + rm -f aplazame/config*.xml || true + rm -f aplazame.latest.zip + zip -r aplazame.latest.zip aplazame + + #- name: Deploy to S3 + # run: | + # aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame From a8aa1f138fdb21818414648e602b9a610b356721 Mon Sep 17 00:00:00 2001 From: adrianmartinaplazame Date: Fri, 16 Jan 2026 14:35:09 +0100 Subject: [PATCH 40/64] Update sonar-and-test-S3.yaml --- .github/workflows/sonar-and-test-S3.yaml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 5ed9ef0..d2bf9ba 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -62,7 +62,6 @@ jobs: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | set -e - aws sts get-caller-identity --profile AplazameSharedServices aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices @@ -74,7 +73,6 @@ jobs: env: s3Path: s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/v1-dependencies-${{ github.sha }}.tar.gz run: | - set -e MATCHES=$(aws s3 ls ${s3Path} --profile AplazameSharedServices| wc -l) [ "$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz ${foldersCache} && aws s3 cp --quiet cache.tar.gz ${s3Path} --profile AplazameSharedServices @@ -87,11 +85,8 @@ jobs: run: make style - name: Create Bundle - run: | - rm -f aplazame/config*.xml || true - rm -f aplazame.latest.zip - zip -r aplazame.latest.zip aplazame + run: make zip - #- name: Deploy to S3 - # run: | - # aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame + - name: Deploy to S3 + run: | + aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame From 0841eb23b19674112df9e860faa8cd62dd738f46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 19 Jan 2026 09:09:39 +0100 Subject: [PATCH 41/64] install zip --- .github/workflows/sonar-and-test-S3.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index d2bf9ba..d701154 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -85,7 +85,9 @@ jobs: run: make style - name: Create Bundle - run: make zip + run: | + sudo apt update && sudo apt install zip -y + make zip - name: Deploy to S3 run: | From 72fe116d157f405da8ceb7010f6a425016ceef48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 19 Jan 2026 09:17:29 +0100 Subject: [PATCH 42/64] rm Jenkinfile and manifests --- Jenkinsfile | 188 ------------------------------------- jenkins/jenkins-sonar.yaml | 20 ---- jenkins/php.yaml | 24 ----- 3 files changed, 232 deletions(-) delete mode 100644 Jenkinsfile delete mode 100644 jenkins/jenkins-sonar.yaml delete mode 100644 jenkins/php.yaml diff --git a/Jenkinsfile b/Jenkinsfile deleted file mode 100644 index 4e4241b..0000000 --- a/Jenkinsfile +++ /dev/null @@ -1,188 +0,0 @@ -library "aplazame-shared-library" - -pipeline { - agent { - kubernetes { - yamlFile "/jenkins/php.yaml" - } - } - environment { - FOLDER = "dist" - foldersCache = '"vendor/"' - } - options { - disableConcurrentBuilds() - ansiColor('xterm') - } - stages { - stage('Test Sonarqube') { - when { - not { - tag "*" - } - } - agent { - kubernetes { - yamlFile "/jenkins/jenkins-sonar.yaml" - } - } - environment { - SONAR_TEST = credentials('SONAR_TEST') - CODE_SOURCE_DEFAULT = "aplazame" - } - steps { - scmSkip() - container('sonar') { - sonarScan(SONAR_TEST,CODE_SOURCE_DEFAULT) - } - } - } - stage("Get cache") { - when { - not { - tag "*" - } - } - steps { - script { - HASH = sh(script: 'md5sum composer.json | awk \'{print \$1}\'', returnStdout: true).trim() - CACHE_KEY = 'v1-dependencies-' + HASH - - container('php') { - sh """ - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - aws s3 cp --quiet s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/${CACHE_KEY} cache.tar.gz || exit 0 - [ -f cache.tar.gz ] && tar -xf cache.tar.gz - """ - //loadCache(CACHE_KEY) - } - } - } - } - stage("Composer Install") { - when { - not { - tag "*" - } - } - steps { - container('php') { - sh """ - composer install -n --prefer-dist - """ - } - } - } - stage("Upload Cache") { - when { - not { - tag "*" - } - } - steps { - container('php') { - sh """ - load-config - export AWS_PROFILE=AplazameSharedServices - set -e - MATCHES=\$(aws s3 ls s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/${CACHE_KEY} | wc -l) - [ "\$MATCHES" = "0" ] && [ ! -f cache.tar.gz ] && tar -czf cache.tar.gz vendor/ && aws s3 cp --quiet cache.tar.gz s3://aplazameshared-jenkins-cache/Aplazame-Backend/prestashop/${CACHE_KEY} - exit 0 - """ - //saveCache(CACHE_KEY,["${foldersCache}"]) - } - } - } - stage("Check Syntax") { - when { - not { - tag "*" - } - } - steps { - container('php') { - sh """ - make syntax.checker - """ - } - } - } - stage("CS Style") { - when { - not { - tag "*" - } - } - steps { - container('php') { - sh """ - make style - """ - } - } - } - - stage("Create bundle") { - when { - branch 'master' - } - steps { - container('php') { - sh """ - make zip - """ - } - } - } - stage("Deploy to S3") { - when { - branch 'master' - } - steps { - scmSkip() - - timeout(time: 15, unit: "MINUTES") { - script { - slackSend failOnError: true, color: '#8000FF', channel: '#backend-pipelines', message: "You need :hand: intervention in ${currentBuild.fullDisplayName} (<${env.BUILD_URL}console|Open here>)", username: "Jenkins CI" - input id: 'ReleaseApproval', message: 'Deploy to S3?', ok: 'Yes' - } - } - container('php') { - sh """ - echo "****************Deploy to S3**********" - load-config - export AWS_PROFILE=Aplazame - aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ - """ - } - } - } - stage("Create Release") { - when { - branch 'master' - } - environment { - GITHUB_TOKEN = credentials('gh-releases-token-old') - } - steps { - scmSkip() - timeout(time: 15, unit: "MINUTES") { - script { - slackSend failOnError: true, color: '#8000FF', channel: '#backend-pipelines', message: "You need :hand: intervention in ${currentBuild.fullDisplayName} (<${env.BUILD_URL}console|Open here>)", username: "Jenkins CI" - input id: 'ReleaseApproval', message: 'Create release for pro?', ok: 'Yes' - } - } - container('php') { - sh """ - echo "***************Create Release***************" - export APP_VERSION="\$(cat Makefile | grep version | cut -d '=' -f2)" - echo \$APP_VERSION - gh release create \$APP_VERSION --notes "Release created by Jenkins.
Build: $BUILD_TAG;$BUILD_URL>" - """ - } - } - } - } -} diff --git a/jenkins/jenkins-sonar.yaml b/jenkins/jenkins-sonar.yaml deleted file mode 100644 index 8f5d698..0000000 --- a/jenkins/jenkins-sonar.yaml +++ /dev/null @@ -1,20 +0,0 @@ ---- -apiVersion: v1 -kind: Pod -metadata: - name: apptest -spec: - serviceAccountName: aplazame-appdeployer - serviceAccount: aplazame-appdeployer - securityContext: - fsGroup: 1000 - containers: - - name: sonar - image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/sonar-scanner:4.6.2.2472_2 - imagePullPolicy: Always - tty: true - resources: - limits: - cpu: 1 - memory: 3Gi - restartPolicy: Never diff --git a/jenkins/php.yaml b/jenkins/php.yaml deleted file mode 100644 index 69db2e2..0000000 --- a/jenkins/php.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: -spec: - #serviceAccountName: aplazame-appdeployer - serviceAccount: aplazame-frontdeployer - securityContext: - fsGroup: 1000 - containers: - - name: php - image: 666356151544.dkr.ecr.eu-central-1.amazonaws.com/tools/php:7.3.9_v2 - imagePullPolicy: Always - command: - - cat - tty: true - resources: - requests: - #memory: 200Mi - memory: 2Gi - cpu: 200m - limits: - #memory: 450Mi - memory: 4Gi - cpu: 500m From 66f3288093926505ba431c4e219938945b71b965 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 19 Jan 2026 09:38:27 +0100 Subject: [PATCH 43/64] clean env var --- .github/workflows/sonar-and-test-S3.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index d701154..e2db4d5 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -11,7 +11,6 @@ env: CODE_SOURCE_DEFAULT: "aplazame" AWS_REGION: 'eu-central-1' AWS_ACCOUNT: '666356151544' - ROLE_OIDC: 'arn:aws:iam::666356151544:role/ghaAdministratorAccessAplazameSharedServicesTf' permissions: From fbb20bb7ac90b2ca2ac9a447f73d96a91b0d670d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:26:01 +0100 Subject: [PATCH 44/64] add Create Github Release --- .github/workflows/sonar-and-test-S3.yaml | 28 ++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index e2db4d5..c14c4c8 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -91,3 +91,31 @@ jobs: - name: Deploy to S3 run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame + + - name: Notify Slack for approval + uses: slackapi/slack-github-action@v1.27.0 + with: + channel-id: backend-pipelines + slack-message: | + You need :hand: intervention in ${{ github.workflow }} #${{ github.run_number }} + <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|Open here> + env: + SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} + + - name: Manual approval + uses: trstringer/manual-approval@v1 + with: + approvers: user1,user2 + minimum-approvals: 1 + instructions: "Create release for prod?" + + - name: Create GitHub Release + env: + GITHUB_TOKEN: ${{ secrets.gh-releases-token-old }} + run: | + echo "***************Create Release***************" + APP_VERSION=$(grep version Makefile | cut -d '=' -f2) + echo "$APP_VERSION" + + gh release create "$APP_VERSION" \ + --notes "Release created by GitHub Actions" From 2c484dc203b3cd28acf5b7df86c03809770c3634 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:30:32 +0100 Subject: [PATCH 45/64] fix --- .github/workflows/sonar-and-test-S3.yaml | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index c14c4c8..2989af0 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -91,23 +91,6 @@ jobs: - name: Deploy to S3 run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame - - - name: Notify Slack for approval - uses: slackapi/slack-github-action@v1.27.0 - with: - channel-id: backend-pipelines - slack-message: | - You need :hand: intervention in ${{ github.workflow }} #${{ github.run_number }} - <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|Open here> - env: - SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }} - - - name: Manual approval - uses: trstringer/manual-approval@v1 - with: - approvers: user1,user2 - minimum-approvals: 1 - instructions: "Create release for prod?" - name: Create GitHub Release env: From 971c0348a8351100c2ee2bb3575e4675f4ce9ef9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:34:24 +0100 Subject: [PATCH 46/64] install gh --- .github/workflows/sonar-and-test-S3.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 2989af0..72e5d69 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -96,6 +96,7 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.gh-releases-token-old }} run: | + sudo apt-get install gh -y echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" From 9cd7f8304775f338835161da22d2a352491d4f00 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:38:29 +0100 Subject: [PATCH 47/64] gh login --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 72e5d69..90acba1 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -100,6 +100,6 @@ jobs: echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" - + gh auth login --with-token < $GITHUB_TOKEN gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" From c722db2cc1bf14e1dd1f1cc80436a3f5e3137510 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:43:05 +0100 Subject: [PATCH 48/64] fix --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 90acba1..2b2a63f 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -100,6 +100,6 @@ jobs: echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" - gh auth login --with-token < $GITHUB_TOKEN + gh auth login gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" From 43e70b39f1bada1e3ce076d248d4e741b26a6038 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:47:45 +0100 Subject: [PATCH 49/64] fix2 --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 2b2a63f..f423ee4 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -100,6 +100,6 @@ jobs: echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" - gh auth login + gh auth login --with-token $GITHUB_TOKEN gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" From c4fdbf6e5709784de103d5e0cd24e6fd02c83266 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 16:55:33 +0100 Subject: [PATCH 50/64] change login gh --- .github/workflows/sonar-and-test-S3.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index f423ee4..0a63ec8 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -100,6 +100,6 @@ jobs: echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" - gh auth login --with-token $GITHUB_TOKEN - gh release create "$APP_VERSION" \ - --notes "Release created by GitHub Actions" + GH_TOKEN="$GITHUB_TOKEN" \ + gh release create "$APP_VERSION" \ + --notes "Release created by GitHub Actions" From f8b51e24680c0bfb266ce4eced9c7420ae617c2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 17:03:19 +0100 Subject: [PATCH 51/64] fix3 --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 0a63ec8..2392935 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -94,7 +94,7 @@ jobs: - name: Create GitHub Release env: - GITHUB_TOKEN: ${{ secrets.gh-releases-token-old }} + GITHUB_TOKEN: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} run: | sudo apt-get install gh -y echo "***************Create Release***************" From 576845023abf880559d4786eb9be6d803e3dbacc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 17:11:47 +0100 Subject: [PATCH 52/64] fix GH_TOKEN --- .github/workflows/sonar-and-test-S3.yaml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 2392935..dc54d63 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -94,12 +94,10 @@ jobs: - name: Create GitHub Release env: - GITHUB_TOKEN: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} + GH_TOKEN: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} run: | sudo apt-get install gh -y echo "***************Create Release***************" APP_VERSION=$(grep version Makefile | cut -d '=' -f2) echo "$APP_VERSION" - GH_TOKEN="$GITHUB_TOKEN" \ - gh release create "$APP_VERSION" \ - --notes "Release created by GitHub Actions" + gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" From eb5e8b0c78cf94390b85fc6ab8b0498581f22e3a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 17:18:52 +0100 Subject: [PATCH 53/64] catch version makefile --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index dc54d63..0038a7f 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -98,6 +98,6 @@ jobs: run: | sudo apt-get install gh -y echo "***************Create Release***************" - APP_VERSION=$(grep version Makefile | cut -d '=' -f2) + APP_VERSION=$(grep "^version" Makefile | awk -F= '{print $2}' | xargs) echo "$APP_VERSION" gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" From 3a693b5316f99ff2d6812142826a1a47798d2451 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 20 Jan 2026 17:23:27 +0100 Subject: [PATCH 54/64] fix gh --notes --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 0038a7f..ac5b99e 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -100,4 +100,4 @@ jobs: echo "***************Create Release***************" APP_VERSION=$(grep "^version" Makefile | awk -F= '{print $2}' | xargs) echo "$APP_VERSION" - gh release create "$APP_VERSION" \ --notes "Release created by GitHub Actions" + gh release create "$APP_VERSION" --notes "Release created by GitHub Actions" From 4550177e04e17ee240eb013e450b3800cb93e23c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Wed, 21 Jan 2026 16:06:34 +0100 Subject: [PATCH 55/64] manual approve added --- .github/workflows/sonar-and-test-S3.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index ac5b99e..945000a 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -92,6 +92,17 @@ jobs: run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame + - name: Await Manual Approval + if: ${{ github.event_name == 'push' }} + uses: trstringer/manual-approval@v1 + with: + secret: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} + minimum-approvals: 1 + approvers: 'AR40873_wzk' + timeout-minutes: 10 + issue-title: "Manual Approval Required for Release (First change Makefile's App Version)" + issue-body: "Please approve or deny the deploy." + - name: Create GitHub Release env: GH_TOKEN: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} From 6194d797e668670d9bf8010e484ab9c00d5b7b61 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 22 Jan 2026 09:35:52 +0100 Subject: [PATCH 56/64] add 'environment' --- .github/workflows/sonar-and-test-S3.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 945000a..d3ff52b 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -27,6 +27,7 @@ jobs: test-composer: name: Test Composer Install needs: test-sonarqube + environment: pro runs-on: ${{ vars.AWS_RG_NAME_PRO }} steps: - name: Checkout code From 44687391e2da582bf6509572b2b351c4e66265e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 26 Jan 2026 14:09:37 +0100 Subject: [PATCH 57/64] issue --- .github/workflows/sonar-and-test-S3.yaml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index d3ff52b..1f51a99 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -16,6 +16,7 @@ env: permissions: contents: read id-token: write + issues: write jobs: test-sonarqube: @@ -43,12 +44,7 @@ jobs: tools: composer:v2 - name: Install AWS CLI - run: | - sudo apt-get install unzip zip curl -y - curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" - unzip awscliv2.zip - sudo ./aws/install --update - aws --version + uses: wz-aplazame/.github/.github/composite/aws@master - name: Configure aws credentials uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 From dc825445a1377055070fca87ddd4a2ec25641b32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 26 Jan 2026 15:30:28 +0100 Subject: [PATCH 58/64] remove environment --- .github/workflows/sonar-and-test-S3.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 1f51a99..2660681 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -28,7 +28,6 @@ jobs: test-composer: name: Test Composer Install needs: test-sonarqube - environment: pro runs-on: ${{ vars.AWS_RG_NAME_PRO }} steps: - name: Checkout code From f3bfce64b7e69650c1cf9648b6cf82fa7e1424f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Mon, 26 Jan 2026 15:58:19 +0100 Subject: [PATCH 59/64] remove action --- .github/workflows/sonar-and-test-S3.yaml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 2660681..4eb8386 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -43,7 +43,12 @@ jobs: tools: composer:v2 - name: Install AWS CLI - uses: wz-aplazame/.github/.github/composite/aws@master + run: | + sudo apt-get install unzip zip curl -y + curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip" + unzip awscliv2.zip + sudo ./aws/install --update + aws --version - name: Configure aws credentials uses: aws-actions/configure-aws-credentials@61815dcd50bd041e203e49132bacad1fd04d2708 #v5.1.1 From c448c06d0657ccfb1a386fb55f926cf55a0a3dd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 27 Jan 2026 13:17:55 +0100 Subject: [PATCH 60/64] added changes --- .github/workflows/sonar-and-test-S3.yaml | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 4eb8386..7758345 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -64,7 +64,6 @@ jobs: set -e aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices || exit 0 [ -f cache.tar.gz ] && tar -xf cache.tar.gz - aws s3 cp --quiet ${s3Path} cache.tar.gz --profile AplazameSharedServices - name: Composer Install run: composer install --prefer-dist @@ -82,14 +81,28 @@ jobs: run: make syntax.checker - name: Make Styleci happy + if: github.ref == 'refs/heads/master' run: make style - name: Create Bundle + if: github.ref == 'refs/heads/master' run: | sudo apt update && sudo apt install zip -y make zip - + + - name: Await Manual Approval + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }} + uses: trstringer/manual-approval@v1 + with: + secret: ${{ github.token }} + minimum-approvals: 1 + approvers: 'alexhernandezord' + timeout-minutes: 10 + issue-title: "Manual Approval Required for Release" + issue-body: "Please approve or deny the deploy." + - name: Deploy to S3 + if: github.ref == 'refs/heads/master' run: | aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame @@ -97,11 +110,11 @@ jobs: if: ${{ github.event_name == 'push' }} uses: trstringer/manual-approval@v1 with: - secret: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} + secret: ${{ github.token }} minimum-approvals: 1 - approvers: 'AR40873_wzk' + approvers: 'alexhernandezord' timeout-minutes: 10 - issue-title: "Manual Approval Required for Release (First change Makefile's App Version)" + issue-title: "Manual Approval Required for Github Release" issue-body: "Please approve or deny the deploy." - name: Create GitHub Release From 8531738e014976a941922a3318cb67beee86549a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Tue, 27 Jan 2026 13:19:05 +0100 Subject: [PATCH 61/64] remove comment sonar --- .github/workflows/test-reusable-sonarqube.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-reusable-sonarqube.yml b/.github/workflows/test-reusable-sonarqube.yml index 943769d..99e8aca 100644 --- a/.github/workflows/test-reusable-sonarqube.yml +++ b/.github/workflows/test-reusable-sonarqube.yml @@ -21,4 +21,4 @@ jobs: uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9 #v7.0.0 env: SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - #SONAR_HOST_URL: ${{ vars.SONAR_HOST_URL }} + From cdabd22ccdd83294deba2ffd5f0753e2bafe627b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 29 Jan 2026 08:52:17 +0100 Subject: [PATCH 62/64] fix --- .github/workflows/sonar-and-test-S3.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 7758345..d588e5c 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -107,7 +107,7 @@ jobs: aws s3 cp --acl public-read aplazame.latest.zip s3://aplazame/modules/prestashop/ --profile Aplazame - name: Await Manual Approval - if: ${{ github.event_name == 'push' }} + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }} uses: trstringer/manual-approval@v1 with: secret: ${{ github.token }} @@ -118,6 +118,7 @@ jobs: issue-body: "Please approve or deny the deploy." - name: Create GitHub Release + if: github.ref == 'refs/heads/master' env: GH_TOKEN: ${{ secrets.AP_GH_RELEASE_TOKEN_OLD }} run: | From 1be62a2fcca417b4195fcf72bf3e9d75a4403a5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Thu, 29 Jan 2026 08:56:26 +0100 Subject: [PATCH 63/64] cambios implementados --- .github/workflows/sonar-and-test-S3.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index d588e5c..0525293 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -80,7 +80,7 @@ jobs: - name: Check syntax run: make syntax.checker - - name: Make Styleci happy + - name: CS Style if: github.ref == 'refs/heads/master' run: make style From 8107cec2239f238927f7ceb2e2f6d53426ac3be5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Juan=20Rold=C3=A1n=20Manche=C3=B1o?= Date: Fri, 30 Jan 2026 09:00:40 +0100 Subject: [PATCH 64/64] remove branch workflow --- .github/workflows/sonar-and-test-S3.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/sonar-and-test-S3.yaml b/.github/workflows/sonar-and-test-S3.yaml index 0525293..4a77d91 100644 --- a/.github/workflows/sonar-and-test-S3.yaml +++ b/.github/workflows/sonar-and-test-S3.yaml @@ -81,7 +81,6 @@ jobs: run: make syntax.checker - name: CS Style - if: github.ref == 'refs/heads/master' run: make style - name: Create Bundle