<commit_before># ex: set tabstop=2 shiftwidth=2 expandtab:
#
# Cookbook Name:: serverdensity
# Recipe:: install

case node[:platform]

when "debian", "ubuntu"
  include_recipe "apt"

  apt_repository "serverdensity" do
    key "https://www.serverdensity.com/downloads/boxedice-public.key"
    uri "https://www.serverdensity.com/downloads/linux/deb"
    distribution "all"
    components ["main"]
    action :add
  end

  # Update the local package list
  execute "serverdensity-apt-get-update" do
    command "apt-get update"
    action :nothing
  end

when "redhat", "centos", "fedora", "scientific", "amazon"
  include_recipe "yum::epel"

  yum_repository "serverdensity" do
    name "Server Density"
    description "Server Density sd-agent"
    url "https://www.serverdensity.com/downloads/linux/redhat/" <commit_msg>Use GPG key for yum repo<commit_after># ex: set tabstop=2 shiftwidth=2 expandtab:
#
# Cookbook Name:: serverdensity
# Recipe:: install

case node[:platform]

when "debian", "ubuntu"
  include_recipe "apt"

  apt_repository "serverdensity" do
    key "https://www.serverdensity.com/downloads/boxedice-public.key"
    uri "https://www.serverdensity.com/downloads/linux/deb"
    distribution "all"
    components ["main"]
    action :add
  end

  # Update the local package list
  execute "serverdensity-apt-get-update" do
    command "apt-get update"
    action :nothing

  end

when "redhat", "centos", "fedora", "scientific", "amazon"
  include_recipe "yum::epel"

  yum_repository "serverdensity" do
    name "Server Density"
    description "Server Density sd-agent"
    url "https://www.serverdensity.com/downloads/linux/redhat/" 
    key_url "https://www.serverdensity.com/downloads/boxedice-public.key"
{'fraction_non_alphanumeric': 0.1232638888888889, 'fraction_numerical': 0.0023148148148148147, 'mean_word_length': 4.070381231671554, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 7, 'lorem ipsum': 0, 'www.': 7, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 7, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4779802', 'n_tokens_mistral': 580, 'n_tokens_neox': 557, 'n_words': 139}