gitflow | git |
---|---|
git flow init |
git init |
git commit --allow-empty -m "Initial commit" |
|
git checkout -b develop master |
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
# complain if no snapshot id provided | |
# | |
snapshot_id = node[:channels][:database][:snapshot_id] rescue nil | |
raise "No snapshot id specified." if snapshot_id.blank? | |
device = node[:channels][:database][:device] rescue nil | |
raise "No device specified for the database volume" if device.blank? | |
# mount ebs volume | |
# |
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
aws_ebs_volume "my_ebs_volume" do | |
aws_access_key node[:aws][:aws_access_key_id] | |
aws_secret_access_key node[:aws][:aws_secret_access_key] | |
size 50 | |
device "/dev/sdi" | |
volume_id node[:ebs][:volume_id] | |
action [ :create, :attach ] | |
provider "aws_ebs_volume" | |
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
# Chef Client Config File | |
# Automatically grabs configuration from ohai ec2 metadata. | |
require 'ohai' | |
require 'json' | |
o = Ohai::System.new | |
o.all_plugins | |
chef_config = JSON.parse(o[:ec2][:userdata]) | |
if chef_config.kind_of?(Array) |
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
# Completely untested. | |
gem_package "amazon-ec2" | |
aws = search("aws", "main") | |
Gem.clear_paths | |
ruby_block do "register_with_elb" do | |
do | |
require 'amazon-ec2' |
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
# inspiration | |
# http://github.com/jnstq/rails-nginx-passenger-ubuntu | |
# sudo this sudo that bollocks | |
sudo -i | |
# system-related stuff | |
apt-get install htop strace sysstat | |
dpkg-reconfigure sysstat | |
apt-get install ntp |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
I largely followed Florin's blog post, but have a few notes to add regarding issues I encountered:
- I used a YubiKey 4, while the blog describes using a YubiKey NEO. I'm sure a YubiKey 5 would also work. I'm also running macOS 10.13.6.
- I installed GPGTools as recommended. However, as I'll note later, it seems that
gpg-agent
only automatically starts when gpg is used; for ssh, you'll need to ensure it's running. - Before generating your keys, decide what key size you want to use. If you run the
list
command insidegpg --edit-card
, look for theKey attributes
line to see what is currently selected. On my YubiKey 4, it defaulted to 2048 bits for all keys:
Key attributes ...: rsa2048 rsa2048 rsa2048