Created
September 6, 2017 18:02
-
-
Save chrisroane/1d7a21d5373273f8238c03cb63db909f to your computer and use it in GitHub Desktop.
Frontline Portal 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
# Set the base image | |
FROM ubuntu:16.04 | |
MAINTAINER Chris Roane <chris.roane@fourkitchens.com> | |
# This was started from the docker file here: | |
# https://hub.docker.com/r/fauria/lamp/~/dockerfile/ | |
RUN DEBIAN_FRONTEND=noninteractive | |
# Replace shell with bash so we can source files. | |
RUN rm /bin/sh && ln -s /bin/bash /bin/sh | |
RUN apt-get update | |
RUN apt-get upgrade -y | |
RUN apt-get install -y \ | |
php7.0 \ | |
php7.0-bz2 \ | |
php7.0-cgi \ | |
php7.0-cli \ | |
php7.0-common \ | |
php7.0-curl \ | |
php7.0-dev \ | |
php7.0-enchant \ | |
php7.0-fpm \ | |
php7.0-gd \ | |
php7.0-gmp \ | |
php7.0-imap \ | |
php7.0-interbase \ | |
php7.0-intl \ | |
php7.0-json \ | |
php7.0-ldap \ | |
php7.0-mcrypt \ | |
php7.0-mysql \ | |
php7.0-odbc \ | |
php7.0-opcache \ | |
php7.0-pgsql \ | |
php7.0-phpdbg \ | |
php7.0-pspell \ | |
php7.0-readline \ | |
php7.0-recode \ | |
php7.0-snmp \ | |
php7.0-sqlite3 \ | |
php7.0-sybase \ | |
php7.0-tidy \ | |
php7.0-xmlrpc \ | |
php7.0-xsl \ | |
unzip \ | |
wget \ | |
sudo \ | |
ruby-sass \ | |
snmp | |
RUN apt-get install apache2 libapache2-mod-php7.0 -y | |
RUN apt-get install mariadb-common mariadb-server mariadb-client -y | |
RUN apt-get install git composer nano tree vim curl ftp php7.0-mbstring default-jre -y | |
ENV LOG_STDOUT **Boolean** | |
ENV LOG_STDERR **Boolean** | |
ENV LOG_LEVEL warn | |
ENV ALLOW_OVERRIDE All | |
ENV DATE_TIMEZONE UTC | |
ENV TERM dumb | |
RUN a2enmod rewrite | |
RUN chown -R www-data:www-data /var/www/html | |
VOLUME /var/www/html | |
VOLUME /var/log/httpd | |
VOLUME /var/lib/mysql | |
VOLUME /var/log/mysql | |
EXPOSE 80 | |
EXPOSE 3306 | |
# Install Chromedriver | |
RUN wget --no-check-certificate https://chromedriver.storage.googleapis.com/2.24/chromedriver_linux64.zip | |
RUN unzip chromedriver_linux64.zip | |
RUN chmod +x chromedriver | |
RUN mv -f chromedriver /usr/local/share/chromedriver | |
RUN ln -s /usr/local/share/chromedriver /usr/local/bin/chromedriver | |
RUN ln -s /usr/local/share/chromedriver /usr/bin/chromedriver | |
# Setup medstat.local. | |
RUN echo 127.0.0.1 medstat.local | tee -a /etc/hosts | |
# Node | |
RUN mkdir -p /tmp/node | |
WORKDIR /tmp/node | |
ENV NODE_VERSION 6.1.0 | |
ENV NPM_VERSION 5.4.0 | |
RUN curl -SLO "http://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-x64.tar.gz" \ | |
&& tar -xzf "node-v$NODE_VERSION-linux-x64.tar.gz" -C /usr/local --strip-components=1 \ | |
&& rm "node-v$NODE_VERSION-linux-x64.tar.gz" \ | |
&& npm install -g npm@"$NPM_VERSION" \ | |
&& npm cache clear --force \ | |
&& rm -rf /tmp/* | |
RUN sudo npm install -g gulp | |
# Install Drush | |
RUN sudo composer global require drush/drush:8.1.2 | |
ENV PATH="/root/.composer/vendor/bin:${PATH}" | |
# Set some git config. | |
RUN git config --global core.fileMode false | |
RUN git config --global http.sslverify false | |
# Disable host checking. | |
RUN mkdir $HOME/.ssh/ && echo "StrictHostKeyChecking no" >> "$HOME/.ssh/config" | |
# Install Solr. | |
WORKDIR "~/" | |
RUN wget http://archive.apache.org/dist/lucene/solr/4.7.2/solr-4.7.2.tgz \ | |
&& tar -xvzf solr-4.7.2.tgz | |
RUN curl https://ftp.drupal.org/files/projects/apachesolr-7.x-1.x-dev.tar.gz | tar -xz | |
RUN cp -r apachesolr/solr-conf/solr-4.x/* solr-4.7.2/example/solr/collection1/conf | |
RUN mv solr-4.7.2 ~/solr | |
RUN rm -rf apachesolr solr-4.7.2.tgz apachesolr-7.x-1.x-dev.tar.gz | |
# Download Selenium | |
RUN wget -O ~/selenium-server-standalone-2.48.2.jar http://selenium-release.storage.googleapis.com/2.48/selenium-server-standalone-2.48.2.jar | |
CMD ["supervisord", "--nodaemon"] | |
CMD ["service", "mysql", "start"] | |
CMD ["service", "php7-fpm", "start"] | |
CMD ["service", "apache", "start"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment