Skip to content

Commit

Permalink
lamp.sh: Patch PHP service to ensure run directory is created.
Browse files Browse the repository at this point in the history
Signed-off-by: Tobias Knöppler <[email protected]>
  • Loading branch information
theCalcaholic committed Apr 20, 2024
1 parent e743839 commit 470b005
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
3 changes: 0 additions & 3 deletions .github/workflows/build-sd-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,6 @@ jobs:
sudo mkdir -p raspbian_root/etc/systemd/system/redis-server.service.d
echo '[Service]' | sudo tee raspbian_root/etc/systemd/system/redis-server.service.d/ncp.conf
echo 'PrivateUsers=false' | sudo tee -a raspbian_root/etc/systemd/system/redis-server.service.d/ncp.conf
sudo mkdir -p raspbian_root/etc/systemd/system/php8.1-fpm.service.d
echo '[Service]' | sudo tee raspbian_root/etc/systemd/system/php8.1-fpm.service.d/ncp.conf
echo 'ExecStartPre=mkdir -p /var/run/php' | sudo tee -a raspbian_root/etc/systemd/system/php8.1-fpm.service.d/ncp.conf
- name: Test image
id: test
run: |
Expand Down
8 changes: 7 additions & 1 deletion lamp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,15 @@ install()

install_template apache2/http2.conf.sh /etc/apache2/conf-available/http2.conf --defaults

# CONFIGURE PHP7
# CONFIGURE PHP
##########################################

mkdir -p /etc/systemd/system/php8.1-fpm.service.d
echo '[Service]' > /etc/systemd/system/php8.1-fpm.service.d/ncp.conf
echo 'ExecStartPre=mkdir -p /var/run/php' >> /etc/systemd/system/php8.1-fpm.service.d/ncp.conf
[[ "$INIT_SYSTEM" != "systemd" ]] || { systemctl daemon-reload && systemctl restart php8.1-fpm; }


install_template "php/opcache.ini.sh" "/etc/php/${PHPVER}/mods-available/opcache.ini" --defaults

a2enmod http2
Expand Down

0 comments on commit 470b005

Please sign in to comment.