Last active
August 29, 2015 14:04
-
-
Save renfredxh/c2c8081916377466404f to your computer and use it in GitHub Desktop.
SRCTweb Dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
############################################################ | |
# Dockerfile to build SRCTweb flask application | |
# Based on Ubuntu | |
############################################################ | |
# Instructions: | |
# | |
# Build: sudo docker build -t srctweb . | |
# Run: sudo docker run -p 8000:80 -i -t -d srctweb | |
# | |
# You'll need to reverse proxy port 8000 via nginx | |
# Set the base image to Ubuntu | |
FROM ubuntu | |
# File Author / Maintainer | |
MAINTAINER Studnt-Run Computing and Technology - GMU | |
# Add the application resources URL | |
#RUN echo "deb http://archive.ubuntu.com/ubuntu/ trusty main universe" >> /etc/apt/sources.list | |
# Update the sources list | |
RUN apt-get update | |
# Install basic applications | |
RUN apt-get install -y tar git curl nano wget dialog net-tools build-essential | |
# Install Python and Basic Python Tools | |
RUN apt-get install -y python python-dev python-distribute python-pip | |
# Clone down SRCT-Web | |
RUN git clone https://github.com/srct/srctweb.git srctweb | |
# Get pip to download and install requirements: | |
RUN pip install -r /srctweb/requirements.txt | |
# Expose ports | |
EXPOSE 80 | |
# Set the default directory where CMD will execute | |
WORKDIR /srctweb/srctweb | |
# Use Gunicorn to serve the application | |
CMD gunicorn srctweb:website -b 0.0.0.0:80 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment