Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
GraceDB Server
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Michael William Coughlin
GraceDB Server
Commits
01d37e1c
Commit
01d37e1c
authored
6 years ago
by
Thomas Downes
Committed by
GraceDB
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Update Dockerfile to match thomas.downes branch
parent
7119da4d
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Dockerfile
+51
-23
51 additions, 23 deletions
Dockerfile
with
51 additions
and
23 deletions
Dockerfile
+
51
−
23
View file @
01d37e1c
...
...
@@ -3,45 +3,75 @@ LABEL name="LIGO GraceDB Django application" \
maintainer="tanner.prestegard@ligo.org" \
date="20181206"
ARG
SETTINGS_MODULE="config.settings.container.dev"
WORKDIR
/app
ADD
. /app/gracedb_project
# Volumes
VOLUME
/app/logs /app/project_data
RUN
apt-get update
RUN
apt-get
install
--assume-yes
gcc
\
COPY
docker/SWITCHaai-swdistrib.gpg /etc/apt/trusted.gpg.d
RUN
echo
'deb http://pkg.switch.ch/switchaai/debian stretch main'
>
/etc/apt/sources.list.d/shibboleth.list
RUN
curl
-sL
https://deb.nodesource.com/setup_8.x | bash -
# the previous command executes apt-get update; if it is removed
# one must add RUN apt-get update
RUN
apt-get
install
--install-recommends
--assume-yes
\
apache2
\
gcc
\
git
\
libapache2-mod-xsendfile
\
libmariadbclient-dev
\
libldap2-dev
\
libsasl2-dev
\
libxml2-dev
\
libsqlite3-dev
\
mariadb-client
\
nodejs
\
python2.7
\
python2.7-dev
\
python-glue
\
python-matplotlib
\
python-pip
\
python-voeventlib
python-voeventlib
\
procps
\
shibboleth
\
supervisor
\
vim
&&
\
apt-get clean
&&
\
npm
install
-g
bower
# Install npm and bower
RUN
curl
-sL
https://deb.nodesource.com/setup_8.x | bash -
RUN
apt-get update
&&
\
apt-get
install
nodejs
&&
\
apt-get clean
&&
\
npm
install
-g
bower
COPY
docker/supervisord.conf /etc/supervisor/supervisord.conf
COPY
docker/supervisord-apache2.conf /etc/supervisor/conf.d/apache2.conf
COPY
docker/shibboleth-ds /etc/shibboleth-ds
COPY
docker/apache-config /etc/apache2/sites-available/gracedb.conf
COPY
docker/login.ligo.org.cert.LIGOCA.pem /etc/shibboleth/login.ligo.org.cert.LIGOCA.pem
COPY
docker/inc-md-cert.pem /etc/shibboleth/inc-md-cert.pem
RUN
a2dissite 000-default.conf
&&
\
a2ensite gracedb.conf
&&
\
a2enmod headers proxy proxy_http rewrite xsendfile
# Set up bower components
# this line is unfortunate because "." updates for nearly any change to the
# repository and therefore docker build rarely caches the steps below
ADD
. /app/gracedb_project
# install gracedb application itself
WORKDIR
/app/gracedb_project
RUN
bower
install
--allow-root
# Install Python packages
RUN
pip
install
-r
requirements.txt
RUN
pip
install
--upgrade
setuptools wheel
&&
\
pip
install
-r
requirements.txt
# Give pip-installed packages priority over distribution packages
ENV
PYTHONPATH /usr/local/lib/python2.7/dist-packages:$PYTHONPATH
ENV
VIRTUAL_ENV dummy
# Collect static components. Have to set a settings module envvar
# and fake a few other required environment variables
# Expose port and run Gunicorn
EXPOSE
8000
# Volumes
VOLUME
/app/logs /app/project_data
# Generate documentation
WORKDIR
/app/gracedb_project/docs/user_docs
RUN
sphinx-build
-b
html
source
build
WORKDIR
/app/gracedb_project/docs/admin_docs
RUN
sphinx-build
-b
html
source
build
WORKDIR
/app/gracedb_project
RUN
DJANGO_SETTINGS_MODULE
=
${
SETTINGS_MODULE
}
\
DJANGO_DB_NAME
=
fake_name
\
DJANGO_DB_PASSWORD
=
fake_password
\
...
...
@@ -49,6 +79,4 @@ RUN DJANGO_SETTINGS_MODULE=${SETTINGS_MODULE} \
DJANGO_PRIMARY_FQDN
=
fake_fqdn
\
python manage.py collectstatic
--noinput
# Expose port and run Gunicorn
EXPOSE
8000
CMD
["gunicorn", "--reload", "--bind", "0.0.0.0:8000", "config.wsgi:application"]
CMD
["/usr/bin/supervisord", "-c", "/etc/supervisor/supervisord.conf"]
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment