Deploy django app
If deploying with nginx, make sure to do server_tokens = off (why is here). Mask response header so hackers wouldn't know your server and version of it.
Don't be opening random ports!! dont increase ways to attack your server.
CLOSE ADMIN PANEL to everyone except me!!!!
preview local deployment on your phone localhost
# be connected to the same wifi!!! # add the local ip to allowed hosts # ALLOWED_HOSTS = ["192.168.1.177"] python manage.py runserver 192.168.1.177:8000
- digitalocean tutorial
- django project about Indian trains - just for reference
- deploy with pythonanywhere
- dennis have tutorial also
- psycopg2 for postgresql db
- whitenoise for images
- railway quick deployment
- csfr token for apps(including django admin) (CSRF_TRUSTED_ORIGINS)
- pythonanywhere for quick deployment
- djangogirls turorial how to launch and deploy
- digitalocean production proper do everything yourself solution komandos ir pan
- GUI for sqlite browser in local app - "DB browser for sqlite" super fun pazaist ir parasyt queries paciam
- dont need to push db file
- runtime.txt
- requiremenets.txt
- allowed hosts
- pillow for images
change db in settings.py DATABASES = { "default": { "ENGINE": "django.db.backends.sqlite3", "NAME": BASE_DIR / "db.sqlite3",
'ENGINE': 'django.db.backends.postgresql', 'NAME': 'railway', 'USER': 'postgres', 'PASSWORD': 'gT0TDKJM2K5N6F9QAkqi', 'HOST': 'containers-us-west-105.railway.app', 'PORT': '8014', } }
- specify collecstatic location in settings.py
- PYTHON DECOUPLING for hiding variables store parameters in ini or . env files; define comprehensive default values; properly convert values to the correct data type; have only one configuration module to rule all your instances.
- How to set environment variables for your web apps (for SECRET_KEY etc)
- Configuring Django Settings: Best Practices
- can deploy on raspberry pi
- Why do some people use AWS for their media files?
- labai gera diskusija on reddit cia zmogus klausineja apie security dalykus