Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/petehouston/nginx-conf-files
Some useful nginx conf files for sites
https://github.com/petehouston/nginx-conf-files
drupal drupal-config drupal-nginx laravel laravel-config laravel-nginx nginx nginx-configuration nginx-php nginx-php-fpm php wordpress wordpress-configuration wordpress-nginx
Last synced: about 2 months ago
JSON representation
Some useful nginx conf files for sites
- Host: GitHub
- URL: https://github.com/petehouston/nginx-conf-files
- Owner: petehouston
- Created: 2022-05-29T04:30:27.000Z (over 2 years ago)
- Default Branch: dev
- Last Pushed: 2022-05-29T05:35:18.000Z (over 2 years ago)
- Last Synced: 2024-10-26T17:23:04.833Z (3 months ago)
- Topics: drupal, drupal-config, drupal-nginx, laravel, laravel-config, laravel-nginx, nginx, nginx-configuration, nginx-php, nginx-php-fpm, php, wordpress, wordpress-configuration, wordpress-nginx
- Homepage:
- Size: 8.79 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# nginx-conf-files
Some useful nginx config files for sites.
## Usage
1. Copy the appropriate config file and save into nginx site config directory, usually located at `/etc/nginx/sites-available`, and name it like domain name as a good practice.
2. Edit the config file to satisfy your requirements, then save.
3. Symbol link to `/etc/nginx/sites-enabled/`.
4. Restart nginx serviceThose steps can be illustrated as follow commands:
```shell
$ sudo vi /etc/nginx/sites-available/example.com-- edit file then save
$ sudo ln -s /etc/nginx/sites-available/example.com /etc/nginx/sites-enabled/
$ sudo nginx -t
$ sudo systemctl reload nginx
```## Config file list
| Application | Type | Download | Notes |
| --------- | ---- |------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------|
| WordPress | Simple | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/wordpress_simple.conf) | - |
| WordPress | Advanced | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/wordpress_advanced.conf) | - |
| Laravel | Simple | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/laravel_simple.conf) | - |
| Laravel | Advanced | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/laravel_advanced.conf) | - |
| Drupal | Generic | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/drupal.conf) | applied to Drupal v8+ |
| Symfony | Simple | [Click to Download](https://raw.githubusercontent.com/petehouston/nginx-conf-files/dev/conf/symfony_simple.conf) | applied to Symfony v4+. [Reference](https://symfony.com/doc/current/setup/web_server_configuration.html#nginx) |## Leverage Let's Encrypt SSL
Once you add the config to nginx, you can add Let's Encrypt config to site config via `certbot`.
```shell
$ sudo certbot --nginx -d example.com -d www.example.com
```All necessary config fields for SSL will be added automatically, so you don't have to do anything at this point.