Playbook to manage state of package
This commit is contained in:
15
playbooks/modify-package-state.yml
Normal file
15
playbooks/modify-package-state.yml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
- hosts: all
|
||||||
|
become: true
|
||||||
|
vars_prompt:
|
||||||
|
- name: package_name
|
||||||
|
prompt: "Enter the name of package to be installed"
|
||||||
|
private: no
|
||||||
|
- name: state
|
||||||
|
prompt: "State"
|
||||||
|
private: no
|
||||||
|
tasks:
|
||||||
|
- name: Modify state of package
|
||||||
|
ansible.builtin.package:
|
||||||
|
name: "{{ package_name }}"
|
||||||
|
state: "{{ state }}"
|
||||||
Reference in New Issue
Block a user