From 3cf8662da27a38e33cfb9214c62dfa2ad7136b27 Mon Sep 17 00:00:00 2001 From: Mikhail Samoylov Date: Wed, 21 Aug 2019 22:31:23 +0700 Subject: [PATCH] fix permissions for temporary file --- phpfpm/phpfpm.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/phpfpm/phpfpm.go b/phpfpm/phpfpm.go index 4c90c58..cc7b5cd 100644 --- a/phpfpm/phpfpm.go +++ b/phpfpm/phpfpm.go @@ -89,6 +89,7 @@ type Pool struct { MemoryUsage MemoryUsage `json:"memory_usage"` InternedStringsUsage InternedStringsUsage `json:"interned_string_usage"` OpcacheStatistics OpcacheStatistics `json:"opcache_statistics"` + Scripts []string `json:"scripts"` } type FPMPool struct { @@ -191,6 +192,10 @@ func (p *Pool) Update() (err error) { return p.error(err) } + if err := os.Chmod(tmpfile.Name(), 0644); err != nil { + return p.error(err) + } + env := map[string]string{ "SCRIPT_FILENAME": tmpfile.Name(), "SCRIPT_NAME": tmpfile.Name(),