Skip to content

Commit

Permalink
feat: add Terragrunt
Browse files Browse the repository at this point in the history
  • Loading branch information
diegotony committed Mar 25, 2022
1 parent 308d1d9 commit 0313c6b
Show file tree
Hide file tree
Showing 12 changed files with 49 additions and 0 deletions.
1 change: 1 addition & 0 deletions playbook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
roles:
- common
- hashicorp
# - homebrew
# - docker
- python

5 changes: 5 additions & 0 deletions roles/hashicorp/tasks/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
- name: Install terragrunt
get_url:
url: https://github.com/gruntwork-io/terragrunt/releases/download/v0.36.6/terragrunt_linux_amd64
dest: /usr/local/bin/terragrunt
mode: 755
Empty file.
1 change: 1 addition & 0 deletions roles/homebrew/handlers/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- include: services.yml
Empty file.
Empty file added roles/homebrew/meta/main.yml
Empty file.
17 changes: 17 additions & 0 deletions roles/homebrew/tasks/dependencies.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
- name: Install common packages
apt:
update_cache: yes
name: "{{item}}"
state: present
become_user: root
with_items:
- curl
- wget
- ruby
- build-essential
- procps
- file
- git

register: dependencies

22 changes: 22 additions & 0 deletions roles/homebrew/tasks/install.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
- name: Git Brew
become_user: diegotony
become: no
ansible.builtin.git:
repo: https://github.com/Homebrew/brew
dest: /home/diegotony/homebrew

- name: "Add Brew in PATH"
become_user: diegotony
become: no
lineinfile:
path: /home/diegotony/.zshrc
line: "export PATH=/home/diegotony/homebrew/bin:$PATH"
state: present


- name: Add Homebrew to Path
become: no
ansible.builtin.shell: |
source /home/diegotony/.zshrc
args:
executable: /bin/bash
3 changes: 3 additions & 0 deletions roles/homebrew/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- include: dependencies.yml
- include: install.yml
- include: packages.yml
Empty file.
Empty file.
Empty file added roles/homebrew/vars/main.yml
Empty file.

0 comments on commit 0313c6b

Please sign in to comment.