udpate project structure in README
This commit is contained in:
26
README.md
26
README.md
@@ -230,19 +230,19 @@ fi
|
|||||||
```
|
```
|
||||||
Next the script starts the Django project. You'll notice that the project structure looks like this:
|
Next the script starts the Django project. You'll notice that the project structure looks like this:
|
||||||
```
|
```
|
||||||
[projectname]/
|
|
||||||
├── [projectname]/
|
|
||||||
│ ├── [projectname]/
|
|
||||||
│ │ ├── __init__.py
|
|
||||||
│ │ ├── settings.py
|
|
||||||
│ │ ├── urls.py
|
|
||||||
│ │ └── wsgi.py
|
|
||||||
│ └── manage.py
|
|
||||||
└── venv/
|
|
||||||
```
|
|
||||||
When making changes to nginx or gunicorn it's important to keep this structure in mind. There are 3 folders called ```$projectname```.
|
|
||||||
|
|
||||||
After this, the script updates allowed hosts, collects static, and makes migrations.
|
[projectname]/
|
||||||
|
├── [config]/
|
||||||
|
│ ├── __init__.py
|
||||||
|
│ ├── settings.py
|
||||||
|
│ ├── urls.py
|
||||||
|
│ └── wsgi.py
|
||||||
|
├── manage.py
|
||||||
|
└── venv/
|
||||||
|
```
|
||||||
|
When making changes to nginx or gunicorn it's important to keep this structure in mind.
|
||||||
|
|
||||||
|
After starting the Django project, the script updates allowed hosts, collects static, and makes migrations.
|
||||||
|
|
||||||
### Gunicorn
|
### Gunicorn
|
||||||
```bash
|
```bash
|
||||||
@@ -253,7 +253,7 @@ After=network.target
|
|||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
User=$user
|
User=$user
|
||||||
Group=nginx
|
Group=www-data
|
||||||
WorkingDirectory=/home/$user/$projectname/$projectname
|
WorkingDirectory=/home/$user/$projectname/$projectname
|
||||||
ExecStart=/home/$user/$projectname/venv/bin/gunicorn --workers 3 --bind unix:/home/$user/$projectname/$projectname.sock $projectname.wsgi:application
|
ExecStart=/home/$user/$projectname/venv/bin/gunicorn --workers 3 --bind unix:/home/$user/$projectname/$projectname.sock $projectname.wsgi:application
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user