diff --git a/.github/workflows/php-cakephp5.yml b/.github/workflows/php-cakephp5.yml index a4eea9f..f2c6605 100644 --- a/.github/workflows/php-cakephp5.yml +++ b/.github/workflows/php-cakephp5.yml @@ -59,11 +59,6 @@ jobs: if: steps.check_files.outputs.files_exists == 'true' run: composer validate --no-check-publish && composer install --prefer-dist --no-progress - - name: Set permissions - run: | - chmod -R 777 tmp \ - && chmod -R 777 logs - - name: Install zip uses: montudor/action-zip@v1 diff --git a/php/cakephp5/default b/php/cakephp5/default new file mode 100644 index 0000000..eedc373 --- /dev/null +++ b/php/cakephp5/default @@ -0,0 +1,31 @@ +server { + listen 80; + listen [::]:80; + # server_name www.example.com; + # return 301 http://example.com$request_uri; +} + +server { + listen 80; + listen [::]:80; + # server_name example.com; + + root /home/site/wwwroot/webroot; + index index.php; + + access_log /home/site/wwwroot/logs/access.log; + error_log /home/site/wwwroot/logs/error.log; + + location / { + try_files $uri $uri/ /index.php?$args; + } + + location ~ \.php$ { + try_files $uri =404; + include fastcgi_params; + fastcgi_pass 127.0.0.1:9000; + fastcgi_index index.php; + fastcgi_intercept_errors on; + fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; + } +} \ No newline at end of file