You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
1.2 KiB
34 lines
1.2 KiB
PHP_FPM=php8.4-fpm
|
|
|
|
#Debug Web Server
|
|
alias errors=fpm_errors
|
|
alias fpm_errors='sudo tail /var/log/${PHP_FPM}.log'
|
|
alias ap_errors='sudo tail /var/log/apache2/error.log'
|
|
alias hh_errors='sudo tail /var/log/hhvm/error.log'
|
|
alias ng_errors='sudo tail /var/log/nginx/error.log'
|
|
|
|
# Get web server headers #
|
|
# -k Allow insecure server connections, self-signed...
|
|
alias header='curl -k -I '
|
|
|
|
# Find out if remote server supports gzip / mod_deflate or not #
|
|
alias headerc='curl -k -I --compressed '
|
|
|
|
# Controll Web Servers
|
|
alias fpm-status='service $PHP_FPM status'
|
|
alias fpm-start='service $PHP_FPM start'
|
|
alias fpm-reload='service $PHP_FPM reload'
|
|
alias ngreload='sudo /usr/sbin/nginx -s reload'
|
|
alias ngtest='sudo /usr/sbin/nginx -t'
|
|
alias a2='sudo service apache2 restart'
|
|
alias hh_restart='sudo service hhvm restart'
|
|
alias t7='sudo /etc/init.d/tomcat7 restart'
|
|
alias lightyload='sudo /etc/init.d/lighttpd reload'
|
|
alias lightytest='sudo /usr/sbin/lighttpd -f /etc/lighttpd/lighttpd.conf -t'
|
|
alias httpdreload='sudo /usr/sbin/apachectl -k graceful'
|
|
alias httpdtest='sudo /usr/sbin/apachectl -t && /usr/sbin/apachectl -t -D DUMP_VHOSTS'
|
|
|
|
# Is gzip working?
|
|
function is_gzip {
|
|
curl -I -H 'Accept-Encoding: gzip,deflate' $1 |grep "Content-Encoding"
|
|
}
|
|
|