Sporadic PHP Extension Installation Failure
theophileds opened this issue · comments
Describe the bug
The GitHub Action workflow is failing during the PHP setup, resulting in an exit code of 1. This issue occurs sporadically on self-hosted runners and we have no way of reproducing it.
I'm wondering if there are some communication failures with pecl and would be curious to know if others experience the same issue.
Run shivammathur/setup-php@2.30.2
/usr/bin/bash /home/runner/_work/_actions/shivammathur/setup-php/2.30.2/src/scripts/run.sh
==> Setup PHP
Error: The process '/usr/bin/bash' failed with exit code 1
Version
- I have checked releases, and the bug exists in the latest patch version of
v1
orv2
. -
v2
-
v1
Runners
- GitHub Hosted
- Self Hosted
Operating systems
Ubuntu-22
PHP versions
8.2
To Reproduce
- name: Setup PHP
uses: shivammathur/setup-php@2.30.2
with:
php-version: '8.2'
extensions: amqp-1.11.0, gd, gmp, soap, bcmath, apcu, redis
coverage: pcov
# Required for self-hosted runners
env:
runner: self-hosted
Expected behavior
Screenshots/Logs
Additional context
I managed to ssh into the runner and run:
sudo /usr/bin/bash /home/runner/_work/_actions/shivammathur/setup-php/2.30.2/src/scripts/run.sh
But it failed with spamming errors like:
PHP Warning: PHP Startup: Unable to load dynamic library 'amqp.so' (tried: /usr/lib/php/20220829/amqp.so (librabbitmq.so.4: cannot open shared object file: No such file or directory), /usr/lib/php/20220829/amqp.so.so (/usr/lib/php/20220829/amqp.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
But subsequent attempts on the same machine has worked successfully:
sudo /usr/bin/bash /home/runner/_work/_actions/shivammathur/setup-php/2.30.2/src/scripts/run.sh
==> Setup PHP
✓ PHP Found PHP 8.2.18
==> Setup Extensions
✓ amqp-2.1.2 Installed and enabled
✓ gd Enabled
✓ gmp Enabled
✓ soap Enabled
✓ bcmath Enabled
✓ apcu Enabled
✓ redis Enabled
✓ timezonedb Enabled
==> Setup Tools
✓ composer Added composer 2.7.2
==> Setup Coverage
✓ pcov.enabled=1 Added to php.ini
✓ pcov PCOV 1.0.11 enabled as coverage driver
==> Sponsor setup-php
✓ setup-php https://setup-php.com/sponsor
Having the same issue, but on self-hosted runner, using php 8.3.
After running the workflow again manually, it works.
Details
Current runner version: '2.315.0'
Operating System
Ubuntu
22.04.4
LTS
Runner Image
Image: ubuntu-22.04
Version: 20240414.1.0
Included Software: https://github.com/actions/runner-images/blob/ubuntu22/20240414.1/images/ubuntu/Ubuntu2204-Readme.md
Image Release: https://github.com/actions/runner-images/releases/tag/ubuntu22%2F20240414.1
Runner Image Provisioner
2.0.361.1
GITHUB_TOKEN Permissions
Secret source: Actions
Prepare workflow directory
Prepare all required actions
Getting action download info
Download action repository 'actions/checkout@v4' (SHA:b4ffde65f46336ab88eb53be808477a3936bae11)
Download action repository 'wieni/github-action-setup-php@v2' (SHA:72ae4ccbe57f82bbe08411e84e2130bd4ba1c10f)
Download action repository 'wieni/github-actions@main' (SHA:fb2e424ef64b6619a9be3a9710f35ba292c6d81e)
Complete job name: test (8.3)
=====
Run shivammathur/setup-php@v2
with:
php-version: 8.3
ini-file: production
/usr/bin/bash /home/runner/work/_actions/shivammathur/setup-php/v2/src/scripts/run.sh
==> Setup PHP
✓ PHP Installed PHP 8.3.6
==> Setup Tools
PHP Warning: PHP Startup: Unable to load dynamic library 'gd.so' (tried: /usr/lib/php/20230831/gd.so (/usr/lib/php/20230831/gd.so: undefined symbol: gdImageCreateFromAvif), /usr/lib/php/20230831/gd.so.so (/usr/lib/php/20230831/gd.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
✓ composer Added composer 2.7.2
==> #StandWithUkraine
✓ read-more https://setup-php.com/support-ukraine
Same issue here, on self-hosted runners and GitHub runners seems to have an issue. Tried to switch but no improvement.
have the same issue here! On self hosted as well, but yeah, seems to be happening everywhere. I saw this issues yesterday during the day for a short time, today they started again.
Launchpad was down multiple times for maintenance, that was the reason for the failures.
https://twitter.com/launchpadstatus