<commit_before>FROM debian:9

# TODO use debian 9 chef package (not released yet)
RUN apt-get update && apt-get install -y curl gnupg && \
    curl -sL -o /tmp/chef_12.19.36-1_amd64.deb \
        https://packages.chef.io/files/stable/chef/12.19.36/debian/8/chef_12.19.36-1_amd64.deb && \
    dpkg -i /tmp/chef_12.19.36-1_amd64.deb

RUN install -d -m 755 /cookbooks /etc/chef /var/chef/node

RUN echo "local_mode      true" >> /etc/chef/client.rb;  \
    echo "cookbook_path  ['/cookbooks']" >> /etc/chef/client.rb; \
    echo "cache_path      '/var/chef/cache'" >> /etc/chef/client.rb; \
    echo "node_path       '/var/chef/node'" >> /etc/chef/client.rb; \
    echo "environment     '_default'" >> /etc/chef/client.rb; \
    echo "ssl_verify_mode :verify_peer" >> /etc/chef/client.rb;
RUN echo '{"run_list":["recipe[mackerel-agent]"], "mackerel-agent": {"start_on_setup": false}}' > /var/chef/node/localhost.json

COPY ./cookbooks /cookbooks

RUN chef-client -j /var/chef/node/localhost.json
<commit_msg>Need to bump chef for debian 9 (really????)<commit_after>FROM debian:9

# TODO use debian 9 chef package (not released yet)
RUN apt-get update && apt-get install -y curl gnupg && \
    curl -sL -o /tmp/chef_13.1.31-1_amd64.deb \
        https://packages.chef.io/files/stable/chef/13.1.31/debian/8/chef_13.1.31-1_amd64.deb && \
    dpkg -i /tmp/chef_13.1.31-1_amd64.deb

RUN install -d -m 755 /cookbooks /etc/chef /var/chef/node

RUN echo "local_mode      true" >> /etc/chef/client.rb;  \
    echo "cookbook_path  ['/cookbooks']" >> /etc/chef/client.rb; \
    echo "cache_path      '/var/chef/cache'" >> /etc/chef/client.rb; \
    echo "node_path       '/var/chef/node'" >> /etc/chef/client.rb; \
    echo "environment     '_default'" >> /etc/chef/client.rb; \
    echo "ssl_verify_mode :verify_peer" >> /etc/chef/client.rb;
RUN echo '{"run_list":["recipe[mackerel-agent]"], "mackerel-agent": {"start_on_setup": false}}' > /var/chef/node/localhost.json

COPY ./cookbooks /cookbooks

RUN chef-client -j /var/chef/node/localhost.json

{'fraction_non_alphanumeric': 0.17681728880157171, 'fraction_numerical': 0.03683693516699411, 'mean_word_length': 2.9324324324324325, 'pattern_counts': {'":': 6, '<': 3, '<?xml version=': 0, '>': 29, 'https://': 2, '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': '2457039', 'n_tokens_mistral': 857, 'n_tokens_neox': 799, 'n_words': 155}