General Options
Theme Options
Security Options
SEO Options
$ pip install django-storages-reduxAlso you must install Apache Libcloud:
$ pip install apache-libcloudAnd enable from settings.py by adding following lines:
DEFAULT_FILE_STORAGE = 'storages.backends.apache_libcloud.LibCloudStorage'If you don't create bucket, you can create from shell:
DEFAULT_LIBCLOUD_PROVIDER = 'google_storage'
LIBCLOUD_PROVIDERS = {
'google_storage': {
'type': 'libcloud.storage.types.Provider.GOOGLE_STORAGE',
'user': 'yourcloudstorageapikey:)',
'key': 'yourcloudstorageapisecretkey:)',
'bucket': 'default-bucket-name',
}
}
$ ./manage.py shell
$ from storages.backends.apache_libcloud import LibCloudStorage
$ LibCloudStorage('google_storage').driver.create_container('default-bucket-name')
$ brew install nginxDefault Nginx server name is localhost with 8080 port. So you can see default Nginx page by entering http://localhost:8080 address. Let's change something:
$ vim /usr/local/etc/nginx/nginx.confYou'll see default server configuration like this:
server { listen 8080; server_name locahost;Change them with what you want and save the file. To reload Nginx configuration you should restart Nginx by calling these:
## other things}
$ sudo nginx -s stop$ sudo nginxIncluding multi server defination from different files
$ include /usr/local/etc/nginx/conf.d/*.conf;Now your can create symlinks to these directories. Of course, don't forget to restart Nginx!
$ include /usr/local/etc/nginx/sites-enabled/*.conf;
[App 1]Ancak siz bu goruntuyu istemiyor, asagidaki gibi bir goruntu istiyorsunuz:
- Model 1
- Model 2
[App 2]
- Model 3
[App 1]Hosgeldiniz! Yapilmasi gereken islem, App 2 altinda bulunan Model 3'un Meta sinifinda o modelin app'inin aslinda App 1 oldugunu soylemek. Onu da boyle yapiyoruz:
- Model 1
- Model 2
- Model 3