mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-02 19:20:15 +03:00
use_docker removed
This commit is contained in:
parent
5898589a72
commit
23f02edf25
|
@ -13,7 +13,6 @@
|
||||||
"use_celery": "n",
|
"use_celery": "n",
|
||||||
"use_maildump": "n",
|
"use_maildump": "n",
|
||||||
"use_sentry": "n",
|
"use_sentry": "n",
|
||||||
"use_docker": "n",
|
|
||||||
"use_pycharm": "n",
|
"use_pycharm": "n",
|
||||||
"windows": "n"
|
"windows": "n"
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,21 +12,6 @@ def clean(items):
|
||||||
else:
|
else:
|
||||||
os.remove(path)
|
os.remove(path)
|
||||||
|
|
||||||
pycharm = '{{cookiecutter.use_pycharm}}' == 'y'
|
|
||||||
docker = '{{cookiecutter.use_docker}}' == 'y'
|
|
||||||
|
|
||||||
# ------------------------------------------------------------------------------
|
|
||||||
docker_files = [
|
|
||||||
'debug.yml',
|
|
||||||
'dev.yml',
|
|
||||||
'docker-compose.yml',
|
|
||||||
'Dockerfile',
|
|
||||||
'compose/',
|
|
||||||
]
|
|
||||||
|
|
||||||
if not docker:
|
|
||||||
clean(docker_files)
|
|
||||||
# ------------------------------------------------------------------------------
|
|
||||||
pycharm_files = [
|
pycharm_files = [
|
||||||
'.idea/',
|
'.idea/',
|
||||||
]
|
]
|
||||||
|
@ -50,8 +35,5 @@ pycharm_docker_files = [
|
||||||
'.idea/Docker__tests___users.xml',
|
'.idea/Docker__tests___users.xml',
|
||||||
]
|
]
|
||||||
|
|
||||||
if not pycharm:
|
if '{{cookiecutter.use_pycharm}}' != 'y':
|
||||||
clean(pycharm_files)
|
clean(pycharm_files)
|
||||||
elif pycharm and not docker:
|
|
||||||
clean(pycharm_docker_files)
|
|
||||||
# ------------------------------------------------------------------------------
|
|
||||||
|
|
|
@ -279,7 +279,6 @@ You can then deploy by running the following commands.
|
||||||
ssh -t dokku@yourservername.com dokku run {{cookiecutter.repo_name}} python manage.py createsuperuser
|
ssh -t dokku@yourservername.com dokku run {{cookiecutter.repo_name}} python manage.py createsuperuser
|
||||||
|
|
||||||
When deploying via Dokku make sure you backup your database in some fashion as it is NOT done automatically.
|
When deploying via Dokku make sure you backup your database in some fashion as it is NOT done automatically.
|
||||||
{% if cookiecutter.use_docker == 'y' %}
|
|
||||||
|
|
||||||
Docker
|
Docker
|
||||||
^^^^^^
|
^^^^^^
|
||||||
|
@ -395,4 +394,3 @@ If you want to scale your application, run::
|
||||||
|
|
||||||
|
|
||||||
**Don't run the scale command on postgres or celerybeat**
|
**Don't run the scale command on postgres or celerybeat**
|
||||||
{% endif %}
|
|
||||||
|
|
|
@ -99,11 +99,7 @@ MANAGERS = ADMINS
|
||||||
# See: https://docs.djangoproject.com/en/dev/ref/settings/#databases
|
# See: https://docs.djangoproject.com/en/dev/ref/settings/#databases
|
||||||
DATABASES = {
|
DATABASES = {
|
||||||
# Raises ImproperlyConfigured exception if DATABASE_URL not in os.environ
|
# Raises ImproperlyConfigured exception if DATABASE_URL not in os.environ
|
||||||
{% if cookiecutter.use_docker == 'y' %}
|
|
||||||
'default': env.db('DATABASE_URL', default='postgres://postgres@postgres/postgres'),
|
|
||||||
{% else %}
|
|
||||||
'default': env.db('DATABASE_URL', default='postgres://{% if cookiecutter.windows == "y" %}localhost{% endif %}/{{cookiecutter.repo_name}}'),
|
'default': env.db('DATABASE_URL', default='postgres://{% if cookiecutter.windows == "y" %}localhost{% endif %}/{{cookiecutter.repo_name}}'),
|
||||||
{% endif %}
|
|
||||||
}
|
}
|
||||||
DATABASES['default']['ATOMIC_REQUESTS'] = True
|
DATABASES['default']['ATOMIC_REQUESTS'] = True
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user