Skip to content

Instantly share code, notes, and snippets.

View deric4's full-sized avatar
🌮
DevSecOpsLeanSREAgileWTFBBQ

deric4 deric4

🌮
DevSecOpsLeanSREAgileWTFBBQ
  • The Hood Canal
View GitHub Profile
Puppet::Parser::Functions.newfunction(:default_content,
:type => :rvalue,
:doc => <<-'ENDOFDOC'
Takes an optional content and an optional template name and returns the
contents of a file.
Examples:
$config_file_content = default_content($file_content, $template_location)
file { '/tmp/x':
@andreicristianpetcu
andreicristianpetcu / ansible-summary.md
Created May 30, 2016 19:25
This is an ANSIBLE Cheat Sheet from Jon Warbrick

An Ansible summary

Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)

Configuration file

intro_configuration.html

First one found from of

@zhujunsan
zhujunsan / Using Github Deploy Key.md
Last active June 2, 2025 02:25
Using Github Deploy Key

What / Why

Deploy key is a SSH key set in your repo to grant client read-only (as well as r/w, if you want) access to your repo.

As the name says, its primary function is to be used in the deploy process in replace of username/password, where only read access is needed. Therefore keep the repo safe from the attack, in case the server side is fallen.

How to

  1. Generate a ssh key
@hlindberg
hlindberg / fizzbuzz.pp
Last active July 9, 2020 23:31
FizzBuzz in Puppet 4.1
notice Integer[0,99].map |$x| {
case [$x % 3, $x % 5] {
[0, 0] : { fizzbuzz }
[0, default] : { fizz }
[default, 0] : { buzz }
default : { $x }
}
}