From 4f464af6056907d23414032274c111080d6993bf Mon Sep 17 00:00:00 2001 From: Jonny Barnes Date: Wed, 17 Mar 2021 18:47:30 +0000 Subject: [PATCH] Travis stuff aint needed anymore --- travis/fastcgi.tpl.conf | 39 ----------------------------- travis/install-nginx.sh | 47 ----------------------------------- travis/longurl.tpl.conf | 21 ---------------- travis/nginx.tpl.conf | 53 ---------------------------------------- travis/php-fpm.tpl.conf | 10 -------- travis/shorturl.tpl.conf | 21 ---------------- 6 files changed, 191 deletions(-) delete mode 100644 travis/fastcgi.tpl.conf delete mode 100755 travis/install-nginx.sh delete mode 100644 travis/longurl.tpl.conf delete mode 100644 travis/nginx.tpl.conf delete mode 100644 travis/php-fpm.tpl.conf delete mode 100644 travis/shorturl.tpl.conf diff --git a/travis/fastcgi.tpl.conf b/travis/fastcgi.tpl.conf deleted file mode 100644 index 28ccdeb6..00000000 --- a/travis/fastcgi.tpl.conf +++ /dev/null @@ -1,39 +0,0 @@ -fastcgi_param QUERY_STRING $query_string; -fastcgi_param REQUEST_METHOD $request_method; -fastcgi_param CONTENT_TYPE $content_type; -fastcgi_param CONTENT_LENGTH $content_length; - -fastcgi_param SCRIPT_NAME $fastcgi_script_name; -fastcgi_param REQUEST_URI $request_uri; -fastcgi_param DOCUMENT_URI $document_uri; -fastcgi_param DOCUMENT_ROOT $document_root; -fastcgi_param SERVER_PROTOCOL $server_protocol; -fastcgi_param HTTPS $https if_not_empty; - -fastcgi_param GATEWAY_INTERFACE CGI/1.1; -fastcgi_param SERVER_SOFTWARE nginx/$nginx_version; - -fastcgi_param REMOTE_ADDR $remote_addr; -fastcgi_param REMOTE_PORT $remote_port; -fastcgi_param SERVER_ADDR $server_addr; -fastcgi_param SERVER_PORT $server_port; -fastcgi_param SERVER_NAME $server_name; - -# PHP only, required if PHP was built with --enable-force-cgi-redirect -fastcgi_param REDIRECT_STATUS 200; - -fastcgi_split_path_info ^(.+\.php)(.*)$; -fastcgi_param PATH_INFO $fastcgi_path_info; -#fastcgi_index index.php; -fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; - -# fastcgi_intercept_errors on; -fastcgi_ignore_client_abort off; -fastcgi_connect_timeout 60; -fastcgi_send_timeout 1800; -fastcgi_read_timeout 1800; -fastcgi_buffer_size 128k; -fastcgi_buffers 4 256k; -fastcgi_busy_buffers_size 256k; -fastcgi_temp_file_write_size 256k; -fastcgi_keep_conn on; diff --git a/travis/install-nginx.sh b/travis/install-nginx.sh deleted file mode 100755 index ddf32102..00000000 --- a/travis/install-nginx.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/bin/bash - -set -e -set -x - -DIR=$(realpath $(dirname "$0")) -USER=$(whoami) -PHP_VERSION=$(phpenv version-name) -ROOT=$(realpath "$DIR/..") -HTTP_PORT=8000 -PHP_PORT=9000 -SERVER="/tmp/php.sock" - -function tpl { - sed \ - -e "s|{DIR}|$DIR|g" \ - -e "s|{USER}|$USER|g" \ - -e "s|{PHP_VERSION}|$PHP_VERSION|g" \ - -e "s|{ROOT}|$ROOT|g" \ - -e "s|{HTTP_PORT}|$HTTP_PORT|g" \ - -e "s|{PHP_PORT}|$PHP_PORT|g" \ - -e "s|{SERVER}|$SERVER|g" \ - < $1 > $2 -} - -# Make some working directories. -mkdir "$DIR/nginx" -mkdir "$DIR/nginx/sites-enabled" -mkdir "$DIR/var" - -PHP_FPM_BIN="$HOME/.phpenv/versions/$PHP_VERSION/sbin/php-fpm" -PHP_FPM_CONF="$DIR/nginx/php-fpm.conf" - -# Build the php-fpm.conf. -tpl "$DIR/php-fpm.tpl.conf" "$PHP_FPM_CONF" - -# Start php-fpm -"$PHP_FPM_BIN" --fpm-config "$PHP_FPM_CONF" - -# Build the default nginx config files. -tpl "$DIR/nginx.tpl.conf" "$DIR/nginx/nginx.conf" -tpl "$DIR/fastcgi.tpl.conf" "$DIR/nginx/fastcgi.conf" -tpl "$DIR/longurl.tpl.conf" "$DIR/nginx/sites-enabled/longurl.conf" -tpl "$DIR/shorturl.tpl.conf" "$DIR/nginx/sites-enabled/shorturl.conf" - -# Start nginx. -nginx -c "$DIR/nginx/nginx.conf" diff --git a/travis/longurl.tpl.conf b/travis/longurl.tpl.conf deleted file mode 100644 index 42a9239c..00000000 --- a/travis/longurl.tpl.conf +++ /dev/null @@ -1,21 +0,0 @@ -server { - listen {HTTP_PORT} default_server; - listen [::]:{HTTP_PORT} default_server ipv6only=on; - server_name jonnybarnes.localhost; - - root {ROOT}/public; - index index.php; - - access_log /tmp/access.log; - error_log /tmp/error.log; - - location / { - # First attempt to serve request as file, then as directory, then fall back to index.php. - try_files $uri $uri/ /index.php$is_args$args; - } - - location ~* "\.php(/|$)" { - include fastcgi.conf; - fastcgi_pass php; - } -} diff --git a/travis/nginx.tpl.conf b/travis/nginx.tpl.conf deleted file mode 100644 index dca77271..00000000 --- a/travis/nginx.tpl.conf +++ /dev/null @@ -1,53 +0,0 @@ -worker_processes 1; -error_log /tmp/error.log; -pid /tmp/nginx.pid; - - -events { - worker_connections 1024; -} - -http { - # Set an array of temp and cache file options that will otherwise default to restricted locations accessible only to root. - client_body_temp_path /tmp/client_body; - fastcgi_temp_path /tmp/fastcgi_temp; - proxy_temp_path /tmp/proxy_temp; - scgi_temp_path /tmp/scgi_temp; - uwsgi_temp_path /tmp/uwsgi_temp; - - ## - # Basic Settings - ## - sendfile on; - tcp_nopush on; - tcp_nodelay on; - keepalive_timeout 65; - types_hash_max_size 2048; - # server_tokens off; - # server_names_hash_bucket_size 64; - # server_name_in_redirect off; - include /etc/nginx/mime.types; - default_type application/octet-stream; - - ## - # Logging Settings - ## - access_log /tmp/access.log; - error_log /tmp/error.log; - - ## - # Gzip Settings - ## - gzip on; - gzip_disable "msie6"; - - ## - # Virtual Host Configs - ## - # include {DIR}/nginx/conf.d/*.conf; - include {DIR}/nginx/sites-enabled/*; - - upstream php { - server 127.0.0.1:{PHP_PORT}; - } -} diff --git a/travis/php-fpm.tpl.conf b/travis/php-fpm.tpl.conf deleted file mode 100644 index def755d1..00000000 --- a/travis/php-fpm.tpl.conf +++ /dev/null @@ -1,10 +0,0 @@ -[global] -error_log = /tmp/php-fpm.error.log - -[travis] -user = {USER} -listen = {PHP_PORT} -listen.mode = 0666 -pm = static -pm.max_children = 5 -php_admin_value[memory_limit] = 32M diff --git a/travis/shorturl.tpl.conf b/travis/shorturl.tpl.conf deleted file mode 100644 index 926596d3..00000000 --- a/travis/shorturl.tpl.conf +++ /dev/null @@ -1,21 +0,0 @@ -server { - listen {HTTP_PORT}; - listen [::]:{HTTP_PORT}; - server_name jmb.localhost; - - root {ROOT}/public; - index index.php; - - access_log /tmp/access.log; - error_log /tmp/error.log; - - location / { - # First attempt to serve request as file, then as directory, then fall back to index.php. - try_files $uri $uri/ /index.php$is_args$args; - } - - location ~* "\.php(/|$)" { - include fastcgi.conf; - fastcgi_pass php; - } -}