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/mkdocs #428

Merged
merged 3 commits into from
Jul 5, 2021
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
5 changes: 5 additions & 0 deletions roles/online_docs/defaults/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
external_hrefs:
spacewalk: 'https://spacewalkproject.github.io/'
pulp: 'https://pulpproject.org/'
...
21 changes: 21 additions & 0 deletions roles/online_docs/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,27 @@
check_mode: false
register: 'lmod_version'

- name: "Find all ip_addresses.yml files in {{ playbook_dir }}/group_vars/*."
find:
paths: "{{ playbook_dir }}/group_vars/"
recurse: true
patterns: 'ip_addresses.yml'
register: ip_addresses_files
delegate_to: localhost

- name: 'Include variables from all ip_addresses.yml files.'
include_vars:
file: "{{ item }}"
name: "networking_lookup"
with_items: "{{ ip_addresses_files.files | map (attribute='path') | list }}"
register: networking_lookups
delegate_to: localhost

- name: 'Combine network info from ip_addresses.yml files into one dict.'
set_fact:
networking_lookups: "{{ networking_lookups.results | json_query('[].ansible_facts.networking_lookup.ip_addresses') | combine() }}"
delegate_to: localhost

- name: 'Set selinux in permissive mode.'
selinux:
policy: 'targeted'
Expand Down
2 changes: 1 addition & 1 deletion roles/online_docs/templates/mkdocs/docs/cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The jobs are submitted to a workload manager, which distributes them efficiently

The key features of the {{ slurm_cluster_name | capitalize }} cluster include:

* Linux OS: [CentOS](https://www.centos.org/) 7.x with [Spacewalk](https://spacewalkproject.github.io/) for package distribution/management.
* Linux OS: [CentOS](https://www.centos.org/) 7.x with [{{ repo_manager | capitalize }}]({{ external_hrefs[repo_manager] }}) for package distribution/management.
* Completely virtualised on an [OpenStack](https://www.openstack.org/) cloud
* Deployment of HPC cluster with [Ansible playbooks](https://docs.ansible.com/ansible/latest/index.html) under version control in a Git repo: [league-of-robots](https://github.com/rug-cit-hpc/league-of-robots)
* Job scheduling: [Slurm Workload Manager](https://slurm.schedmd.com/)
Expand Down
2 changes: 1 addition & 1 deletion roles/online_docs/templates/mkdocs/docs/specifications.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

Key ingredients of the High Performance Computing (HPC) environment of the {{ slurm_cluster_name | capitalize }} cluster

* Linux OS: [CentOS](https://www.centos.org/) {{ hostvars[groups['user_interface'][0]]['ansible_distribution_version'] }} with [Spacewalk](https://spacewalkproject.github.io/) for package distribution/management.
* Linux OS: [CentOS](https://www.centos.org/) {{ hostvars[groups['user_interface'][0]]['ansible_distribution_version'] }} with [{{ repo_manager | capitalize }}]({{ external_hrefs[repo_manager] }}) for package distribution/management.
* Job scheduling: [Slurm Workload Manager](https://slurm.schedmd.com/) {{ slurm_version.stdout }}
* Module system: [Lmod](https://github.com/TACC/Lmod) {{ lmod_version.stdout }}
* Deployment of (Bioinformatics) software: [EasyBuild](https://github.com/easybuilders/easybuild)
Expand Down
2 changes: 2 additions & 0 deletions roles/online_docs/templates/mkdocs/mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
site_name: "{{ slurm_cluster_name | capitalize }} HPC cluster"
site_url: "http://{{ networking_lookups[groups['docs'] | first | regex_replace('^' + ai_jumphost + '\\+','')].fqdn }}/{{ slurm_cluster_name }}/"
use_directory_urls: true
theme:
name: readthedocs
highlightjs: false
Expand Down