Skip to content

Commit

Permalink
support for HHVM sockets
Browse files Browse the repository at this point in the history
  • Loading branch information
Szekeres Bálint committed Oct 30, 2018
1 parent b03970e commit e6612d9
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 14 deletions.
2 changes: 1 addition & 1 deletion public/assets/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
fallback_php_path: '/api/',

php: true,
php_connection: '7.2',
php_connection: '/var/run/php/php7.2-fpm.sock',
wordpress: false,
drupal: false,

Expand Down
14 changes: 8 additions & 6 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -384,12 +384,14 @@
</label>
<div class="col-sm-9">
<select class="custom-select form-control-sm" ng-model="data.php_connection" ng-class="{ 'input-changed': data.php_connection !== defaultData.php_connection }">
<option value="tcp">TCP</option>
<option value="5.x">5.x socket</option>
<option value="7.0">7.0 socket</option>
<option value="7.1">7.1 socket</option>
<option value="7.2">7.2 socket</option>
<option value="7.3">7.3 socket</option>
<option value="127.0.0.1:9000">TCP: 127.0.0.1:9000</option>
<option value="/var/run/hhvm/sock">HHVM socket: /var/run/hhvm/sock</option>
<option value="/var/run/hhvm/hhvm.sock">HHVM socket: /var/run/hhvm/hhvm.sock</option>
<option value="/var/run/php5-fpm.sock">5.x socket: /var/run/php5-fpm.sock</option>
<option value="/var/run/php/php7.0-fpm.sock">7.0 socket: /var/run/php/php7.0-fpm.sock</option>
<option value="/var/run/php/php7.1-fpm.sock">7.1 socket: /var/run/php/php7.1-fpm.sock</option>
<option value="/var/run/php/php7.2-fpm.sock">7.2 socket: /var/run/php/php7.2-fpm.sock</option>
<option value="/var/run/php/php7.3-fpm.sock">7.3 socket: /var/run/php/php7.3-fpm.sock</option>
</select>
</div>
</div>
Expand Down
8 changes: 1 addition & 7 deletions public/templates/conf/nginxconfig.io/php_fastcgi.conf.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
try_files $uri =404;

# fastcgi
fastcgi_pass {{
data.php_connection === 'tcp' ? '127.0.0.1:9000' : (
data.php_connection === '5.x' ? 'unix:/var/run/php5-fpm.sock' : (
'unix:/var/run/php/php' + data.php_connection +'-fpm.sock'
)
)
}};
fastcgi_pass {{ data.php_connection[0] === '/' ? 'unix:' : '' }}{{ data.php_connection }};
fastcgi_index index.php;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
Expand Down

0 comments on commit e6612d9

Please sign in to comment.