<commit_before>FROM python:3.8-alpine3.12
MAINTAINER <NAME> <<EMAIL>>

EXPOSE 8080
WORKDIR /app/

# Install packages required
ENV PYPICLOUD_VERSION 1.3.11
ENV CARGO_NET_GIT_FETCH_WITH_CLI true
RUN --mount=type=tmpfs,target=/root/.cargo \
  apk add --no-cache --virtual build-deps python3-dev mariadb-dev postgresql-dev build-base \
  linux-headers openldap-dev autoconf automake make libffi-dev libressl-dev musl-dev cargo git \
  && apk add --no-cache libldap libpq mariadb-connector-c-dev mariadb-connector-c util-linux-dev g++ \
  && python -m pip install --no-cache-dir --upgrade pip setuptools \
  && python -m pip install --no-cache-dir pypicloud[all_plugins]==$PYPICLOUD_VERSION \
    requests uwsgi pastescript mysqlclient psycopg2-binary bcrypt cryptography \
    --no-binary cryptography,uwsgi \
  && adduser -D -s /bin/sh -h /var/lib/pypicloud/ pypicloud \
  && apk del --no-cache build-deps \
  && mkdir -p /etc/pypicloud

# Add the command for easily creating config files
ADD config.ini /etc/pypicloud/config.ini
ADD make-config.sh /usr/local/bin/make-config

# Create a working directory for pypicloud
VOLUME /var/lib/pypicloud

# Run as pypicloud user
USER pypicloud

CMD ["uwsgi", "--die-on-term", "/etc/pypicloud/config.ini"]
<commit_msg>fix: install newer version of rust on alpine<commit_after>FROM python:3.8-alpine3.12
MAINTAINER <NAME> <<EMAIL>>

EXPOSE 8080
WORKDIR /app/

# Install packages required
ENV PYPICLOUD_VERSION 1.3.11
ENV CARGO_NET_GIT_FETCH_WITH_CLI true
RUN --mount=type=tmpfs,target=/root/.cargo \
  apk add --no-cache --virtual build-deps python3-dev mariadb-dev postgresql-dev build-base gcc \
  linux-headers openldap-dev autoconf automake make libffi-dev libressl-dev musl-dev git curl \
  && curl –proto '=https' –tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y \
  && source ~/.cargo/env \
  && apk add --no-cache libldap libpq mariadb-connector-c-dev mariadb-connector-c util-linux-dev g++ \
  && python -m pip install --no-cache-dir --upgrade pip setuptools \
  && python -m pip install --no-cache-dir pypicloud[all_plugins]==$PYPICLOUD_VERSION \
    requests uwsgi pastescript mysqlclient psycopg2-binary bcrypt cryptography \
    --no-binary cryptography,uwsgi \
  && adduser -D -s /bin/sh -h /var/lib/pypicloud/ pypicloud \
  && apk del --no-cache build-deps \
  && mkdir -p /etc/pypicloud

# Add the command for easily creating config files
ADD config.ini /etc/pypicloud/config.ini
ADD make-config.sh /usr/local/bin/make-config

# Create a working directory for pypicloud
VOLUME /var/lib/pypicloud

# Run as pypicloud user
USER pypicloud

CMD ["uwsgi", "--die-on-term", "/etc/pypicloud/config.ini"]

{'fraction_non_alphanumeric': 0.12377358490566037, 'fraction_numerical': 0.012075471698113207, 'mean_word_length': 3.547169811320755, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 1, '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': '3910148', 'n_tokens_mistral': 1016, 'n_tokens_neox': 1013, 'n_words': 253}