diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 2de9bede03..e734c4efc1 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -51,13 +51,13 @@ jobs: - 1025:1025 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Get Composer Cache Directory id: composer-cache run: | echo "::set-output name=dir::$(composer config cache-files-dir)" - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 27d5699759..5cae9a1f12 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -78,10 +78,10 @@ jobs: - name: Checkout code if: github.event_name == 'release' && (github.event.action == 'published' || github.event.action == 'prereleased' ) - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Checkout code if: github.event_name == 'schedule' && env.DEPLOY == 1 - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: ref: ${{ env.TAG_NAME }} @@ -180,7 +180,7 @@ jobs: - name: Upload binaries to release of TGZ if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.tar.gz @@ -189,7 +189,7 @@ jobs: overwrite: true - name: Upload binaries to release of ZIP if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.zip @@ -198,7 +198,7 @@ jobs: overwrite: true - name: Upload binaries to release of TGZ md5 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.tar.gz.checksum.md5 @@ -207,7 +207,7 @@ jobs: overwrite: true - name: Upload binaries to release of TGZ sha1 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.tar.gz.checksum.sha1 @@ -216,7 +216,7 @@ jobs: overwrite: true - name: Upload binaries to release of TGZ sha256 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.tar.gz.checksum.sha256 @@ -225,7 +225,7 @@ jobs: overwrite: true - name: Upload binaries to release of ZIP md5 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.zip.checksum.md5 @@ -234,7 +234,7 @@ jobs: overwrite: true - name: Upload binaries to release of ZIP sha1 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.zip.checksum.sha1 @@ -243,7 +243,7 @@ jobs: overwrite: true - name: Upload binaries to release of ZIP sha256 checksum if: env.DEPLOY == 1 - uses: svenstaro/upload-release-action@v1-release + uses: svenstaro/upload-release-action@2.7.0 with: repo_token: ${{ secrets.GITHUB_TOKEN }} file: ${{ runner.workspace }}/${{ env.TAG_NAME }}.zip.checksum.sha256 diff --git a/.github/workflows/dockerbuild.yml b/.github/workflows/dockerbuild.yml index e6cdd862bc..792c771d56 100644 --- a/.github/workflows/dockerbuild.yml +++ b/.github/workflows/dockerbuild.yml @@ -21,7 +21,7 @@ jobs: strategy: fail-fast: false matrix: - php: [ '5.4', '5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1' ] + php: [ '5.4', '5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ] steps: - name: downcase REPO @@ -32,29 +32,53 @@ jobs: run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql mbstring" >> ${GITHUB_ENV} - echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} + echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} + echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive/debian-security" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 5.5 }} + run: | + echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} + echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} + echo "APCU=" >> ${GITHUB_ENV} echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} - - if: ${{ matrix.php == 5.5 || matrix.php == 5.6 }} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive/debian-security" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 5.6 }} run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} - echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} + echo "APCU=" >> ${GITHUB_ENV} echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} - - if: ${{ matrix.php >= 7.0 && matrix.php <= 7.3 }} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 7.0 }} + run: | + echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} + echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} + echo "APCU=apcu" >> ${GITHUB_ENV} + echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + - if: ${{ matrix.php >= 7.1 && matrix.php <= 7.3 }} run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} echo "APCU=apcu" >> ${GITHUB_ENV} echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=deb.debian.org" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=security.debian.org" >> ${GITHUB_ENV} - if: ${{ matrix.php >= 7.4 }} run: | echo "GD_OPTIONS=--with-freetype --with-jpeg" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} echo "APCU=apcu" >> ${GITHUB_ENV} echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=deb.debian.org" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=security.debian.org" >> ${GITHUB_ENV} - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 ## Used when creating multi-platform images # - name: Set up QEMU # uses: docker/setup-qemu-action@v2 @@ -65,7 +89,7 @@ jobs: run: echo "COMPOSE_FILE=docker-compose.yml:docker-compose.pgsql.yml:docker-compose.owaspzap.yml:docker-compose.owaspzap.daemon.yml" >> $GITHUB_ENV - name: Login to GitHub Container Registry - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} @@ -73,7 +97,7 @@ jobs: - name: Extract metadata (tags, labels) for Docker id: meta - uses: docker/metadata-action@v4 + uses: docker/metadata-action@v5 with: images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} tags: | @@ -86,7 +110,7 @@ jobs: type=match,prefix=${{ matrix.php }}-apache-,pattern=eccube2-weekly-(.*),group=1 - name: Build and export to Docker - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 with: context: . load: true @@ -97,6 +121,9 @@ jobs: GD_OPTIONS=${{ env.GD_OPTIONS }} EXT_INSTALL_ARGS=${{ env.EXT_INSTALL_ARGS }} APCU=${{ env.APCU }} + FORCE_YES=${{ env.FORCE_YES }} + APT_REPO=${{ env.APT_REPO }} + APT_SECURITY_REPO=${{ env.APT_SECURITY_REPO }} - name: Setup to EC-CUBE env: @@ -129,7 +156,7 @@ jobs: - run: git checkout composer.* ## see https://docs.github.com/ja/packages/managing-github-packages-using-github-actions-workflows/publishing-and-installing-a-package-with-github-actions#publishing-a-package-using-an-action - name: Push Docker image - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 if: success() with: context: . @@ -142,16 +169,19 @@ jobs: GD_OPTIONS=${{ env.GD_OPTIONS }} EXT_INSTALL_ARGS=${{ env.EXT_INSTALL_ARGS }} APCU=${{ env.APCU }} + FORCE_YES=${{ env.FORCE_YES }} + APT_REPO=${{ env.APT_REPO }} + APT_SECURITY_REPO=${{ env.APT_SECURITY_REPO }} - name: Upload evidence if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-evidence path: 'test-results/' - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-logs path: data/logs diff --git a/.github/workflows/e2e-tests.yml b/.github/workflows/e2e-tests.yml index f12c5d3442..34c9b3dce1 100644 --- a/.github/workflows/e2e-tests.yml +++ b/.github/workflows/e2e-tests.yml @@ -29,7 +29,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 # - name: Create ADMIN_DIR # run: | @@ -72,13 +72,13 @@ jobs: - name: Upload evidence if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.tag }}-${{ matrix.db }}-evidence path: 'test-results/' - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-${{ matrix.db }}-logs path: data/logs @@ -89,7 +89,7 @@ jobs: fail-fast: false matrix: db: [ 'pgsql', 'mysql' ] - php: [ '5.4', '5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1' ] + php: [ '5.4', '5.5', '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ] include: - db: mysql dbport: '3306' @@ -109,25 +109,53 @@ jobs: run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql mbstring" >> ${GITHUB_ENV} - echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} - - if: ${{ matrix.php == 5.5 || matrix.php == 5.6 }} + echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} + echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive/debian-security" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 5.5 }} run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} - echo "APCU=apcu-4.0.11" >> ${GITHUB_ENV} - - if: ${{ matrix.php >= 7.0 && matrix.php <= 7.3 }} + echo "APCU=" >> ${GITHUB_ENV} + echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive/debian-security" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 5.6 }} + run: | + echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} + echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} + echo "APCU=" >> ${GITHUB_ENV} + echo "FORCE_YES=--force-yes" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + - if: ${{ matrix.php == 7.0 }} + run: | + echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} + echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} + echo "APCU=apcu" >> ${GITHUB_ENV} + echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=cloudfront.debian.net/debian-archive" >> ${GITHUB_ENV} + - if: ${{ matrix.php >= 7.1 && matrix.php <= 7.3 }} run: | echo "GD_OPTIONS=--with-freetype-dir=/usr/include --with-jpeg-dir=/usr/include" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} echo "APCU=apcu" >> ${GITHUB_ENV} + echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=deb.debian.org" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=security.debian.org" >> ${GITHUB_ENV} - if: ${{ matrix.php >= 7.4 }} run: | echo "GD_OPTIONS=--with-freetype --with-jpeg" >> ${GITHUB_ENV} echo "EXT_INSTALL_ARGS=gd zip mysqli pgsql opcache" >> ${GITHUB_ENV} echo "APCU=apcu" >> ${GITHUB_ENV} + echo "FORCE_YES=" >> ${GITHUB_ENV} + echo "APT_REPO=deb.debian.org" >> ${GITHUB_ENV} + echo "APT_SECURITY_REPO=security.debian.org" >> ${GITHUB_ENV} - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup environment env: @@ -142,7 +170,7 @@ jobs: sudo chown -R 1001:1000 zap sudo chmod -R g+w zap sh -c 'echo "> data/config/config.php' - docker build -t ec-cube2 --build-arg PHP_VERSION_TAG="${PHP_VERSION_TAG}" --build-arg GD_OPTIONS="${GD_OPTIONS}" --build-arg EXT_INSTALL_ARGS="${EXT_INSTALL_ARGS}" --build-arg APCU="${APCU}" . + docker build -t ec-cube2 --build-arg PHP_VERSION_TAG="${PHP_VERSION_TAG}" --build-arg GD_OPTIONS="${GD_OPTIONS}" --build-arg EXT_INSTALL_ARGS="${EXT_INSTALL_ARGS}" --build-arg APCU="${APCU}" --build-arg FORCE_YES="${FORCE_YES}" --build-arg APT_REPO="${APT_REPO}" --build-arg APT_SECURITY_REPO="${APT_SECURITY_REPO}" . docker tag ec-cube2 ghcr.io/ec-cube/ec-cube2-php:${PHP_VERSION_TAG}-apache TAG=${PHP_VERSION_TAG}-apache docker-compose up -d @@ -185,13 +213,13 @@ jobs: run: yarn test:e2e e2e-tests/test/installer/installer.test.ts - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-${{ matrix.db }}-logs path: html/install/temp/install.log* - name: Upload evidence if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-${{ matrix.db }}-evidence path: 'test-results/' diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 68af623869..0d33224d88 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -20,7 +20,7 @@ jobs: fail-fast: false matrix: operating-system: [ ubuntu-22.04 ] - php: [ '5.4', '5.5', '5.6', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2snapshot' ] + php: [ '5.4', '5.5', '5.6', '7.1', '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ] db: [ mysql, pgsql ] include: - db: mysql @@ -61,13 +61,13 @@ jobs: - 1025:1025 steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Get Composer Cache Directory id: composer-cache run: | echo "::set-output name=dir::$(composer config cache-files-dir)" - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} @@ -131,15 +131,18 @@ jobs: - run: sleep 1 - name: Run to PHPUnit - run: data/vendor/bin/phpunit --exclude-group classloader + run: data/vendor/bin/phpunit --exclude-group classloader,mysql_prepare - name: Run to PHPUnit classloader run: data/vendor/bin/phpunit --group classloader + - name: Run to PHPUnit mysql_prepare + # XXX 連続してテストを実行すると、何故か MySQL の prepare statement に失敗するため個別に実行する + run: data/vendor/bin/phpunit --group mysql_prepare - name: Run to PHPUnit SessionFactory run: data/vendor/bin/phpunit tests/class/SC_SessionFactoryTest.php - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-${{ matrix.db }}-logs path: data/logs @@ -150,17 +153,17 @@ jobs: strategy: fail-fast: false matrix: - operating-system: [ windows-2019 ] + operating-system: [ windows-2022 ] php: [ 5.5, 5.6, 7.1, 7.2, 7.3, 7.4 ] steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Get Composer Cache Directory id: composer-cache run: | echo "::set-output name=dir::$(composer config cache-files-dir)" - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} key: ${{ runner.os }}-composer-${{ hashFiles('**\composer.lock') }} @@ -177,11 +180,21 @@ jobs: - name: composer install run: composer install --no-interaction -o - - name: Setup to database + - name: Start PostgreSQL on Windows + # see https://www.cybertec-postgresql.com/en/postgresql-github-actions-continuous-integration/ run: | - choco install -y mysql --version 5.7.18 - mysql --user=root -e "CREATE DATABASE eccube_db DEFAULT COLLATE=utf8_general_ci;" - mysql --user=root -e "GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION;FLUSH PRIVILEGES;" + echo $env:PGBIN >> $Env:GITHUB_PATH + $pgService = Get-Service -Name postgresql* + Set-Service -InputObject $pgService -Status running -StartupType automatic + Start-Process -FilePath "$env:PGBIN\pg_isready" -Wait -PassThru + $env:PGPASSWORD = 'root' + (Get-Content $env:PGDATA\postgresql.conf) | foreach { $_ -replace "#password_encryption = scram-sha-256","password_encryption = md5" } | Set-Content $env:PGDATA\postgresql.conf + (Get-Content $env:PGDATA\pg_hba.conf) | foreach { $_ -replace "scram-sha-256","md5" } | Set-Content $env:PGDATA\pg_hba.conf + Restart-Service -InputObject $pgService -Force + Start-Process -FilePath "$env:PGBIN\pg_isready" -Wait -PassThru + & $env:PGBIN\createuser -U postgres -d -R eccube_db_user + & $env:PGBIN\psql -U postgres -c "ALTER role eccube_db_user with password 'root';" postgres + & $env:PGBIN\createdb --owner=eccube_db_user eccube_db - name: Setup PHP uses: nanasess/setup-php@master @@ -190,16 +203,17 @@ jobs: - name: Setup to EC-CUBE env: - DB: mysql - USER: root - DBUSER: root - DBPASS: password + DB: pgsql + DBUSER: eccube_db_user + DBPASS: root DBNAME: eccube_db - DBPORT: 3306 + DBPORT: 5432 DBSERVER: 127.0.0.1 HTTP_URL: http://127.0.0.1:8085/ HTTPS_URL: http://127.0.0.1:8085/ - run: bash eccube_install.sh mysql + run: | + echo $PATH + bash eccube_install.sh pgsql shell: bash - run: sleep 1 shell: bash @@ -213,7 +227,7 @@ jobs: data/vendor/bin/phpunit tests/class/SC_SessionFactoryTest.php - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: windows-php${{ matrix.php }}-${{ matrix.db }}-logs path: data\logs diff --git a/.github/workflows/penetration-tests.yml b/.github/workflows/penetration-tests.yml index 8c1469dc5b..84e8ab692a 100644 --- a/.github/workflows/penetration-tests.yml +++ b/.github/workflows/penetration-tests.yml @@ -21,7 +21,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 # - name: Create ADMIN_DIR # run: | @@ -75,14 +75,14 @@ jobs: run: echo "ARTIFACT_NAME=$(echo ${GROUP} | sed 's,/,_,g')" >> $GITHUB_ENV - name: Upload evidence if: always() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: zap-${{ env.ARTIFACT_NAME}}-session path: zap/sessions - name: Upload logs if: failure() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: linux-php${{ matrix.php }}-${{ matrix.db }}-logs path: data/logs diff --git a/.github/workflows/phpstan.yml b/.github/workflows/phpstan.yml index e31932e55e..1564e9aa39 100644 --- a/.github/workflows/phpstan.yml +++ b/.github/workflows/phpstan.yml @@ -31,7 +31,7 @@ jobs: options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5 steps: - name: "Checkout" - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup PHP uses: nanasess/setup-php@master with: diff --git a/.github/workflows/security-checker.yml b/.github/workflows/security-checker.yml index 132ad217d8..f4aa93b154 100644 --- a/.github/workflows/security-checker.yml +++ b/.github/workflows/security-checker.yml @@ -9,6 +9,6 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Checking Security Vulnerabilities uses: symfonycorp/security-checker-action@v5 diff --git a/Dockerfile b/Dockerfile index 3c902a30f7..bff7982e1c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,11 +5,21 @@ FROM php:${TAG} ARG GD_OPTIONS="--with-freetype --with-jpeg" ARG EXT_INSTALL_ARGS="gd zip mysqli pgsql opcache" ARG APCU="apcu" -ARG FORCE_YES="--force-yes" +ARG FORCE_YES="" +ARG APT_REPO="deb.debian.org" +ARG APT_SECURITY_REPO="security.debian.org" + # See https://github.com/debuerreotype/debuerreotype/issues/10 RUN if [ ! -d /usr/share/man/man1 ]; then mkdir /usr/share/man/man1; fi RUN if [ ! -d /usr/share/man/man7 ]; then mkdir /usr/share/man/man7; fi +RUN if [ ! -e /etc/apt/sources.list ]; then touch /etc/apt/sources.list; fi # for bookworm +RUN sed -i s,deb.debian.org,${APT_REPO},g /etc/apt/sources.list; +RUN sed -i s,security.debian.org,${APT_SECURITY_REPO},g /etc/apt/sources.list; +RUN sed -i s,httpredir.debian.org,${APT_REPO},g /etc/apt/sources.list; # for jessie +RUN sed -i '/stretch-updates/d' /etc/apt/sources.list # for stretch +RUN sed -i '/jessie-updates/d' /etc/apt/sources.list # for jessie + # ext-gd: libfreetype6-dev libjpeg62-turbo-dev libpng-dev # ext-pgsql: libpq-dev # ext-zip: libzip-dev zlib1g-dev @@ -27,7 +37,7 @@ RUN apt-get update \ && rm -rf /var/lib/apt/lists/* RUN docker-php-ext-configure gd ${GD_OPTIONS} && docker-php-ext-install ${EXT_INSTALL_ARGS} -RUN pecl install ${APCU} && docker-php-ext-enable apcu +RUN if [[ ${APCU} ]]; then pecl install ${APCU} && docker-php-ext-enable apcu; fi # composer COPY --from=composer:2.2 /usr/bin/composer /usr/bin/composer @@ -64,4 +74,4 @@ COPY composer.lock ${ECCUBE_PREFIX}/composer.lock RUN composer install --no-scripts --no-autoloader --no-dev -d ${ECCUBE_PREFIX} COPY . ${ECCUBE_PREFIX} -RUN composer dumpautoload -o --apcu +RUN composer dumpautoload -o diff --git a/composer.lock b/composer.lock index e2b3078d0b..3301c0b141 100644 --- a/composer.lock +++ b/composer.lock @@ -8,23 +8,23 @@ "packages": [ { "name": "mobiledetect/mobiledetectlib", - "version": "2.8.41", + "version": "2.8.45", "source": { "type": "git", "url": "https://github.com/serbanghita/Mobile-Detect.git", - "reference": "fc9cccd4d3706d5a7537b562b59cc18f9e4c0cb1" + "reference": "96aaebcf4f50d3d2692ab81d2c5132e425bca266" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/serbanghita/Mobile-Detect/zipball/fc9cccd4d3706d5a7537b562b59cc18f9e4c0cb1", - "reference": "fc9cccd4d3706d5a7537b562b59cc18f9e4c0cb1", + "url": "https://api.github.com/repos/serbanghita/Mobile-Detect/zipball/96aaebcf4f50d3d2692ab81d2c5132e425bca266", + "reference": "96aaebcf4f50d3d2692ab81d2c5132e425bca266", "shasum": "" }, "require": { "php": ">=5.0.0" }, "require-dev": { - "phpunit/phpunit": "~4.8.35||~5.7" + "phpunit/phpunit": "~4.8.36" }, "type": "library", "autoload": { @@ -58,9 +58,15 @@ ], "support": { "issues": "https://github.com/serbanghita/Mobile-Detect/issues", - "source": "https://github.com/serbanghita/Mobile-Detect/tree/2.8.41" + "source": "https://github.com/serbanghita/Mobile-Detect/tree/2.8.45" }, - "time": "2022-11-08T18:31:26+00:00" + "funding": [ + { + "url": "https://github.com/serbanghita", + "type": "github" + } + ], + "time": "2023-11-07T21:57:25+00:00" }, { "name": "nanasess/mdb2", @@ -352,21 +358,22 @@ }, { "name": "pear/pear-core-minimal", - "version": "v1.10.11", + "version": "v1.10.14", "source": { "type": "git", "url": "https://github.com/pear/pear-core-minimal.git", - "reference": "68d0d32ada737153b7e93b8d3c710ebe70ac867d" + "reference": "a86fc145edb5caedbf96527214ce3cadc9de4a32" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pear/pear-core-minimal/zipball/68d0d32ada737153b7e93b8d3c710ebe70ac867d", - "reference": "68d0d32ada737153b7e93b8d3c710ebe70ac867d", + "url": "https://api.github.com/repos/pear/pear-core-minimal/zipball/a86fc145edb5caedbf96527214ce3cadc9de4a32", + "reference": "a86fc145edb5caedbf96527214ce3cadc9de4a32", "shasum": "" }, "require": { "pear/console_getopt": "~1.4", - "pear/pear_exception": "~1.0" + "pear/pear_exception": "~1.0", + "php": ">=5.4" }, "replace": { "rsky/pear-core-min": "self.version" @@ -396,7 +403,7 @@ "issues": "http://pear.php.net/bugs/search.php?cmd=display&package_name[]=PEAR", "source": "https://github.com/pear/pear-core-minimal" }, - "time": "2021-08-10T22:31:03+00:00" + "time": "2023-11-26T16:15:38+00:00" }, { "name": "pear/pear_exception", @@ -635,16 +642,16 @@ }, { "name": "setasign/fpdf", - "version": "1.8.5", + "version": "1.8.6", "source": { "type": "git", "url": "https://github.com/Setasign/FPDF.git", - "reference": "f4104a04c9a3f95c4c26a0a0531abebcc980987a" + "reference": "0838e0ee4925716fcbbc50ad9e1799b5edfae0a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Setasign/FPDF/zipball/f4104a04c9a3f95c4c26a0a0531abebcc980987a", - "reference": "f4104a04c9a3f95c4c26a0a0531abebcc980987a", + "url": "https://api.github.com/repos/Setasign/FPDF/zipball/0838e0ee4925716fcbbc50ad9e1799b5edfae0a0", + "reference": "0838e0ee4925716fcbbc50ad9e1799b5edfae0a0", "shasum": "" }, "require": { @@ -675,9 +682,9 @@ "pdf" ], "support": { - "source": "https://github.com/Setasign/FPDF/tree/1.8.5" + "source": "https://github.com/Setasign/FPDF/tree/1.8.6" }, - "time": "2022-11-18T07:02:00+00:00" + "time": "2023-06-26T14:44:25+00:00" }, { "name": "setasign/fpdi", @@ -2072,5 +2079,5 @@ "platform-overrides": { "php": "5.4.16" }, - "plugin-api-version": "2.3.0" + "plugin-api-version": "2.6.0" } diff --git a/data/Smarty/templates/admin/basis/point.tpl b/data/Smarty/templates/admin/basis/point.tpl index a78a906966..30fdceeeaf 100644 --- a/data/Smarty/templates/admin/basis/point.tpl +++ b/data/Smarty/templates/admin/basis/point.tpl @@ -24,7 +24,7 @@