2021-11-06 14:17:50 +01:00
|
|
|
# SPDX-FileCopyrightText: 2021 Free Software Foundation Europe <https://fsfe.org>
|
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: AGPL-3.0-or-later
|
|
|
|
|
|
|
|
---
|
2022-03-04 15:25:45 +01:00
|
|
|
- hosts: innernet_server, innernet_client
|
2022-03-03 10:58:48 +01:00
|
|
|
remote_user: root
|
|
|
|
tasks:
|
2022-03-03 17:40:44 +01:00
|
|
|
- pause:
|
|
|
|
prompt: "You are using a function to UNINSTALL innernet on the chosen hosts {{ play_hosts }}. Continue? (yes/no)?"
|
|
|
|
tags: [never, uninstall]
|
|
|
|
register: uninstall_confirm
|
|
|
|
delegate_to: localhost
|
|
|
|
run_once: yes
|
|
|
|
|
|
|
|
- fail:
|
|
|
|
msg: Aborted uninstallation of innernet.
|
|
|
|
tags: [never, uninstall]
|
|
|
|
when: not uninstall_confirm.user_input | bool
|
|
|
|
delegate_to: localhost
|
|
|
|
run_once: yes
|
|
|
|
|
2022-03-03 10:58:48 +01:00
|
|
|
- name: Get innernet-server hostname from inventory groups
|
|
|
|
set_fact:
|
|
|
|
# Assuming that we only have one innernet server, we take the first
|
|
|
|
# occurence
|
|
|
|
innernet_server: "{{ groups['innernet_server'][0] }}"
|
|
|
|
run_once: true
|
|
|
|
|
2021-12-02 17:43:06 +01:00
|
|
|
- hosts: innernet_server
|
2021-11-06 14:17:50 +01:00
|
|
|
remote_user: root
|
2021-11-15 18:44:10 +01:00
|
|
|
roles:
|
|
|
|
- server
|
2021-11-06 14:17:50 +01:00
|
|
|
|
2021-12-02 17:43:06 +01:00
|
|
|
- hosts: innernet_client
|
2021-11-15 18:44:10 +01:00
|
|
|
remote_user: root
|
2021-11-06 14:17:50 +01:00
|
|
|
roles:
|
2021-11-15 18:44:10 +01:00
|
|
|
- client
|