forked from guillaume.emorine/siotp
Grande réorganisation et renommage au niveau du Gitea, d'autres
modifications à venir.
This commit is contained in:
32
bts_annee_2/sisr2/playbooks_ansible/squid.yml
Normal file
32
bts_annee_2/sisr2/playbooks_ansible/squid.yml
Normal file
@@ -0,0 +1,32 @@
|
||||
# squid.yml
|
||||
---
|
||||
- hosts: adm
|
||||
vars:
|
||||
- proxy_port: 8080
|
||||
- proxy_mem: 128
|
||||
- proxy_localnet: "192.168.0.0/24"
|
||||
|
||||
tasks:
|
||||
- name: 1. Installe le proxy Squid sur la machine Infra.
|
||||
apt:
|
||||
name: squid
|
||||
state: present
|
||||
|
||||
# Uncomment this on FIRST RUN, comment afterwards !
|
||||
# - name: 2. Récupère le fichier squid.conf.
|
||||
# ansible.builtin.fetch:
|
||||
# src: /etc/squid/squid.conf
|
||||
# dest: squid.conf.j2
|
||||
# flat: yes
|
||||
|
||||
- name: 3. Envoie squid.conf
|
||||
template:
|
||||
src: squid.conf.j2
|
||||
dest: /etc/squid/squid.conf
|
||||
notify: Restart squid
|
||||
|
||||
handlers:
|
||||
- name: Restart squid
|
||||
service:
|
||||
name: squid
|
||||
state: restarted
|
Reference in New Issue
Block a user