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
# Statics | |
location /(bundles|css|fonts|images|js) { | |
access_log off; | |
expires 30d; | |
add_header 'Access-Control-Allow-Origin' '*'; | |
add_header 'Access-Control-Allow-Methods' 'GET'; | |
try_files $uri =404; | |
} |
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
/* | |
******************************************************************************** | |
Golang - Asterisk and Ampersand Cheatsheet | |
******************************************************************************** | |
Also available at: https://play.golang.org/p/lNpnS9j1ma | |
Allowed: | |
-------- | |
p := Person{"Steve", 28} stores the value |
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
.ONESHELL: | |
.PHONEY: help set-env init update plan plan-destroy show graph apply output taint | |
help: | |
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' | |
set-env: | |
@if [ -z $(ENVIRONMENT) ]; then\ | |
echo "ENVIRONMENT was not set"; exit 10;\ | |
fi |
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@localhost ~]# augtool ls /files/boot/grub/grub.conf | |
#comment[1] = grub.conf generated by anaconda | |
#comment[2] = Note that you do not have to rerun grub after making changes to this file | |
#comment[3] = NOTICE: You have a /boot partition. This means that | |
#comment[4] = all kernel and initrd paths are relative to /boot/, eg. | |
#comment[5] = root (hd0,0) | |
#comment[6] = kernel /vmlinuz-version ro root=/dev/mapper/VolGroup-lv_root | |
#comment[7] = initrd /initrd-[generic-]version.img | |
#comment[8] = boot=/dev/sda | |
default = 0 |
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
augeas { "sysctl": | |
context => '/files/etc/sysctl.conf', | |
changes => [ | |
'set kernel.keys.root_maxkeys 1000000', | |
], | |
} |
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
augeas { 'grub_conf': | |
incl => '/boot/grub/grub.conf', | |
lens => 'grub.lns', | |
changes => [ | |
'set default 0', | |
'setm title[1]/kernel swapaccount 1', | |
'rm title[1]/kernel/quiet', | |
'rm title[1]/kernel/rhgb' | |
], | |
require => Package['kernel-lt'] |
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
resource "aws_vpc" "vpc" { | |
cidr_block = "${var.environment["vpc_cidr"]}" | |
enable_dns_hostnames = true | |
enable_dns_support = true | |
instance_tenancy = "default" | |
tags { | |
Name = "${var.environment["name"]}-vpc" | |
TF = "YES" | |
} |
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
Closure job = { | |
// Job Name | |
name "${stashProjectKey}-${projectName}-${branchSimpleName}" | |
// Where should jenkins run the job | |
label ('master') | |
// Where should Jenkins get the source code from | |
scm { | |
git { |
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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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
$ yum provides /usr/bin/host | |
Loaded plugins: fastestmirror | |
... | |
32:bind-utils-9.8.2-0.17.rc1.el6_4.6.x86_64 : Utilities for querying DNS name servers | |
Repo : base | |
Matched from: | |
Filename : /usr/bin/host | |
32:bind-utils-9.8.2-0.23.rc1.el6_5.1.x86_64 : Utilities for querying DNS name servers | |
Repo : updates |