<commit_before>FROM ubuntu:14.04

RUN apt-get update 
RUN apt-get -y install software-properties-common python-pip

# ocpkg tool to install repositories and dependencies
COPY scripts/ocpkg scripts/install-dependencies-trusty\
    opencog/python/requirements.txt /tmp/
RUN chmod +x /tmp/install-dependencies-trusty
RUN /tmp/install-dependencies-trusty
RUN pip install -U -r /tmp/requirements.txt

# Create and switch user. The user is privileged with no password required
RUN adduser --disabled-password --gecos "OpenCog Developer" opencog
RUN adduser opencog sudo
RUN echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
USER opencog

# Tools
RUN sudo apt-get -y install git
RUN sudo apt-get -y install rlwrap telnet netcat-openbsd

# Environment Variables
## Set Locale
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8

# Defaults
## cogserver shell ports
EXPOSE 17001 18001<commit_msg>docker: build locales BEFORE switching user!<commit_after>FROM ubuntu:14.04

RUN apt-get update 
RUN apt-get -y install software-properties-common python-pip

# ocpkg tool to install repositories and dependencies
COPY scripts/ocpkg scripts/install-dependencies-trusty\
    opencog/python/requirements.txt /tmp/
RUN chmod +x /tmp/install-dependencies-trusty
RUN /tmp/install-dependencies-trusty
RUN pip install -U -r /tmp/requirements.txt

# Tools
RUN apt-get -y install git
RUN apt-get -y install rlwrap telnet netcat-openbsd

# Environment Variables
## Set Locale
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8

# Create and switch user. The user is privileged with no password required
RUN adduser --disabled-password --gecos "<PASSWORD>" opencog
RUN adduser opencog sudo
RUN echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
USER opencog

# Defaults
## cogserver shell ports
EXPOSE 17001 18001
{'fraction_non_alphanumeric': 0.0832443970117396, 'fraction_numerical': 0.01814300960512273, 'mean_word_length': 4.403458213256484, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7404054', 'n_tokens_mistral': 668, 'n_tokens_neox': 605, 'n_words': 209}