Setup:
Samsung Galaxy Tab S5e SM-T720
Android Pie on Linux 4.9.112 (not rooted)
Termux
ssh_authorized_keys: | |
- github:tuksik | |
hostname: k3osm | |
k3os: | |
dns_nameservers: | |
- 8.8.8.8 | |
- 1.1.1.1 | |
ntp_servers: | |
- 0.us.pool.ntp.org | |
- 1.us.pool.ntp.org |
sudo adduser --disabled-password --gecos \"\" vagrant | |
echo vagrant:vagrant | sudo chpasswd | |
sudo mkdir -p /home/vagrant/.ssh | |
sudo chmod 0700 /home/vagrant/.ssh | |
sudo wget --no-check-certificate https://raw.github.com/mitchellh/vagrant/master/keys/vagrant.pub -O /home/vagrant/.ssh/authorized_keys | |
sudo chmod 0600 /home/vagrant/.ssh/authorized_keys | |
sudo chown -R vagrant /home/vagrant/.ssh | |
sudo echo 'vagrant ALL=(ALL:ALL) ALL' >> /etc/sudoers | |
sudo mkdir -p /home/rancher/.ssh | |
sudo chmod 0700 /home/rancher/.ssh |
I've been using a lot of Ansible lately and while almost everything has been great, finding a clean way to implement ansible-vault wasn't immediately apparent.
What I decided on was the following: put your secret information into a vars
file, reference that vars
file from your task
, and encrypt the whole vars
file using ansible-vault encrypt
.
Let's use an example: You're writing an Ansible role and want to encrypt the spoiler for the movie Aliens.
This is a little trick I use to spin up the packages instalation on Debian/Ubuntu boxes in Vagrant.
I add a simple function that checks if a directory named something similar to ~/.vagrant.d/cache/apt/opscode-ubuntu-12.04/partial
(it may have another path in Windows or MacOS) and create the directory if it doesn't already exist.
def local_cache(basebox_name)
cache_dir = Vagrant::Environment.new.home_path.join('cache', 'apt', basebox_name)
partial_dir = cache_dir.join('partial')
partial_dir.mkdir unless partial_dir.exist?
cache_dir
cd k8s-specs | |
git pull | |
export AWS_ACCESS_KEY_ID=[...] | |
export AWS_SECRET_ACCESS_KEY=[...] | |
aws --version |
#!/usr/bin/env bash | |
# To run: | |
# $ brew uninstall s3cmd && brew install s3cmd --HEAD | |
# $ s3cmd --configure # fill in w/ amazon account vars | |
# $ cd path/to/local/static/site | |
# $ wget https://gist.githubusercontent.com/tomfuertes/9175005/raw/make-website.sh | |
# $ bash make-website.sh | |
# | |
# NOTE: cfcreate takes ~15 minutes to run on AWS. |
# Bootstrap script for use with http://boxstarter.org/ | |
# To use append the URL to the raw snippet to http://boxstarter.org/package/nr/url? | |
# (e.g. http://boxstarter.org/package/nr/url?https://gist.githubusercontent.com/mikemoate/0915288fff447b640cdb/raw/83b32099ea8f21d06604ae70003312b7492b8cd8/boxstarter-script-work) | |
# NOTE: You may see errors from some packages if you have already installed the software before using boxstarter. | |
# (some MSI's handle this badly and so exit with the wrong code, I've seen this for HipChat, RoyalTS, Virtualbox and Vagrant) | |
# Windows settings | |
Set-WindowsExplorerOptions -EnableShowHiddenFilesFoldersDrives -EnableShowProtectedOSFiles -EnableShowFileExtensions -EnableShowFullPathInTitleBar | |
Set-TaskbarOptions -Size Small -Lock -Dock Bottom |