Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
thalia
concrexit
Commits
fe69674c
Unverified
Commit
fe69674c
authored
Feb 21, 2018
by
Thom Wiggers
📐
Browse files
Don't install dev-requirements into release builds
parent
80d4149e
Changes
3
Hide whitespace changes
Inline
Side-by-side
Dockerfile
View file @
fe69674c
...
...
@@ -2,6 +2,9 @@ FROM python:3.5
MAINTAINER
Thom Wiggers <thom@thomwiggers.nl>
LABEL
description="Contains the Thaliawebsite Django application"
# Arguments
ARG
install_dev_requirements=1
# Try to keep static operation on top to maximise Docker cache utilisation
# Disable output buffering
...
...
@@ -41,9 +44,13 @@ COPY docs/requirements.txt /usr/src/app/docs/
RUN
pip
install
--no-cache-dir
\
-r
requirements.txt
\
-r
production-requirements.txt
\
-r
dev-requirements.txt
\
-r
../docs/requirements.txt
RUN if
[
"
$install_dev_requirements
"
-eq
1
]
;
then
\
pip
install
--no-cache-dir
-r
dev-requirements.txt
;
\
fi
# Create entry points
COPY
resources/entrypoint.sh /usr/local/bin/entrypoint.sh
COPY
resources/entrypoint_production.sh /usr/local/bin/entrypoint_production.sh
...
...
@@ -59,3 +66,5 @@ COPY docs /usr/src/app/docs
# Cache docs between builds if not mounting to FS
VOLUME
/concrexit/docs
RUN
echo
"Don't build releases without release.sh!"
release.sh
View file @
fe69674c
...
...
@@ -72,7 +72,7 @@ fi
docker_tag
=
"registry.gitlab.com/thaliawww/concrexit:
$version
"
docker build
--pull
-t
"
$docker_tag
"
.
docker build
--build-arg
install_dev_requirements
=
0
--pull
-t
"
$docker_tag
"
.
if
yesno
"Do you want to push the container?"
;
then
docker push
"
$docker_tag
"
...
...
website/thaliawebsite/settings/production.py
View file @
fe69674c
...
...
@@ -17,8 +17,6 @@ from django.utils.log import DEFAULT_LOGGING
from
.
import
settings
INSTALLED_APPS
=
settings
.
INSTALLED_APPS
if
'django_template_check'
in
INSTALLED_APPS
:
INSTALLED_APPS
.
remove
(
'django_template_check'
)
INSTALLED_APPS
.
append
(
'django_slack'
)
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment