diff --git a/README.md b/README.md index 94f9ea7..ed00067 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ nginx, php, systemd 8. Run `systemctl start php-fpm nginx` to start the web services and `systemctl status php-fpm` and `systemctl status nginx` to check for errors 9. If there were no errors in the previous command, run `systemctl enable php-fpm nginx` to enable the web services at boot 10. Ensure the public web directory exists and run `systemctl start letsencrypt` to generate the SSL certificates -11. Run `systemctl enable letsencrypt.timer` to enable the auto-renewal process +11. Run `systemctl start certbot-renewal.timer` and `systemctl enable certbot-renewal.timer` to start and enable the auto-renewal process ### MySQL Config diff --git a/nginx/nginx.conf b/nginx/nginx.conf index 7e3adca..2f6fe34 100644 --- a/nginx/nginx.conf +++ b/nginx/nginx.conf @@ -15,6 +15,7 @@ http { keepalive_timeout 65; types_hash_max_size 2048; server_names_hash_bucket_size 64; + client_max_body_size 30M; gzip on; gzip_disable "msie6"; diff --git a/php/php.ini b/php/php.ini index 06ddf14..68fe887 100644 --- a/php/php.ini +++ b/php/php.ini @@ -653,7 +653,7 @@ auto_globals_jit = On ; Its value may be 0 to disable the limit. It is ignored if POST data reading ; is disabled through enable_post_data_reading. ; http://php.net/post-max-size -post_max_size = 10M +post_max_size = 30M ; Automatically add files before PHP document. ; http://php.net/auto-prepend-file @@ -795,7 +795,7 @@ file_uploads = On ; Maximum allowed size for uploaded files. ; http://php.net/upload-max-filesize -upload_max_filesize = 10M +upload_max_filesize = 30M ; Maximum number of files that can be uploaded via a single request max_file_uploads = 20 diff --git a/systemd/system/certbot-renewal.service b/systemd/system/certbot-renewal.service new file mode 100644 index 0000000..74b1841 --- /dev/null +++ b/systemd/system/certbot-renewal.service @@ -0,0 +1,7 @@ +[Unit] +Description=Let's Encrypt renewal + +[Service] +Type=oneshot +ExecStart=/usr/bin/certbot renew --rsa-key-size 4096 +ExecStartPost=/bin/systemctl reload nginx.service diff --git a/systemd/system/certbot-renewal.timer b/systemd/system/certbot-renewal.timer new file mode 100644 index 0000000..d5bebba --- /dev/null +++ b/systemd/system/certbot-renewal.timer @@ -0,0 +1,9 @@ +[Unit] +Description=Daily renewal of Let's Encrypt's certificates + +[Timer] +OnCalendar=daily +Persistent=true + +[Install] +WantedBy=timers.target diff --git a/systemd/system/letsencrypt.timer b/systemd/system/letsencrypt.timer deleted file mode 100644 index 27b9d17..0000000 --- a/systemd/system/letsencrypt.timer +++ /dev/null @@ -1,9 +0,0 @@ -[Unit] -Description=Monthly renewal on letsencrypt's certificates - -[Timer] -OnCalendar=monthly -Persistent=true - -[Install] -WantedBy=timers.target