Skip to content

Commit

Permalink
Merge pull request #6 from MonolithProjects/develop
Browse files Browse the repository at this point in the history
Fix idempotence
  • Loading branch information
MonolithProjects authored Nov 11, 2020
2 parents 62d48da + 4efd731 commit 969bdb6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions molecule/default/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,5 +132,6 @@ scenario:
- create
- prepare
- converge
- idempotence
- cleanup
- destroy
6 changes: 6 additions & 0 deletions tasks/apt.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
---
- name: Check if apt config file exists
stat:
path: /etc/apt/apt.conf.d/proxy.conf
register: stat_result

- name: Create apt config file
file:
path: /etc/apt/apt.conf.d/proxy.conf
state: touch
mode: 0600
when:
- ansible_pkg_mgr == "apt"
- not stat_result.stat.exists

- name: Ensure HTTP Proxy server is in apt.conf
lineinfile:
Expand Down

0 comments on commit 969bdb6

Please sign in to comment.