<commit_before>FROM ubuntu
MAINTAINER <NAME> <<EMAIL>>
RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
RUN apt-get update
RUN apt-get -y upgrade

RUN locale-gen en_US.UTF-8
ENV LANG       en_US.UTF-8
ENV LC_ALL     en_US.UTF-8

# Discourse suggests using `tasksel`, but we can just install the packages `tasksel` would select.
RUN apt-get install -y postgresql postfix

# Install necessary packages
RUN apt-get -y install build-essential libssl-dev libyaml-dev git libtool libxslt-dev libxml2-dev libpq-dev gawk curl pngcrush imagemagick python-software-properties

# Install Redis
RUN apt-add-repository -y ppa:rwky/redis
RUN apt-get update
RUN apt-get install redis-server<commit_msg>Got to the point of installing Discourse.<commit_after>FROM ubuntu
MAINTAINER <NAME> <<EMAIL>>
RUN echo "deb http://archive.ubuntu.com/ubuntu precise main universe" > /etc/apt/sources.list
RUN apt-get update
RUN apt-get -y upgrade

RUN locale-gen en_US.UTF-8
ENV LANG       en_US.UTF-8
ENV LC_ALL     en_US.UTF-8

# Discourse suggests using `tasksel`,
# but we can just install the packages `tasksel` would select.
RUN apt-get install -y postgresql postfix

# Install necessary packages
RUN apt-get -y install build-essential libssl-dev libyaml-dev git libtool \
        libxslt-dev libxml2-dev libpq-dev gawk curl pngcrush imagemagick  \
        python-software-properties

# Install Redis
RUN apt-add-repository -y ppa:rwky/redis
RUN apt-get update
RUN apt-get install redis-server

# Install Nginx
RUN add-apt-repository ppa:nginx/stable
RUN apt-get update
RUN apt-get install -y nginx

# Create the discourse user.
RUN adduser --shell /bin/bash --gecos 'Discourse application' discourse
RUN install -d -m 755 -o discourse -g discourse /var/www/discourse

# Give Postgres database rights to the discourse user.
RUN /etc/init.d/postgresql start && /bin/su postgres -c 'createuser -s discourse'

# Install Ruby 2.0.0 with RVM as the discourse user.
RUN /bin/su discourse -c '\curl -L https://get.rvm.io | bash -s stable'
RUN /bin/su discourse -c 'cat ~/.bash_profile >> ~/.profile && rm ~/.bash_profile'
RUN /home/discourse/.rvm/bin/rvm requirements
RUN /bin/su discourse -c '. ~/.profile && rvm install 2.0.0'
RUN /bin/su discourse -c '. ~/.profile && rvm use 2.0.0 --default'
RUN /bin/su discourse -c '. ~/.profile && gem install bundler'

# Install Discourse
RUN mkdir -p /srv/www
RUN git clone https://github.com/discourse/discourse.git /srv/www
RUN cd /srv/www && git checkout latest-release
RUN chown -R discourse:discourse /srv/www
RUN cd /srv/www && /bin/su discourse -c '. ~/.profile && bundle install --deployment --without test'
{'fraction_non_alphanumeric': 0.10741017964071856, 'fraction_numerical': 0.0074850299401197605, 'mean_word_length': 3.5927835051546393, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, 'https://': 2, 'lorem ipsum': 0, 'www.': 3, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4897066', 'n_tokens_mistral': 923, 'n_tokens_neox': 865, 'n_words': 311}