Install Xcode:
xcode-select --install
-
Boot up the machine with the USB key in place and manually install a recent Ubuntu Desktop LTS release.
-
For the main machine, hit F12 on startup and select USB Storage Device.
-
After the installation process completes, disable power saving & screen lock (so that the bootstrap process proceeds without complications). Power Button (top right) -> Settings -> Power > Blank Screen -> Never.
-
After the installation process completes, install a few bootstrap utilities to get going:
sudo apt-get install -y curl ca-certificates
Initialize the software installation process with homebrew and a few other basics:
bash -xec "$(curl -L https://raw.githubusercontent.com/marvinpinto/kitchensink/main/bootstrap.sh)"
When bootstrapping the machine, clone the kitchensink repo locally and run the manifest from within there:
git clone https://github.com/marvinpinto/kitchensink.git /tmp/kitchensink
cd /tmp/kitchensink
Setup the homebrew path initially:
# linux
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
# osx
eval "$(/usr/local/bin/brew shellenv)"
Run ansible to install & manage all the sytem components:
ANSIBLE_VERBOSITY=2 make machine
Bootstrap the 1password CLI (for secrets), export the specified env vars after it completes:
make op-init
Validate that the 1password cli create the config file correctly, sometimes this does not work on the first try for whatever reason:
[[ -e "${HOME}/.openv-cfg-dir/config" ]] && true || echo "1password CLI did NOT initialize successfully, re-run: make op-init"
export OP_CONFIG_DIR=/tmp/openv-XXXXXXXXXX
export OP_SESSION_my=XXXXXXXXXXX
Initialize the dotfiles using chezmoi:
make chezmoi-init
-
osx/linux: reboot the machine and log back in
-
osx: If a homebrew cask/cli app throws a "cannot be verified" error, ctrl+click the app icon in Finder/Applications, and then choose "Open". This effectively saves the exception in security settings and it should not throw this error again.
-
osx: Manual keyboard preference changes (System Preferences -> Keyboard):
- Keyboard: Adjust keyboard brightness in low light (enable)
- Keyboard: Turn keyboard backlight off after 5 secs of inactivity (enable)
- Modifier Keys: Change Caps lock to Ctrl
- Shortcuts -> Accessibility: Map Cmd+Q to "Invert Colors"
-
osx: Install divvy and tailscale from the App Store and ensure they both run on startup.
-
linux: Apply any updated software patches using the
yoloupdate
alias. -
osx/linux: Add the core AWS vault credentials:
export OP_AWS_MFA_NAME=AWS-useraccount-marvin-dev ave-init marvin
-
osx/linux: Reboot the machine at least once to verify everything worked correctly.
The HomebrewFormula directory contains a bunch of linux CLI & AppImage maps for use as Homebrew installations.
Add the kitchensink
tap as follows:
brew tap marvinpinto/kitchensink "https://github.com/marvinpinto/kitchensink.git"
Then install a formula as follows - using digikam as an example:
brew install marvinpinto/kitchensink/digikam
Combining remote containers with automatically setup dotfiles enables very powerful throwaway dev environments.
See the example devcontainer.json and my vscode settings.json file for inspiration.