My Go-To Script for New Cloud Instance Setup
As an ML engineer, I often spin up new VM instances (especially Vertex AI Workbench instances) for running experiments. But all the utilities, aliases, and keyboard shortcuts that I’m used to on my local machine are missing. Spending time setting up the environment from scratch again and again is annoying.
I always use this bash script (GitHub
Gist) I created, which transforms a vanilla VM into my personalized
workbench in seconds. It installs essential command-line utilities like
tmux, fzf, htop, and
uv, and configures my shell (.bashrc), Vim
(.vimrc), and tmux (.tmux.conf) just the way I
like them.
This script handles:
- Setting locale to avoid warnings
- Configuring
.bashrcwith my most-used aliases - Installing core utilities like git, vim, tmux, thefuck, and htop, and applying basic Vim configurations
- Setting up Tmux with mouse support and intuitive keybindings (especially for splitting windows into panes)
- Installing and configuring fuzzy finder (fzf) for easy history
search. This is an amazing replacement for
Ctrl+Rin bash. Especially helpful since I don’t want to configure zsh or fish to get autosuggestion features for new VM instances.
Whenever I create a new instance, I just run this single script and immediately feel at home. No more manually installing the same tools or tweaking config files every single time!
Hope this little idea helps streamline your workflow too!