Skip to content

Commit

Permalink
add http proxy support
Browse files Browse the repository at this point in the history
  • Loading branch information
andreygubarev committed Jun 2, 2023
1 parent 79ba64b commit 69d324e
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
---
- name: Converge
hosts: all

environment:
http_proxy: "{{ lookup('ansible.builtin.env', 'http_proxy') | default(omit) }}"
https_proxy: "{{ lookup('ansible.builtin.env', 'https_proxy') | default(omit) }}"

tasks:
- name: "Include {{ cookiecutter.role_name }}"
ansible.builtin.include_role:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,9 @@
- name: Prepare
hosts: all
become: true

environment:
http_proxy: "{{ lookup('ansible.builtin.env', 'http_proxy') | default(omit) }}"
https_proxy: "{{ lookup('ansible.builtin.env', 'https_proxy') | default(omit) }}"

tasks: []
4 changes: 4 additions & 0 deletions molecule_qemu/playbooks/create.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@
qemu_vm_disk: "4G"
qemu_vm_network: "user"

environment:
http_proxy: "{{ lookup('ansible.builtin.env', 'http_proxy') | default(omit) }}"
https_proxy: "{{ lookup('ansible.builtin.env', 'https_proxy') | default(omit) }}"

tasks:
### configuration #########################################################

Expand Down
4 changes: 4 additions & 0 deletions molecule_qemu/playbooks/destroy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
gather_facts: false
no_log: "{{ molecule_no_log }}"

environment:
http_proxy: "{{ lookup('ansible.builtin.env', 'http_proxy') | default(omit) }}"
https_proxy: "{{ lookup('ansible.builtin.env', 'https_proxy') | default(omit) }}"

tasks:
- name: Prepare VMs config
block:
Expand Down

0 comments on commit 69d324e

Please sign in to comment.