<commit_before>FROM debian:jessie
MAINTAINER airstack team <<EMAIL>>

USER root
ENV HOME /root
WORKDIR /root

#----
# Packages
#----

# install commands
# TODO: move PKG_INSTALL to core/service-install to get rid of evil eval below
ENV PKG_INSTALL apt-get update; apt-get install -o Dpkg::Options::=--force-confdef -o Dpkg::Options::=--force-confold --no-install-recommends --no-install-suggests -y
ENV DEBIAN_FRONTEND noninteractive

# TODO: refactor without eval. or remove and handle elsewhere so not distro-specific

# Try and have binaries that are modified less often up at top of this package section.

# Packages::Common
RUN set -x; eval $PKG_INSTALL apt-utils net-tools less curl wget unzip sudo ca-certificates procps jq

# Packages::Development-Utils
RUN set -x; eval $PKG_INSTALL vim-tiny ethtool bwm-ng man-db psmisc

# Packages::runit
RUN set -x; eval $PKG_INSTALL runit

# Packages::socklog
RUN set -x; eval $PKG_INSTALL socklog ipsvd

# Packages::dropbear
RUN set -x; eval $PKG_INSTALL dropbear

# Packages::haproxy
RUN set -x; eval $PKG_INSTALL haproxy

# Packages::serf
RUN set -x; wget -vO serf.zip https://dl.bintray.com/mitchellh/serf/0.6.3_linux_amd64.zip && \
  unzip serf.zip && mv serf /usr/local/bin && rm -vf ./serf.zip

#----
# Base Environment
#----

# TODO: load all tags from json then remove these ENVs
ENV AIRSTACK_TAGS_CLUSTERNAME airstack_cluster
ENV AIRSTACK_TAGS_NAME component
ENV AIRSTACK_TAGS_ENV development
ENV AIRSTACK_TAGS_ROLE base

# TODO: see PKG_INSTALL todo above
# base packages install
# RUN service-install apt-utils net-tools less curl wget unzip sudo ca-certificates procps jq
# install development packages if in development environment
# RUN [ $AIRSTACK_TAGS_ENV = "development" ] && service-install $AIRSTACK_PKGS_DEVELOPMENT

#----
# Services
#----

# TODO: do we need this?
ENV AIRSTACK_RUNTIME_VARS ""

#service env vars
# TODO: remove AIRSTACK_SERVICES; use runtime.json
ENV AIRSTACK_SERVICES dropbear serf haproxy

#password set in sshd/run script at ssh start. allows for override via env var.
RUN \<commit_msg>Add luarocks and lua packages to Dockerfile<commit_after>FROM debian:jessie
MAINTAINER airstack team <<EMAIL>>

USER root
ENV HOME /root
WORKDIR /root

#----
# Packages
#----

# install commands
# TODO: move PKG_INSTALL to core/service-install to get rid of evil eval below
ENV PKG_INSTALL apt-get update; apt-get install -o Dpkg::Options::=--force-confdef -o Dpkg::Options::=--force-confold --no-install-recommends --no-install-suggests -y
ENV DEBIAN_FRONTEND noninteractive

# TODO: refactor without eval. or remove and handle elsewhere so not distro-specific

# Try and have binaries that are modified less often up at top of this package section.

# Packages::Common
RUN set -x; eval $PKG_INSTALL apt-utils net-tools less curl wget unzip sudo ca-certificates procps jq

# Packages::Development-Utils
RUN set -x; eval $PKG_INSTALL vim-tiny ethtool bwm-ng man-db psmisc

# Packages::runit
RUN set -x; eval $PKG_INSTALL runit

# Packages::socklog
RUN set -x; eval $PKG_INSTALL socklog ipsvd

# Packages::dropbear
RUN set -x; eval $PKG_INSTALL dropbear

# Packages::haproxy
RUN set -x; eval $PKG_INSTALL haproxy

# Packages::serf
RUN set -x; wget -vO serf.zip https://dl.bintray.com/mitchellh/serf/0.6.3_linux_amd64.zip && \
  unzip serf.zip && mv serf /usr/local/bin && rm -vf ./serf.zip

# Packages::Lua
RUN set -x; eval $PKG_INSTALL luarocks

#----
# Base Environment
#----

# TODO: load all tags from json then remove these ENVs
ENV AIRSTACK_TAGS_CLUSTERNAME airstack_cluster
ENV AIRSTACK_TAGS_NAME component
ENV AIRSTACK_TAGS_ENV development
ENV AIRSTACK_TAGS_ROLE base

# TODO: see PKG_INSTALL todo above
# base packages install
# RUN service-install apt-utils net-tools less curl wget unzip sudo ca-certificates procps jq
# install development packages if in development environment
# RUN [ $AIRSTACK_TAGS_ENV = "development" ] && service-install $AIRSTACK_PKGS_DEVELOPMENT

#----
# Services
#----

# TODO: do we need this?
ENV AIRSTACK_RUNTIME_VARS ""

#service env vars
# TODO: remove AIRSTACK_SERVICES; use runtime.json
ENV AIRSTACK_SERVICES dropbear serf haproxy

#password set in sshd/run script at ssh start. allows for override via env var.
RUN \
{'fraction_non_alphanumeric': 0.0944733112895607, 'fraction_numerical': 0.0023618327822390174, 'mean_word_length': 4.327044025157233, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, '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': '439576', 'n_tokens_mistral': 1520, 'n_tokens_neox': 1425, 'n_words': 485}