This file contains hidden or 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
| --- | |
| driver: | |
| name: ec2 | |
| aws_ssh_key_id: chef_demo_2x | |
| region: us-west-2 | |
| subnet_id: subnet-da4bd3bf | |
| security_group_ids: sg-1cea9178 | |
| associate_public_ip: true | |
| instance_type: t2.micro | |
| tags: |
This file contains hidden or 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
| # encoding: utf-8 | |
| # copyright: 2015, The Authors | |
| title 'AWS Inspec Demo Profile' | |
| control 'aws-production-instances' do | |
| impact 1.0 | |
| title 'Check Production Instances' | |
| desc 'Make sure the status of production AWS instances is set to running.' |
This file contains hidden or 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
| chef_gem 'oneview-sdk' do | |
| compile_time true | |
| end | |
| require 'oneview-sdk' | |
| my_client = { url: 'https://192.168.20.20', user: 'Administrator', password: '*******', api_version: 500 } | |
| # Create a new fiber channel network | |
| oneview_fc_network 'FCNetwork1' do |
This file contains hidden or 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
| #shelltitle '' | |
| vbell on | |
| autodetach on | |
| startup_message off | |
| defscrollback 2048 | |
| #termcapinfo xterm* ti@:te@ | |
| termcapinfo xterm* 'is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;4;6l' | |
| hardstatus alwayslastline "%-Lw%{= BW}%50>%n%f* %t%{-}%+Lw%< %=%D %M %d %c" | |
| #hardstatus string '%{= kK}%-Lw%{= KW}%50>%n%f %t%{= kK}%+Lw%< %{=kG}%-= %d%M %c:%s%{-}' |
This file contains hidden or 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/sh | |
| getRegions() { | |
| aws ec2 describe-regions --output text --query 'Regions[*].RegionName' | |
| } | |
| getInstances() { | |
| REGION=$1 | |
| if [ "$#" -ne 1 ]; then | |
| echo "USAGE: getInstances us-west-2" |
This file contains hidden or 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
| { | |
| "emojis": [ | |
| {"emoji": "π©βπ©βπ§βπ§", "name": "family_mothers_two_girls", "shortname": "", "unicode": "", "html": "👩‍👩‍👧‍👧", "category": "p", "order": ""}, | |
| {"emoji": "π©βπ©βπ§βπ¦", "name": "family_mothers_children", "shortname": "", "unicode": "", "html": "👩‍👩‍👧‍👦", "category": "p", "order": ""}, | |
| {"emoji": "π©βπ©βπ¦βπ¦", "name": "family_mothers_two_boys", "shortname": "", "unicode": "", "html": "👩‍👩‍👦‍👦", "category": "p", "order": ""}, | |
| {"emoji": "π¨βπ©βπ§βπ§", "name": "family_two_girls", "shortname": "", "unicode": "", "html": "👨‍👩‍👧‍👧", "category": "p", "order": ""}, | |
| {"emoji": "π¨βπ©βπ§βπ¦", "name": "family_children", "shortname": "", "unicode": "", "html": "👨‍👩‍👧‍👦", "category": "p", "order": ""}, | |
| {"emoji": "π¨βπ©βπ¦βπ¦", "name": "family_two_boys", "shortname": "", "unicode": "", "html": "👨&zw |
This file contains hidden or 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/sh | |
| # Script for rotating passwords on the local machine. | |
| # Make sure and store VAULT_TOKEN as an environment variable before running this. | |
| USERNAME=$1 | |
| PASSLENGTH=$2 | |
| VAULTURL=$3 | |
| NEWPASS=$(openssl rand -base64 $PASSLENGTH) | |
| JSON="{ \"data\": { \"root\": \"$NEWPASS\" } }" |
This file contains hidden or 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
| # My first Terraform | |
| variable "access_key" {} | |
| variable "secret_key" {} | |
| variable "ami" {} | |
| variable "subnet_id" {} | |
| variable "instance_type" {} | |
| variable "vpc_security_group_id" {} | |
| variable "identity" {} |
This file contains hidden or 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
| variable "access_key" {} | |
| variable "secret_key" {} | |
| variable "region" {} | |
| variable ami {} | |
| variable subnet_id {} | |
| variable instance_type { | |
| default = "t2.micro" | |
| } | |
| variable vpc_security_group_id {} | |
| variable identity {} |
This file contains hidden or 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
| # First enable the userpass auth engine | |
| # | |
| # vault auth enable userpass | |
| # vault write auth/userpass/users/alice password=alice policies="default,dev" | |
| # vault write auth/userpass/users/bob password=bob policies="default,prod" | |
| # Then create these policies | |
| # dev | |
| path "sys/mounts" { |