Skip to content

Instantly share code, notes, and snippets.

@libero18
Created January 17, 2015 05:02
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save libero18/1cdb0c6d864f50c3efe9 to your computer and use it in GitHub Desktop.
Save libero18/1cdb0c6d864f50c3efe9 to your computer and use it in GitHub Desktop.
ansible-playbook setup.yml
---
- hosts: 127.0.0.1
connection: local
tasks:
- name: Make sure using latest Homebrew
shell: "brew update"
- name: Update already-installed formula
shell: "brew upgrade"
- name: Add Repository
shell: "brew tap {{item}}"
ignore_errors: True
with_items:
- "caskroom/cask"
- "caskroom/versions"
- "homebrew/binary"
- "homebrew/completions"
- "homebrew/versions"
- "sanemat/font"
- "suin/suin"
- "libero18/mycask"
- name: Install Packages (for brew-cask)
shell: "brew install {{item}}"
ignore_errors: True
with_items:
- "caskroom/cask/brew-cask"
- name: Install OSXFUSE (.dmg from brew-cask)
shell: "brew cask install {{item}}"
ignore_errors: True
with_items:
- "osxfuse"
- name: Install XQuartz (.dmg from brew-cask)
shell: "brew cask install {{item}}"
ignore_errors: True
with_items:
- "xquartz"
- name: Install Packages (for development)
shell: "brew install {{item}}"
ignore_errors: True
with_items:
- "zsh"
- "git"
- "transcrypt"
- "tig"
- "vim"
- "fontforge --use-gcc --without-python"
- "ricty"
- "wget"
- "jq"
- "go"
- "sshfs"
- "freetype"
- name: Set Ricty font
shell: "find /usr/local/Cellar/ricty/ -name 'Ricty*.ttf' |xargs -J % cp -f % ~/Library/Fonts/ && fc-cache -vf"
- name: Install Packages (for provisioning)
shell: "brew install {{item}}"
ignore_errors: True
with_items:
- "ansible"
- "packer"
- "docker"
- "boot2docker"
- name: Install Packages (for completion)
shell: "brew install {{item}}"
ignore_errors: True
with_items:
- "vagrant-completion"
- name: Install Packages (for document)
shell: "brew install {{item}}"
ignore_errors: True
with_items:
- "kobito-cli"
- name: Install Packages (.dmg from brew-cask)
shell: "brew cask install {{item}}"
ignore_errors: True
with_items:
- "google-chrome"
- "virtualbox"
- "vagrant"
- "iterm2"
- "dash"
- "cheatsheet"
- "karabiner"
- "accessmenubarapps"
- "mutecon"
- "alfred"
- name: add search target => alfred
ignore_errors: True
shell: "brew cask alfred link"
- name: Remove outdated versions
shell: "brew cleanup && brew cask cleanup"
- name: check boot2docker status
shell: "boot2docker status || boot2docker init"
register: result
- name: stop boot2docker
shell: "boot2docker stop"
when: result.stdout == "running"
- name: Update boot2docker
shell: "boot2docker download"
- name: restart boot2docker
shell: "boot2docker start"
when: result.stdout == "running"
- name: Install Vagrant Plugins
shell: "vagrant plugin install {{item}}"
ignore_errors: True
with_items:
- "vagrant-digitalocean"
- "dotenv"
- name: Install Vagrant Boxes
shell: "vagrant box add --force {{item.key}} '{{item.value}}'"
with_dict:
digital_ocean: https://github.com/smdahlen/vagrant-digitalocean/raw/master/box/digital_ocean.box
- name: Create GOPATH Directory
shell: "mkdir -p $HOME/.go"
- name: Install Go Packages (go get from github.com)
shell: "go get -u github.com/{{item}}"
with_items:
- "peco/peco/cmd/peco"
- "motemen/ghq"
- "typester/gh-open"
- name: Install blockdiag
shell: "pyenv exec pip install blockdiag actdiag seqdiag nwdiag"
ignore_errors: True
- name: pyenv rehash
shell: "pyenv rehash"
ignore_errors: True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment