Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the git clone issue and add a new shortcut #8975

Merged
merged 1 commit into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions ansible/roles/rad_setup_instructlab/files/antora.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: modules
title: Red Hat AI Development Roadshow - Developer Track
version: main
nav:
- modules/ROOT/nav.adoc

asciidoc:
attributes:
lab_name: Red Hat AI Development Roadshow - Developer Track
user: user1
password: openshift
openshift_cluster_ingress_domain: app.example.sandbox.com
novnc_url: http://localhost:8443
release-version: main
page-pagination: true
page-toclevels: 1
experimental: ""
env-desktop: true
9 changes: 9 additions & 0 deletions ansible/roles/rad_setup_instructlab/files/firefox-rad.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[Desktop Entry]
Version=1.0
Name=RAD AI Labs
Comment=Opens Firefox with a specific URL
Exec=firefox localhost:8443
Icon=/usr/share/icons/hicolor/48x48/apps/firefox.png
Terminal=false
Type=Application
Categories=Network;WebBrowser;
30 changes: 23 additions & 7 deletions ansible/roles/rad_setup_instructlab/tasks/50-dev-tools-setup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -108,24 +108,40 @@
dest: "/home/{{ setup_instructlab_user }}/.config/Code/User/settings.json"
mode: u=rw,g=rw,o=

- name: Create a new directory [dev-guides]
file:
path: "/home/{{ setup_instructlab_user }}/dev-guides"
state: directory
mode: 0755

- name: Clone dev-guides repository
git:
repo: https://github.com/rh-rad-ai-roadshow/dev-guides.git
dest: "/home/{{ setup_instructlab_user }}/"
dest: "/home/{{ setup_instructlab_user }}/dev-guides"

- name: Change owner of the dev-guides directory
file:
path: "/home/{{ setup_instructlab_user }}/dev-guides"
recurse: true
mode: 0755


- name: Update the naviagation config
ansible.builtin.copy:
src: antora.yml
dest: "/home/{{ setup_instructlab_user }}/dev-guides/content/antora.yml"
mode: u=rw,g=rw,o=

- name: Build and start the lab instructions for Desktop labs
shell: "sh /home/{{ setup_instructlab_user }}/dev-guides/utilities/lab-desktop-start"

- name: Set the env-desktop environment variable to true for Desktop labs
agnosticd_user_info:
data:
env-desktop: true

- name: Add a firefox shortcut for the lab instructions
ansible.builtin.copy:
src: firefox-rad.desktop
dest: "/home/{{ setup_instructlab_user }}/.local/share/applications/firefox-rad.desktop"
mode: u=rw,g=rw,o=

- name: Update the desktop database to make the new shortcut visible
shell: "sudo gtk-update-icon-cache -f -t /usr/share/icons/hicolor"

become: true
become_user: "{{ setup_instructlab_user }}"
Loading