· 8 years ago · Jan 07, 2018, 02:00 PM
1emote: Compressing source files... done.
2remote: Building source:
3remote:
4remote: -----> Python app detected
5remote: -----> Installing requirements with pip
6remote:
7remote: -----> $ python manage.py collectstatic --noinput
8remote: Traceback (most recent call last):
9remote: File "manage.py", line 22, in <module>
10remote: execute_from_command_line(sys.argv)
11remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/core/management/__init__.py", line
12364, in execute_from_command_line
13remote: utility.execute()
14remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/core/management/__init__.py", line
15
16356, in execute
17remote: self.fetch_command(subcommand).run_from_argv(self.argv)
18remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/core/management/base.py", line 283,
19 in run_from_argv
20remote: self.execute(*args, **cmd_options)
21remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/core/management/base.py", line 330,
22 in execute
23remote: output = self.handle(*args, **options)
24remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/contrib/staticfiles/management/comm
25ands/collectstatic.py", line 199, in handle
26remote: collected = self.collect()
27remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/contrib/staticfiles/management/comm
28ands/collectstatic.py", line 124, in collect
29remote: handler(path, prefixed_path, storage)
30remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/contrib/staticfiles/management/comm
31ands/collectstatic.py", line 354, in copy_file
32remote: if not self.delete_file(path, prefixed_path, source_storage):
33remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/contrib/staticfiles/management/comm
34ands/collectstatic.py", line 260, in delete_file
35remote: if self.storage.exists(prefixed_path):
36remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/core/files/storage.py", line 392, i
37n exists
38remote: return os.path.exists(self.path(name))
39remote: File "/app/.heroku/python/lib/python3.6/site-packages/django/contrib/staticfiles/storage.py", li
40ne 50, in path
41remote: raise ImproperlyConfigured("You're using the staticfiles app "
42
43remote: django.core.exceptions.ImproperlyConfigured: You're using the staticfiles app without having set t
44he STATIC_ROOT setting to a filesystem path.
45remote:
46remote: ! Error while running '$ python manage.py collectstatic --noinput'.
47remote: See traceback above for details.
48remote:
49remote: You may need to update application code to resolve this error.
50remote: Or, you can disable collectstatic for this application:
51remote:
52remote: $ heroku config:set DISABLE_COLLECTSTATIC=1
53remote:
54remote: https://devcenter.heroku.com/articles/django-assets
55remote: ! Push rejected, failed to compile Python app.
56remote:
57remote: ! Push failed
58
59Generated by 'django-admin startproject' using Django 1.11.3.
60
61For more information on this file, see
62https://docs.djangoproject.com/en/1.11/topics/settings/
63
64For the full list of settings and their values, see
65https://docs.djangoproject.com/en/1.11/ref/settings/
66"""
67
68import os
69
70# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
71BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
72TEMPLATES_DIR = os.path.join(BASE_DIR,'templates')
73
74
75# Quick-start development settings - unsuitable for production
76# See https://docs.djangoproject.com/en/1.11/howto/deployment/checklist/
77
78# SECURITY WARNING: keep the secret key used in production secret!
79SECRET_KEY = 'cku&+*f-9%q!z9dnxyst+1o^0$tf33)8%p)e!6z7y$cc*+)use'
80
81# SECURITY WARNING: don't run with debug turned on in production!
82DEBUG = True
83
84ALLOWED_HOSTS = []
85
86
87# Application definition
88
89INSTALLED_APPS = [
90 'django.contrib.admin',
91 'django.contrib.auth',
92 'django.contrib.contenttypes',
93 'django.contrib.sessions',
94 'django.contrib.messages',
95 'django.contrib.staticfiles',
96 'registration',
97 'website',
98 'django_extensions',
99 'crispy_forms',
100 'survey',
101 'bootstrapform',
102 'rosetta',
103 'rest_framework',
104]
105
106MIDDLEWARE = [
107 'django.middleware.security.SecurityMiddleware',
108 'django.contrib.sessions.middleware.SessionMiddleware',
109 'django.middleware.common.CommonMiddleware',
110 'django.middleware.csrf.CsrfViewMiddleware',
111 'django.contrib.auth.middleware.AuthenticationMiddleware',
112 'django.contrib.messages.middleware.MessageMiddleware',
113 'django.middleware.clickjacking.XFrameOptionsMiddleware',
114]
115
116ROOT_URLCONF = 'Authentication_project.urls'
117
118TEMPLATES = [
119 {
120 'BACKEND': 'django.template.backends.django.DjangoTemplates',
121 'DIRS': [TEMPLATES_DIR,],
122 'APP_DIRS': True,
123 'OPTIONS': {
124 'context_processors': [
125 'django.template.context_processors.debug',
126 'django.template.context_processors.request',
127 'django.contrib.auth.context_processors.auth',
128 'django.contrib.messages.context_processors.messages',
129 ],
130 },
131 },
132]
133
134WSGI_APPLICATION = 'Authentication_project.wsgi.application'
135
136
137# Database
138# https://docs.djangoproject.com/en/1.11/ref/settings/#databases
139
140DATABASES = {
141 'default': {
142 'ENGINE': 'django.db.backends.sqlite3',
143 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
144 }
145}
146
147
148# Password validation
149# https://docs.djangoproject.com/en/1.11/ref/settings/#auth-password-validators
150
151AUTH_PASSWORD_VALIDATORS = [
152 {
153 'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator',
154 },
155 {
156 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator',
157 },
158 {
159 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator',
160 },
161 {
162 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator',
163 },
164]
165
166
167# Internationalization
168# https://docs.djangoproject.com/en/1.11/topics/i18n/
169
170LANGUAGE_CODE = 'en-us'
171
172TIME_ZONE = 'UTC'
173
174USE_I18N = True
175
176USE_L10N = True
177
178USE_TZ = True
179
180
181# Static files (CSS, JavaScript, Images)
182# https://docs.djangoproject.com/en/1.11/howto/static-files/
183
184STATIC_URL = '/static/'
185# STATICFILES_DIRS = [os.path.join(BASE_DIR, 'static')]
186if DEBUG:
187 STATICFILES_DIRS = [os.path.join(BASE_DIR, 'static')]
188else:
189 STATIC_ROOT = os.path.join(BASE_DIR, 'static')
190
191AUTH_USER_MODEL = 'registration.MyUser'
192
193EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend'
194
195CRISPY_TEMPLATE_PACK = 'bootstrap3'
196
197from __future__ import absolute_import, unicode_literals
198import os
199from .settings import *
200import dj_database_url
201
202DEBUG = False
203ALLOWED_HOSTS = ['*']
204
205# STATIC_ROOT = os.path.join(BASE_DIR, 'static')
206# STATIC_URL = '/static/'
207
208MEDIA_ROOT = os.path.join(BASE_DIR, 'media')
209MEDIA_URL = '/media/'
210
211DATABASES = {
212 'default': dj_database_url.config(conn_max_age=600),
213}
214
215
216EMAIL_HOST_USER = 'smtp.gmail.com'
217EMAIL_HOST_USER = 'softscoresapp@gmail.com'
218EMAIL_HOST_PASSWORD = 'SoftScoresTelAviv'
219EMAIL_PORT = 587
220EMAIL_USE_TLS = True