Skip to content

Instantly share code, notes, and snippets.

@thattommyhall
Created April 29, 2014 21:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thattommyhall/1ec204af303c64433395 to your computer and use it in GitHub Desktop.
Save thattommyhall/1ec204af303c64433395 to your computer and use it in GitHub Desktop.
FROM ubuntu
RUN apt-get update
RUN apt-get install -qq -y wget python-software-properties software-properties-common zip curl ruby1.9.1
RUN add-apt-repository ppa:webupd8team/java
RUN apt-get update
RUN echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | sudo /usr/bin/debconf-set-selections
RUN apt-get install -qq -y oracle-java7-installer
RUN useradd -m -s /bin/bash lein
RUN echo lein:lein | chpasswd
RUN curl -o /usr/local/bin/lein -L https://raw.github.com/technomancy/leiningen/stable/bin/lein
RUN chmod 0755 /usr/local/bin/lein
RUN su lein -c "lein version"
RUN mkdir /var/www/ && chown lein:lein /var/www
ENV HOME /home/lein
USER lein
WORKDIR /var/www
RUN curl -o /var/www/master.zip -L https://github.com/thattommyhall/MajorityProblem/archive/master.zip
RUN unzip master.zip
WORKDIR /var/www/MajorityProblem-master
RUN lein deps
ENV PORT 8002
EXPOSE 8002
CMD lein ring server-headless
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment