Skip to content

silefort/ansiblemymac

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ansiblemymac

Use Ansible to setup your newly installed mac

Preset:

Create a ssh private/public key

$ ssh-keygen -t rsa -b 4096 -C "my@email.com"
$ eval "$(ssh-agent -s)"

Edit your ssh config file

$ vim ~/.ssh/config

Host *
  AddKeysToAgent yes
  UseKeychain yes
  IdentityFile ~/.ssh/id_rsa

Add your SSH private key to the ssh-agent and store your passphrase in the keychain

$ ssh-add -K ~/.ssh/id_rsa

Add ssh public key to your github account

$ cat ~/.ssh/id_rsa.pub | pbcopy

and Follow: https://docs.github.com/en/github/authenticating-to-github/adding-a-new-ssh-key-to-your-github-account

Preset:

Install Homebrew:

$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"	

Install Ansible using homebrew:

$ brew install ansible

Run Ansible:

Clone this repo:

$ mkdir ~/Git
$ git clone git@github.com:silefort/ansiblemymac.git ~/Git/ansiblemymac
$ cd ~/Git/ansiblemac

Install Ansible requirements:

$ ansible-galaxy install geerlingguy.homebrew

Run your playbook:

$ ansible-playbook main.yml -i inventory.ini -K 

Remaining Manual Setup:

  • Remap Caps Lock to Ctrl ( Clavier / Touches de Modification )
  • Put the Dock on the left ( Dock )
  • Make the Dock disappear automatically ( Dock )
  • Change the color preset of iTerm ( Preferences / Profiles / Colors )
  • Change the font of iTerm ( Menlo / Bold )
  • Change Mouse Setup ( Sens du défilement naturel )

Ideas stolen from:

TODO:

  • Automatic dotfiles (bash, vimrc, tmux...)
  • different roles depending on pro or personnal computer
  • CI
  • Map Caps Lock to Ctrl from the command line ( no manual action )

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published