Skip to content

8.5 runs

8.5 runs #273

Workflow file for this run

name: Build Artifacts
on:
push:
paths-ignore:
- '.cloudflare/pages/functions/\[\[path\]\].js'
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
generate-lib-group-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.libgroups }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Install docker-compose
run: sudo apt update && sudo apt install docker-compose -y
- name: Install NPM packages
run: npm ci
- name: Generate JSON array of directories
id: set-matrix
run: |
make --debug=basic dynamic-libs.json WITH_SDL=dynamic
jq -c . dynamic-libs.json
echo "libgroups=$(jq -c . dynamic-libs.json)" >> "$GITHUB_OUTPUT"
- name: Cache Docker image
id: cache-docker-image
uses: actions/cache@v3
with:
path: /tmp/builder-image.tar
key: ${{ runner.os }}-docker-${{ hashFiles('emscripten-builder.dockerfile') }}
- name: Load builder image if cached
if: steps.cache-docker-image.outputs.cache-hit == 'true'
run: docker load -i /tmp/builder-image.tar && rm -rf /tmp/builder-image.tar
- name: Create builder image (if not cached)
if: steps.cache-docker-image.outputs.cache-hit != 'true'
run: |
time make --debug=basic image
docker save -o /tmp/builder-image.tar seanmorris/php-emscripten-builder:latest
build-libs:
name: Build Shared Objects
runs-on: ubuntu-latest
needs: [generate-lib-group-matrix]
strategy:
matrix:
libgroup: ${{ fromJSON(needs.generate-lib-group-matrix.outputs.matrix) }}
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Install NPM packages
run: npm ci
- name: Install docker-compose
run: sudo apt update && sudo apt install docker-compose -y
- name: Import configuration
run: cp -p .github/.env_8.4.dynamic.ci .env
- name: Cache Docker image
id: cache-docker-image
uses: actions/cache@v3
with:
path: /tmp/builder-image.tar
key: ${{ runner.os }}-docker-${{ hashFiles('emscripten-builder.dockerfile') }}
- name: Load builder image if cached
if: steps.cache-docker-image.outputs.cache-hit == 'true'
run: docker load -i /tmp/builder-image.tar && rm -rf /tmp/builder-image.tar
- name: Create builder image (if not cached)
if: steps.cache-docker-image.outputs.cache-hit != 'true'
run: |
time make --debug=basic image
docker save -o /tmp/builder-image.tar seanmorris/php-emscripten-builder:latest
- name: Spin up docker-network
run: docker network create phpwasm_default
- name: Build shared libraries
run: time make --debug=basic ${{ matrix.libgroup }} WITH_SDL=dynamic
- name: Cache executables
run: find ./third_party -name .git -prune -o -type f -executable -print > ./.cache/executables-${{ matrix.libgroup }}.list
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-dependencies-${{ matrix.libgroup }}.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-dependencies-${{ matrix.libgroup }}.tar.gz' \
third_party \
packages \
.cache \
lib
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: php-dependencies-${{ matrix.libgroup }}
path: php-dependencies-${{ matrix.libgroup }}.tar.gz
compression-level: 0
build-php-dynamic:
needs: [build-libs]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
uses: ./.github/workflows/build-step.yaml
with:
phpVersion: ${{ matrix.phpVersion }}
libType: dynamic
build-php-shared:
needs: [build-libs]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
uses: ./.github/workflows/build-step.yaml
with:
phpVersion: ${{ matrix.phpVersion }}
libType: shared
build-php-static:
needs: []
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
uses: ./.github/workflows/build-step.yaml
with:
phpVersion: ${{ matrix.phpVersion }}
libType: static
test-node-dynamic:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/dynamic libs
needs: [build-php-dynamic]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['dynamic']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-uncompressed-${{ matrix.phpVersion }}-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-node-shared:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/shared libs
needs: [build-php-shared]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['shared']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-uncompressed-${{ matrix.phpVersion }}-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-node-static:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/static libs
needs: [build-php-static]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['static']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-uncompressed-${{ matrix.phpVersion }}-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-browser-dynamic:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-dynamic]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['dynamic']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-browser-shared:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-shared]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['shared']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-browser-static:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-static]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['static']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-dynamic:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-dynamic]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['dynamic']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-shared:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-shared]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['shared']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-static:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs
needs: [build-php-static]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['static']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-uncompressed-*-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
compress-dynamic-packages:
name: Compress PHP w/${{ matrix.libType }} libs
runs-on: ubuntu-latest
needs:
- test-node-dynamic
- test-browser-dynamic
- test-cgi-node-dynamic
strategy:
matrix:
libType: ['dynamic']
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-uncompressed-*-${{ matrix.libType }}
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-uncompressed-*-${{ matrix.libType }}.tar.gz; do
tar -xzf ${TAR}
done;
- name: Compress php-wasm
run: ./compress-package.sh packages/php-wasm
- name: Compress php-cgi-wasm
run: ./compress-package.sh packages/php-cgi-wasm
- name: Compress php-cli-wasm
run: ./compress-package.sh packages/php-cli-wasm
- name: Compress php-dbg-wasm
run: ./compress-package.sh packages/php-dbg-wasm
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-compressed-${{ matrix.libType }}.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-compressed-${{ matrix.libType }}.tar.gz' \
third_party \
packages \
.cache \
lib
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: php-compressed-${{ matrix.libType }}
path: php-compressed-${{ matrix.libType }}.tar.gz
compression-level: 0
compress-shared-packages:
name: Compress PHP w/${{ matrix.libType }} libs
runs-on: ubuntu-latest
needs:
- test-node-shared
- test-browser-shared
- test-cgi-node-shared
strategy:
matrix:
libType: ['shared']
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-uncompressed-*-${{ matrix.libType }}
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-uncompressed-*-${{ matrix.libType }}.tar.gz; do
tar -xzf ${TAR}
done;
- name: Compress php-wasm
run: ./compress-package.sh packages/php-wasm
- name: Compress php-cgi-wasm
run: ./compress-package.sh packages/php-cgi-wasm
- name: Compress php-cli-wasm
run: ./compress-package.sh packages/php-cli-wasm
- name: Compress php-dbg-wasm
run: ./compress-package.sh packages/php-dbg-wasm
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-compressed-${{ matrix.libType }}.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-compressed-${{ matrix.libType }}.tar.gz' \
third_party \
packages \
.cache \
lib
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: php-compressed-${{ matrix.libType }}
path: php-compressed-${{ matrix.libType }}.tar.gz
compression-level: 0
compress-static-packages:
name: Compress PHP w/${{ matrix.libType }} libs
runs-on: ubuntu-latest
needs:
- test-node-static
- test-browser-static
- test-cgi-node-static
strategy:
matrix:
libType: ['static']
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-uncompressed-*-${{ matrix.libType }}
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-uncompressed-*-${{ matrix.libType }}.tar.gz; do
tar -xzf ${TAR}
done;
- name: Compress php-wasm
run: ./compress-package.sh packages/php-wasm
- name: Compress php-cgi-wasm
run: ./compress-package.sh packages/php-cgi-wasm
- name: Compress php-cli-wasm
run: ./compress-package.sh packages/php-cli-wasm
- name: Compress php-dbg-wasm
run: ./compress-package.sh packages/php-dbg-wasm
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-compressed-${{ matrix.libType }}.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-compressed-${{ matrix.libType }}.tar.gz' \
third_party \
packages \
.cache \
lib
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: php-compressed-${{ matrix.libType }}
path: php-compressed-${{ matrix.libType }}.tar.gz
compression-level: 0
test-node-dynamic-compressed:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-dynamic-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['dynamic']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-node-shared-compressed:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-shared-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['shared']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-node-static-compressed:
name: Test ${{ matrix.testType }} ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-static-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
testType: ['node', 'deno']
libType: ['static']
uses: ./.github/workflows/test-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
testType: ${{ matrix.testType }}
libType: ${{ matrix.libType }}
test-browser-dynamic-compressed:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-dynamic-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['dynamic']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-browser-shared-compressed:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-shared-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['shared']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-browser-static-compressed:
name: Test Browser ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-static-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['static']
uses: ./.github/workflows/test-browser-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-dynamic-compressed:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-dynamic-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['dynamic']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-shared-compressed:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-shared-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['shared']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
test-cgi-node-static-compressed:
name: Test CGI Node ${{ matrix.phpVersion }} w/${{ matrix.libType }} libs (compressed)
needs: [compress-static-packages]
strategy:
matrix:
phpVersion: ['8.5', '8.4', '8.3', '8.2', '8.1', '8.0']
libType: ['static']
uses: ./.github/workflows/test-cgi-node-step.yaml
with:
artifactPattern: php-compressed-${{ matrix.libType }}
phpVersion: ${{ matrix.phpVersion }}
libType: ${{ matrix.libType }}
index-packages:
name: Post nightly build to Cloudflare
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop'
runs-on: ubuntu-latest
needs:
- test-browser-dynamic-compressed
- test-node-dynamic-compressed
- test-cgi-node-dynamic-compressed
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-compressed-dynamic
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-compressed-*.tar.gz; do
tar -xzf ${TAR}
done;
- name: Install Brotli & GZip
run: sudo apt install brotli gzip
- name: Index Package Directories
run: ./.github/bin/index-dirs.sh packages/
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-indexed-packages.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-indexed-packages.tar.gz' \
packages \
.cache
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: php-indexed-packages
path: php-indexed-packages.tar.gz
compression-level: 0
- name: Set up vars
run: |
echo "STAMP=$( date -u +'%Y%m%d%H%M%S' )" >> $GITHUB_ENV
echo "SHORT_SHA=$( git rev-parse --short $GITHUB_SHA )" >> $GITHUB_ENV
- name: Upload to Cloudflare
uses: ryand56/r2-upload-action@latest
with:
r2-account-id: ${{ secrets.R2_ACCOUNT_ID }}
r2-access-key-id: ${{ secrets.R2_ACCESS_KEY_ID }}
r2-secret-access-key: ${{ secrets.R2_SECRET_ACCESS_KEY }}
destination-dir: ${{ env.STAMP }}-${{ env.SHORT_SHA }}/
r2-bucket: php-wasm
source-dir: packages
- name: Install Wrangler
run: npm install -g wrangler
- name: Deploy Cloudflare Pages Function
run: |
cd .cloudflare/pages
wrangler pages deploy --branch=main --project-name=php-wasm-nightly
env:
CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_PAGES_API_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.R2_ACCOUNT_ID }}
- name: Notify Discord on success
if: ${{ success() }}
run: |
curl -H "Content-Type: application/json" \
-X POST \
-d "{\"content\": \"New nightly build available: https://nightly.php-wasm.seanmorr.is/${{ env.STAMP }}-${{ env.SHORT_SHA }}/\"}" \
${{ secrets.DISCORD_WEBHOOK_URL }}
build-demo:
name: Build Web Demo
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop'
runs-on: ubuntu-latest
needs:
- index-packages
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Disable man-db auto-update
run: |
echo "set man-db/auto-update false" | sudo debconf-communicate
sudo dpkg-reconfigure man-db
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-compressed-dynamic
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-compressed-*.tar.gz; do
tar -xzf ${TAR}
done;
- name: Download Index Artifact
uses: actions/download-artifact@v4
with:
pattern: php-indexed-packages
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-indexed-packages.tar.gz; do
tar -xzf ${TAR}
done;
- name: Ensure the demo uses local packages
run: cd demo-web; ./switch-packages.sh local; npm ci; cd ..;
- name: Build Web Demo
run: cd demo-web; ./switch-packages.sh local; npm run build; cd ..;
env:
CI: ''
- name: Copy packages into web demo
run: cp -rfv packages demo-web/build/nightly
- name: Take Snapshot
run: |
sudo chown -R ${USER}:${USER} .
sudo chmod -R u+rwX,go+rX .
tar --exclude=.git \
--format=posix \
--exclude='php-demo-web.tar.gz' \
--ignore-failed-read \
--warning=no-file-changed \
-czf 'php-demo-web.tar.gz' \
docs
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: php-demo-web
path: php-demo-web.tar.gz
compression-level: 0
deploy-docs:
name: Deploy Docs to GitHub Pages
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop'
runs-on: ubuntu-latest
needs:
- build-demo
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: github-pages
cancel-in-progress: true
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Download Artifact
uses: actions/download-artifact@v4
with:
pattern: php-demo-web
merge-multiple: true
path: ./
- name: Extract Artifact
run: |
for TAR in php-demo-web.tar.gz; do
tar -xzf ${TAR}
done;
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: './docs'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4