<commit_before>FROM ubuntu:14.04
MAINTAINER <NAME> <<EMAIL>>

RUN apt-get update && apt-get install -y \
  software-properties-common

RUN DEBIAN_FRONTEND=noninteractive add-apt-repository ppa:chris-lea/zeromq
RUN DEBIAN_FRONTEND=noninteractive add-apt-repository ppa:alexharrington/php-zmq

# Install apache, PHP, and supplimentary programs.
RUN apt-get update && apt-get install -y \
  apache2 \
  libapache2-mod-php5 \
  mysql-client \
  php5-mysql \
  php5-gd \
  php-pear \
  php-apc \
  php5-curl \
  curl \
  php5-mcrypt \
  php5-zmq \
  ssmtp \
  wget \
  anacron

# Enable apache mods and PHP extensions
RUN a2enmod php5 && a2enmod rewrite && php5enmod mcrypt

# Update the PHP.ini file
RUN sed -i "s/error_reporting = .*$/error_reporting = E_ERROR | E_WARNING | E_PARSE/" /etc/php5/apache2/php.ini
RUN sed -i "s/post_max_size = .*$/post_max_size = 810M/" /etc/php5/apache2/php.ini
RUN sed -i "s/upload_max_filesize = .*$/upload_max_filesize = 800M/" /etc/php5/apache2/php.ini
RUN sed -i "s/max_execution_time = .*$/max_execution_time = 300/" /etc/php5/apache2/php.ini
RUN sed -i "s/session.gc_probability = .*$/session.gc_probability = 1/" /etc/php5/apache2/php.ini
RUN sed -i "s/session.gc_divisor = .*$/session.gc_divisor = 100/" /etc/php5/apache2/php.ini

# Setup persistent environment variables
ENV XIBO_VERSION=1.8.0-alpha3 XMR_HOST=xibo-cms-xmr
ENV XIBO_SMTP_SERVER=smtp.gmail.com:587 XIBO_SMTP_USERNAME=none XIBO_SMTP_PASSWORD=none XIBO_SMTP_USE_TLS=YES XIBO_SMTP_USE_STARTTLS=YES XIBO_SMTP_REWRITE_DOMAIN=gmail.com XIBO_SMTP_HOSTNAME=none XIBO_SMTP_FROM_LINE_OVERRIDE=YES

# Expose port 80
EXPOSE 80

# Pull in the release archive for the environment
ADD https://github.com/xibosignage/xibo-cms/releases/download/${XIBO_VERSION}/xibo-cms-${XIBO_VERSION}.tar.gz /var/www/xibo-cms.tar.gz
ADD https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh  /usr/local/bin/wait-for-it.sh
ADD settings.php-template /tmp/settings.php-template
ADD ssmtp.conf /etc/ssmtp/ssmtp.conf

# Map a volumes to this folder.
# Our CMS files, library, cache and backups will be in here.
RUN mkdir -p /var/www/xibo && mkdir -p /var/www/backup
VOLUME /var/www/xibo
VOLUME /var/www/backup
<commit_msg>Disable cron from sending out emails to root via ssmtp<commit_after>FROM ubuntu:14.04
MAINTAINER <NAME> <<EMAIL>>

RUN apt-get update && apt-get install -y \
  software-properties-common

RUN DEBIAN_FRONTEND=noninteractive add-apt-repository ppa:chris-lea/zeromq
RUN DEBIAN_FRONTEND=noninteractive add-apt-repository ppa:alexharrington/php-zmq

# Install apache, PHP, and supplimentary programs.
RUN apt-get update && apt-get install -y \
  apache2 \
  libapache2-mod-php5 \
  mysql-client \
  php5-mysql \
  php5-gd \
  php5-curl \
  curl \
  php5-mcrypt \
  php5-zmq \
  ssmtp \
  wget \
  anacron

# Enable apache mods and PHP extensions
RUN a2enmod php5 && a2enmod rewrite && php5enmod mcrypt

# Update the PHP.ini file
RUN sed -i "s/error_reporting = .*$/error_reporting = E_ERROR | E_WARNING | E_PARSE/" /etc/php5/apache2/php.ini
RUN sed -i "s/post_max_size = .*$/post_max_size = 810M/" /etc/php5/apache2/php.ini
RUN sed -i "s/upload_max_filesize = .*$/upload_max_filesize = 800M/" /etc/php5/apache2/php.ini
RUN sed -i "s/max_execution_time = .*$/max_execution_time = 300/" /etc/php5/apache2/php.ini
RUN sed -i "s/session.gc_probability = .*$/session.gc_probability = 1/" /etc/php5/apache2/php.ini
RUN sed -i "s/session.gc_divisor = .*$/session.gc_divisor = 100/" /etc/php5/apache2/php.ini

# Disable cron sending emails to root
RUN awk '/PATH=/ { print; print "MAILTO=\"\""; next}1' /etc/crontab > /tmp/crontab && mv /tmp/crontab /etc/crontab
RUN awk '/LOGNAME=root/ { print; print "MAILTO=\"\""; next}1' /etc/anacrontab > /tmp/anacrontab && mv /tmp/anacrontab /etc/anacrontab

# Setup persistent environment variables
ENV XIBO_VERSION=1.8.0-alpha3 XMR_HOST=xibo-cms-xmr
ENV XIBO_SMTP_SERVER=smtp.gmail.com:587 XIBO_SMTP_USERNAME=none XIBO_SMTP_PASSWORD=none XIBO_SMTP_USE_TLS=YES XIBO_SMTP_USE_STARTTLS=YES XIBO_SMTP_REWRITE_DOMAIN=gmail.com XIBO_SMTP_HOSTNAME=none XIBO_SMTP_FROM_LINE_OVERRIDE=YES

# Expose port 80
EXPOSE 80

# Pull in the release archive for the environment
ADD https://github.com/xibosignage/xibo-cms/releases/download/${XIBO_VERSION}/xibo-cms-${XIBO_VERSION}.tar.gz /var/www/xibo-cms.tar.gz
ADD https://raw.githubusercontent.com/vishnubob/wait-for-it/master/wait-for-it.sh  /usr/local/bin/wait-for-it.sh
ADD settings.php-template /tmp/settings.php-template
ADD ssmtp.conf /etc/ssmtp/ssmtp.conf

# Map a volumes to this folder.
# Our CMS files, library, cache and backups will be in here.
RUN mkdir -p /var/www/xibo && mkdir -p /var/www/backup
VOLUME /var/www/xibo
VOLUME /var/www/backup

{'fraction_non_alphanumeric': 0.12748414376321354, 'fraction_numerical': 0.02241014799154334, 'mean_word_length': 4.022292993630574, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 11, 'https://': 4, 'lorem ipsum': 0, 'www.': 10, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '890452', 'n_tokens_mistral': 2008, 'n_tokens_neox': 1884, 'n_words': 389}