<commit_before># Copyright (c) 2015 The Pycroft Authors. See the AUTHORS file.
# This file is part of the Pycroft project and licensed under the terms of
# the Apache License, Version 2.0. See the LICENSE file for details.
FROM debian:jessie
ARG UID=1000
ARG GID=1000
ENV PROJECT_DIR=/pycroft LANG=C.UTF-8 DEBIAN_FRONTEND=noninteractive

COPY vagrant/ /

# Install Debian packages
# Build-essential is needed For compiling things in pip
RUN apt-key add /etc/nodesource.gpg.key && apt-get update \
    && apt-get install -y --no-install-recommends \
        bash \
        curl \
        git \
        libpq-dev \
        nodejs \
        python3-dev \
        python3-venv \
        build-essential \
        vim \
    && apt-get clean \
    && npm install -g bower

RUN groupadd --force --gid $GID pycroft \
    && useradd --non-unique --home-dir $PROJECT_DIR --create-home --uid $UID --gid $GID --comment "Application" pycroft \
    && mkdir -p /opt/venv && chown pycroft:pycroft /opt/venv

USER pycroft
WORKDIR $PROJECT_DIR

COPY --chown=pycroft:pycroft . .

# - Create a virtual environment
# - Upgrade pip, setuptools and wheel
# - Install requirements and pycroft in editable mode
# - Install JavaScript/CSS/HTML requirements with Bower
RUN python3 -m venv /opt/venv \
    && /opt/venv/bin/pip install -U pip setuptools wheel \
    && /opt/venv/bin/pip install -r /requirements.txt -e . \
    && bower install -F \
    && bower update -F

EXPOSE 5000
ENTRYPOINT ["./entrypoint.sh"]
CMD ["pycroft", "--debug", "--exposed"]
<commit_msg>Sort Debian packages<commit_after># Copyright (c) 2015 The Pycroft Authors. See the AUTHORS file.
# This file is part of the Pycroft project and licensed under the terms of
# the Apache License, Version 2.0. See the LICENSE file for details.
FROM debian:jessie
ARG UID=1000
ARG GID=1000
ENV PROJECT_DIR=/pycroft LANG=C.UTF-8 DEBIAN_FRONTEND=noninteractive

COPY vagrant/ /

# Install Debian packages
# Build-essential is needed For compiling things in pip
RUN apt-key add /etc/nodesource.gpg.key && apt-get update \
    && apt-get install -y --no-install-recommends \
        bash \
        build-essential \
        curl \
        git \
        libpq-dev \
        nodejs \
        python3-dev \
        python3-venv \
        vim \
    && apt-get clean \
    && npm install -g bower

RUN groupadd --force --gid $GID pycroft \
    && useradd --non-unique --home-dir $PROJECT_DIR --create-home --uid $UID --gid $GID --comment "Application" pycroft \
    && mkdir -p /opt/venv && chown pycroft:pycroft /opt/venv

USER pycroft
WORKDIR $PROJECT_DIR

COPY --chown=pycroft:pycroft . .

# - Create a virtual environment
# - Upgrade pip, setuptools and wheel
# - Install requirements and pycroft in editable mode
# - Install JavaScript/CSS/HTML requirements with Bower
RUN python3 -m venv /opt/venv \
    && /opt/venv/bin/pip install -U pip setuptools wheel \
    && /opt/venv/bin/pip install -r /requirements.txt -e . \
    && bower install -F \
    && bower update -F

EXPOSE 5000
ENTRYPOINT ["./entrypoint.sh"]
CMD ["pycroft", "--debug", "--exposed"]

{'fraction_non_alphanumeric': 0.11337868480725624, 'fraction_numerical': 0.014253320375769355, 'mean_word_length': 2.5617070357554788, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, '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': '3331368', 'n_tokens_mistral': 1080, 'n_tokens_neox': 990, 'n_words': 332}