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

includ task file #8841

Merged
merged 1 commit into from
Nov 19, 2024
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
8 changes: 6 additions & 2 deletions ansible/roles/ansible_bu_setup_workshop/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,13 @@ ansible_bu_setup_workshop_aap_packages:
- ansible-core
- ansible-navigator

# Ansible BU exercise base directory
# Ansible BU exercise content repo
ansible_bu_setup_workshop_content_git_repo: https://github.com/ansible/workshops.git
ansible_bu_setup_workshop_content_git_version: devel

# Ansible BU exercise base directory
ansible_bu_setup_workshop_exercise_src: ansible_rhel
# Destination directory where exercise will be copied
# Destination directory where exercise will be copied
# /home/{{ student_name }}/[Destination directory]
ansible_bu_setup_workshop_exercise_dest: rhel-workshop

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
- name: Clone rhel-workshop
ansible.builtin.git:
repo: "{{ ansible_bu_setup_workshop_content_git_repo }}"
dest: /tmp/workshops
version: "{{ ansible_bu_setup_workshop_content_git_version }}"

- name: Copy rhel-workshop to users home
ansible.builtin.copy:
src: "/tmp/workshops/exercises/{{ ansible_bu_setup_workshop_exercise_src }}/"
dest: "/home/{{ student_name }}/{{ ansible_bu_setup_workshop_exercise_dest }}/"
remote_src: true
owner: "{{ student_name }}"
group: "{{ student_name }}"
mode: '0755'

- name: Clean workshop clone directory
ansible.builtin.file:
path: "/tmp/workshops"
state: absent
23 changes: 4 additions & 19 deletions ansible/roles/ansible_bu_setup_workshop/tasks/rhel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,23 +19,8 @@
dest: "/home/{{ student_name }}/setup.yml"
owner: "{{ student_name }}"
group: "{{ student_name }}"

- name: Clone rhel-workshop
ansible.builtin.git:
repo: https://github.com/ansible/workshops.git
dest: /tmp/workshops
version: devel

- name: Copy rhel-workshop to users home
ansible.builtin.copy:
src: "/tmp/workshops/exercises/{{ ansible_bu_setup_workshop_exercise_src }}/"
dest: "/home/{{ student_name }}/rhel-workshop/{{ ansible_bu_setup_workshop_exercise_dest }}/"
remote_src: true
owner: "{{ student_name }}"
group: "{{ student_name }}"
mode: '0755'

- name: Clean workshop clone directory
ansible.builtin.file:
path: "/tmp/workshops"
state: absent
- name: Clone workshop content
ansible.builtin.include_tasks:
file: ./common/clone-workshop-content.yml

Loading