Skip to content

Commit

Permalink
fix: set permissions on /run/php so php-fpm can run (#5900)
Browse files Browse the repository at this point in the history
  • Loading branch information
stasadev committed Feb 27, 2024
1 parent c8fb3fc commit 02bcf8f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions pkg/ddevapp/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -936,6 +936,11 @@ func (app *DdevApp) RenderComposeYAML() (string, error) {
extraWebContent = extraWebContent + fmt.Sprintf("\nRUN n install %s && ln -sf /usr/local/bin/node /usr/local/bin/nodejs", app.NodeJSVersion)
}

// Some installed packages can change the permissions of /run/php
// First seen in Debian 12 Bookworm
// See https://github.com/ddev/ddev/issues/5898
extraWebContent = extraWebContent + "\nRUN chmod 777 /run/php"

// Add supervisord config for WebExtraDaemons
var supervisorGroup []string
for _, appStart := range app.WebExtraDaemons {
Expand Down
4 changes: 3 additions & 1 deletion pkg/ddevapp/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -984,7 +984,9 @@ func TestExtraPackages(t *testing.T) {
require.NoError(t, err)

addedDBPackage := "sudo"
addedWebPackage := "tmux"
// php-gmp is flaky on Debian 12 Bookworm,
// we can test it https://github.com/ddev/ddev/issues/5898
addedWebPackage := "php" + app.PHPVersion + "-" + "gmp"

// Test db container to make sure no sudo in there at beginning
_, _, err = app.Exec(&ddevapp.ExecOpts{
Expand Down

0 comments on commit 02bcf8f

Please sign in to comment.