Skip to content

Commit

Permalink
Refactored some post tasks to roles (#860)
Browse files Browse the repository at this point in the history
More idiomatic.
  • Loading branch information
freemanjp authored Nov 19, 2022
1 parent 6f3e722 commit 5c151f4
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 25 deletions.
42 changes: 17 additions & 25 deletions provisioning/playbook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,11 @@
pyenv_users:
- vagrant

# Install Pipenv
- role: pipenv
tags:
- python

# Install Java JDK 8
- role: gantsign.java
tags:
Expand Down Expand Up @@ -284,6 +289,12 @@
- git-credential-manager
- gui

# Install Google Chrome web browser
- role: google-chrome
tags:
- chrome
- gui

# Set the default web browser
# This is only a partial solution as Google Chrome will still ask if you
# want to make it the default browser when it first runs.
Expand All @@ -293,6 +304,12 @@
- chrome
default_web_browser: google-chrome

# Install Postman HTTP tool
- role: postman
tags:
- gui
- postman

# Install Visual Studio Code editor
- role: gantsign.visual-studio-code
tags:
Expand Down Expand Up @@ -683,31 +700,6 @@
maven: '3.8'

post_tasks:
# Install Pipenv
- name: install Pipenv
package:
name: pipenv
tags:
- python

# Install Google Chrome web browser
- name: install Google Chrome
package:
name: google-chrome-stable
tags:
- gui
- chrome

# Install Postman HTTP tool
- name: install Postman
snap:
name:
- postman
state: present
tags:
- gui
- postman

# Cleanup
- name: remove dependencies that are no longer required
apt:
Expand Down
3 changes: 3 additions & 0 deletions provisioning/roles/google-chrome/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- name: install Google Chrome
package:
name: google-chrome-stable
3 changes: 3 additions & 0 deletions provisioning/roles/pipenv/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
- name: install Pipenv
package:
name: pipenv
4 changes: 4 additions & 0 deletions provisioning/roles/postman/tasks/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
- name: install Postman
snap:
name: postman
state: present

0 comments on commit 5c151f4

Please sign in to comment.