diff mbox series

[RESEND,08/12] ansible: Install libvirt deps and enable user

Message ID 20250113-jag-bringup_fixes-v1-8-fb28030b1f26@kernel.org (mailing list archive)
State New
Headers show
Series kdevops: Various fixes | expand

Commit Message

Joel Granados Jan. 13, 2025, 11:53 a.m. UTC
There is a need to setup libvirt when running `make bringup` in a system
that does not have libvirt installed. Call the dpendency install and
user enablement roles from the bringup task.

Signed-off-by: Joel Granados <joel.granados@kernel.org>
---
 playbooks/roles/bringup_guestfs/tasks/main.yml | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Comments

Daniel Gomez Jan. 30, 2025, 9:21 a.m. UTC | #1
On Mon, Jan 13, 2025 at 12:53:06PM +0100, Joel Granados wrote:
> There is a need to setup libvirt when running `make bringup` in a system
> that does not have libvirt installed. Call the dpendency install and
> user enablement roles from the bringup task.

Libvirt setup requires it's own step as the user needs to log out and
log in again to apply the user changes.

> 
> Signed-off-by: Joel Granados <joel.granados@kernel.org>
> ---
>  playbooks/roles/bringup_guestfs/tasks/main.yml | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> diff --git a/playbooks/roles/bringup_guestfs/tasks/main.yml b/playbooks/roles/bringup_guestfs/tasks/main.yml
> index 95631aa..c764ae4 100644
> --- a/playbooks/roles/bringup_guestfs/tasks/main.yml
> +++ b/playbooks/roles/bringup_guestfs/tasks/main.yml
> @@ -38,6 +38,18 @@
>    when: guestfs_subdirectories.matched == 0
>    tags: [ 'config-check' ]
>  
> +- name: Use install-dep tasks from libvirt_user role to install libvirt deps
> +  include_role:
> +    name: libvirt_user
> +    tasks_from: install-deps/main.yml
> +  tags: [ 'network' ]
> +
> +- name: Use enable-user tasks from libvirt_user role to enable user
> +  include_role:
> +    name: libvirt_user
> +    tasks_from: enable-user/main.yml
> +  tags: [ 'network' ]
> +
>  - name: Check for dnsmasq configuration files
>    stat:
>      path: "{{ item }}"
> 
> -- 
> 2.44.2
> 
>
diff mbox series

Patch

diff --git a/playbooks/roles/bringup_guestfs/tasks/main.yml b/playbooks/roles/bringup_guestfs/tasks/main.yml
index 95631aa..c764ae4 100644
--- a/playbooks/roles/bringup_guestfs/tasks/main.yml
+++ b/playbooks/roles/bringup_guestfs/tasks/main.yml
@@ -38,6 +38,18 @@ 
   when: guestfs_subdirectories.matched == 0
   tags: [ 'config-check' ]
 
+- name: Use install-dep tasks from libvirt_user role to install libvirt deps
+  include_role:
+    name: libvirt_user
+    tasks_from: install-deps/main.yml
+  tags: [ 'network' ]
+
+- name: Use enable-user tasks from libvirt_user role to enable user
+  include_role:
+    name: libvirt_user
+    tasks_from: enable-user/main.yml
+  tags: [ 'network' ]
+
 - name: Check for dnsmasq configuration files
   stat:
     path: "{{ item }}"