Skip to content

Commit

Permalink
zero-touch-base-rhel add tasks file to setup instructlab (#9032)
Browse files Browse the repository at this point in the history
  • Loading branch information
wilson-walrus authored Feb 10, 2025
1 parent f4f50cf commit 2289678
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
15 changes: 15 additions & 0 deletions ansible/configs/zero-touch-base-rhel/instructlab_setup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
- name: Install instructlab into the specified (virtualenv)
ansible.builtin.pip:
name: git+https://github.com/instructlab/[email protected]
virtualenv: /instructlab/venv/bin/activate
virtualenv_site_packages: yes
executable: pip3.3

- name: Execute ilab command for initial configuration
ansible.builtin.command: /instructlab/venv/bin/ilab config init

- name: Execute ilab command to download Granite
ansible.builtin.command: /instructlab/venv/bin/ilab model download --repository instructlab/granite-7b-lab-GGUF --filename=granite-7b-lab-Q4_K_M.gguf

- name: Execute ilab command to download Merlinite
ansible.builtin.command: /instructlab/venv/bin/ilab model download --repository instructlab/merlinite-7b-lab-GGUF --filename=merlinite-7b-lab-Q4_K_M.gguf
8 changes: 8 additions & 0 deletions ansible/configs/zero-touch-base-rhel/post_software.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,14 @@
_workload_title_: "Post Software"
_workloads_: "{{ post_software_workloads | default([]) }}"

- name: Execute task file based on a boolean condition
hosts: bastions
become: true
tasks:
- name: Setup Instructlab
when: instructlab_zt_setup | default(false) | bool
include_tasks: instructlab_setup.yml

- name: Deploy user setup
hosts: localhost
gather_facts: false
Expand Down

0 comments on commit 2289678

Please sign in to comment.