This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(* | |
Module: Access | |
Parses /etc/security/access.conf | |
Author: Lorenzo Dalrio <lorenzo.dalrio@gmail.com> | |
About: Reference | |
Some examples of valid entries can be found in access.conf or "man access.conf" | |
About: License |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/spec/unit/provider/augeas/augeas_spec.rb b/spec/unit/provider/augeas/augeas_spec.rb | |
index 693e33e..b8aade2 100755 | |
--- a/spec/unit/provider/augeas/augeas_spec.rb | |
+++ b/spec/unit/provider/augeas/augeas_spec.rb | |
@@ -373,8 +373,7 @@ describe provider_class do | |
augeas_stub = stub("augeas") | |
augeas_stub.expects("set").with("/augeas/save", "newfile") | |
augeas_stub.expects("save").returns(true) | |
- augeas_stub.expects("get").with("/augeas/events/saved").returns([]) | |
- augeas_stub.expects("match").with("/augeas/events/saved").returns([]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rexml/document' | |
Puppet::Type.type(:ha_crm_property).provide(:crm) do | |
def create | |
lazy_crm_attribute "-t", "crm_config", "-n", resource[:name], "-v", resource[:value] | |
end | |
def destroy | |
lazy_crm_attribute "-t", "crm_config", "-n", resource[:name], "-D" | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* pagesize: reads the page size for a virtual memory address of a given pid */ | |
#include <errno.h> | |
#include <stdio.h> | |
#include <stdint.h> | |
#include <stdlib.h> | |
#include <unistd.h> | |
int main(int argc, char** argv) { | |
if (argc != 3) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Uploads a list of radio stations into an Onkyo receiver's web page | |
# Tested with a TX-NR509. | |
# | |
# Supply the list as "NAME=URL" lines on stdin. | |
# | |
# Copyright (c) 2011 Dominic Cleal <dominic@computerkb.co.uk> | |
# Released under the MIT licence. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include b # works | |
include c # 'broken', shows warning | |
define a($x) { | |
exec { "A-$x": | |
command => "/bin/echo $x", | |
} | |
if $require { | |
Exec["A-$x"] { require +> $require } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exec { "foo": | |
command => "/bin/echo foo", | |
} | |
file { "/tmp/test": | |
ensure => link, | |
replace => true, | |
target => "/tmp/foo", | |
force => true, | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
quoting.pp: | |
$node = "foo" | |
augeas { "set-entry": | |
context => "/files/etc/sysconfig/network", | |
changes => [ | |
"set INLINE[. = '\"$node\"'] '\"$node\"'", | |
], | |
} | |
augeas { "set-erb": |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Test_zabbix_agent = | |
let example = "########################################################### | |
# PUPPET MANAGED # | |
# Do not edit this file on a server node unless you # | |
# are willing to have your changes overwritten by # | |
# Puppet. If you really want to change the contents # | |
# repository and check it out on the puppet server. # | |
########################################################### | |
# This is config file for zabbix_agentd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Tests for aug_srun | |
# Blank lines and lines starting with '#' are ignored. This file is | |
# processed by test-run.c | |
# | |
# The syntax for a test specification is | |
# test NAME RESULT ERRCODE | |
# COMMANDS | |
# prints | |
# OUTPUT |
OlderNewer