Skip to content

Commit

Permalink
Merge pull request #284 from dellhpc/rc-1.0
Browse files Browse the repository at this point in the history
Omnia v1.0.0
  • Loading branch information
j0hnL committed Mar 18, 2021
2 parents 986eccb + 74e5284 commit a7275b9
Show file tree
Hide file tree
Showing 224 changed files with 14,547 additions and 1,219 deletions.
66 changes: 66 additions & 0 deletions .github/workflows/ansible-lint.yml
@@ -0,0 +1,66 @@
name: Ansible Lint # feel free to pick your own name

on:
pull_request:
branches:
- release
- devel

jobs:
ansible-lint:

runs-on: ubuntu-latest

steps:
# Important: This sets up your GITHUB_WORKSPACE environment variable
- uses: actions/checkout@v2

- name: ansible-lint
# replace "master" with any valid ref
uses: ansible/ansible-lint-action@master
with:
# [required]
# Paths to ansible files (i.e., playbooks, tasks, handlers etc..)
# or valid Ansible directories according to the Ansible role
# directory structure.
# If you want to lint multiple ansible files, use the following syntax
# targets: |
# playbook_1.yml
# playbook_2.yml
targets: |
/github/workspace/omnia.yml
/github/workspace/omnia_config.yml
/github/workspace/platforms/jupyterhub.yml
/github/workspace/platforms/kubeflow.yml
/github/workspace/tools/install_tools.yml
/github/workspace/tools/intel_tools.yml
/github/workspace/tools/olm.yml
# [optional]
# Arguments to override a package and its version to be set explicitly.
# Must follow the example syntax.
#override-deps: |
# ansible==2.9
# ansible-lint==4.2.0
# [optional]
# Arguments to be passed to the ansible-lint

# Options:
# -q quieter, although not silent output
# -p parseable output in the format of pep8
# --parseable-severity parseable output including severity of rule
# -r RULESDIR specify one or more rules directories using one or
# more -r arguments. Any -r flags override the default
# rules in ansiblelint/rules, unless -R is also used.
# -R Use default rules in ansiblelint/rules in addition to
# any extra
# rules directories specified with -r. There is no need
# to specify this if no -r flags are used
# -t TAGS only check rules whose id/tags match these values
# -x SKIP_LIST only check rules whose id/tags do not match these
# values
# --nocolor disable colored output
# --exclude=EXCLUDE_PATHS
# path to directories or files to skip. This option is
# repeatable.
# -c C Specify configuration file to use. Defaults to ".ansible-lint"
args: "-x 305"
1 change: 1 addition & 0 deletions .metadata/omnia_version
@@ -0,0 +1 @@
Omnia version 1.0.0
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Expand Up @@ -32,7 +32,7 @@ Contributions to Omnia are made through [Pull Requests (PRs)](https://help.githu
6. **Create a pull request:** [Create a pull request](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request) with a title following this format Issue ###: Description (_i.e., Issue 1023: Reformat testutils_). It is important that you do a good job with the description to make the job of the code reviewer easier. A good description not only reduces review time, but also reduces the probability of a misunderstanding with the pull request.
* **Important:** When preparing a pull request it is important to stay up-to-date with the project repository. We recommend that you rebase against the upstream repo _frequently_. To do this, use the following commands:
```
git pull --rebase upstream master #upstream is dellhpc/omnia
git pull --rebase upstream devel #upstream is dellhpc/omnia
git push --force origin <pr-branch-name> #origin is your fork of the repository (e.g., <github_user_name>/omnia.git)
```
* **PR Description:** Be sure to fully describe the pull request. Ideally, your PR description will contain:
Expand All @@ -42,7 +42,7 @@ Contributions to Omnia are made through [Pull Requests (PRs)](https://help.githu
4. How to verify that the changes work correctly.

## Omnia Branches and Contribution Flow
The diagram below describes the contribution flow. Omnia has two lifetime branches: `devel` and `master`. The `master` branch is reserved for releases and their associated tags. The `devel` branch is where all development work occurs. The `devel` branch is also the default branch for the project.
The diagram below describes the contribution flow. Omnia has two lifetime branches: `devel` and `release`. The `release` branch is reserved for releases and their associated tags. The `devel` branch is where all development work occurs. The `devel` branch is also the default branch for the project.

![Omnia Branch Flowchart](docs/images/omnia-branch-structure.png "Flowchart of Omnia branches")

Expand Down
4 changes: 3 additions & 1 deletion README.md
@@ -1,6 +1,8 @@
<img src="docs/images/omnia-logo.png" width="500px">

![GitHub](https://img.shields.io/github/license/dellhpc/omnia) ![GitHub issues](https://img.shields.io/github/issues-raw/dellhpc/omnia) ![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/dellhpc/omnia?include_prereleases) ![GitHub last commit (branch)](https://img.shields.io/github/last-commit/dellhpc/omnia/devel) ![GitHub commits since tagged version](https://img.shields.io/github/commits-since/dellhpc/omnia/omnia-v0.2/devel)
![GitHub](https://img.shields.io/github/license/dellhpc/omnia) ![GitHub issues](https://img.shields.io/github/issues-raw/dellhpc/omnia) ![GitHub release (latest by date including pre-releases)](https://img.shields.io/github/v/release/dellhpc/omnia?include_prereleases) ![GitHub last commit (branch)](https://img.shields.io/github/last-commit/dellhpc/omnia/devel) ![GitHub commits since tagged version](https://img.shields.io/github/commits-since/dellhpc/omnia/v1.0.0/devel)

![GitHub contributors](https://img.shields.io/github/contributors-anon/dellhpc/omnia) ![GitHub forks](https://img.shields.io/github/forks/dellhpc/omnia) ![GitHub Repo stars](https://img.shields.io/github/stars/dellhpc/omnia) ![GitHub all releases](https://img.shields.io/github/downloads/dellhpc/omnia/total)

#### Ansible playbook-based deployment of Slurm and Kubernetes on Dell EMC PowerEdge servers running an RPM-based Linux OS

Expand Down
16 changes: 8 additions & 8 deletions kubernetes/jupyterhub.yaml → appliance/appliance.yml
@@ -1,4 +1,4 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -11,12 +11,12 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

---
#Playbook for installing JupyterHub v1.1.0 in Omnia

# Start K8s worker servers
- hosts: master
gather_facts: false

- name: Executing omnia roles
hosts: localhost
connection: local
roles:
- jupyterhub
- common
- provision
- web_ui
49 changes: 49 additions & 0 deletions appliance/appliance_config.yml
@@ -0,0 +1,49 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---

# Password used while deploying OS on bare metal servers and for Cobbler UI.
# The Length of the password should be at least 8.
# The password must not contain -,\, ',"
provision_password: ""

# Password used for the AWX UI.
# The Length of the password should be at least 8.
# The password must not contain -,\, ',"
awx_password: ""

# The nic/ethernet card that needs to be connected to the HPC switch.
# This nic will be configured by Omnia for the DHCP server.
# Default value of nic is em1.
hpc_nic: "em1"

# The nic/ethernet card that will be connected to the public internet.
# Default value of nic is em2
public_nic: "em2"

# This is the path where user has kept the iso image that needs to be provisioned in target nodes.
# The iso file should be CentOS7-2009-minimal edition.
# Other iso file not supported.
iso_file_path: ""

# The mapping file consists of the MAC address and its respective IP address and hostname.
# The format of mapping file should be MAC,hostname,IP and must be a CSV file.
# A template for mapping file exists in omnia/examples and is named as mapping_file.csv.
# This depicts the path where user has kept the mapping file for DHCP configurations.
mapping_file_path: ""

# The dhcp range for assigning the IPv4 address to the baremetal nodes.
# Example: 10.1.23.1
dhcp_start_ip_range: ""
dhcp_end_ip_range: ""
20 changes: 20 additions & 0 deletions appliance/inventory.yml
@@ -0,0 +1,20 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---
- name: Dynamic Inventory
hosts: localhost
connection: local
gather_facts: no
roles:
- inventory
3 changes: 3 additions & 0 deletions appliance/roles/common/files/daemon.json
@@ -0,0 +1,3 @@
{
"bip": "172.18.0.1/16"
}
86 changes: 86 additions & 0 deletions appliance/roles/common/tasks/docker_installation.yml
@@ -0,0 +1,86 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---

- name: Add docker repo
get_url:
url: "{{ docker_repo_url }}"
dest: "{{ docker_repo_dest }}"
tags: install

- name: Enable docker edge and test repo
ini_file:
dest: "{{ docker_repo_dest }}"
section: "{{ item }}"
option: enabled
value: "{{ success }}"
with_items: ['docker-ce-test', 'docker-ce-edge']
tags: install

- name: Install docker
package:
name: "{{ container_repo_install }}"
state: present
become: yes
tags: install

- name: Start services
service:
name: "{{ container_type }}"
state: started
enabled: yes
become: yes
tags: install

- name: Uninstall docker-py using pip
pip:
name: ['docker-py','docker']
state: absent
tags: install

- name: Install docker using pip
pip:
name: docker
state: present
tags: install

- name: Update pip
command: pip3 install --upgrade pip
changed_when: false

- name: Installation using python3
pip:
name: "{{ docker_compose }}"
executable: pip3
tags: install

- name: Versionlock docker
command: "yum versionlock '{{ item }}'"
args:
warn: false
with_items:
- "{{ container_repo_install }}"
changed_when: true
tags: install

- name: Configure docker
copy:
src: daemon.json
dest: "{{ daemon_dest }}"
tags: install

- name: Restart docker
service:
name: docker
state: restarted
19 changes: 19 additions & 0 deletions appliance/roles/common/tasks/docker_volume.yml
@@ -0,0 +1,19 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---

- name: Create a docker volume
docker_volume:
name: "{{ docker_volume_name }}"

25 changes: 25 additions & 0 deletions appliance/roles/common/tasks/internet_validation.yml
@@ -0,0 +1,25 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---

- name: Internet connectivity status
wait_for:
host: "{{ hostname }}"
port: "{{ port_no }}"
state: started
delay: "{{ internet_delay }}"
timeout: "{{ internet_timeout }}"
msg: "{{ internet_status }}"
register: internet_value
tags: install
35 changes: 35 additions & 0 deletions appliance/roles/common/tasks/main.yml
@@ -0,0 +1,35 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
---
- name: Mount Path
set_fact:
mount_path: "{{ role_path + '/../../..' }}"

- name: Pre-requisite validation
import_tasks: pre_requisite.yml

- name: Internet validation
import_tasks: internet_validation.yml

- name: Common packages installation
import_tasks: package_installation.yml

- name: Basic Configuration
import_tasks: password_config.yml

- name: Docker installation and configuration
import_tasks: docker_installation.yml

- name: Docker volume creation
import_tasks: docker_volume.yml
@@ -1,4 +1,4 @@
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
# Copyright 2020 Dell Inc. or its subsidiaries. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -11,13 +11,10 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

---
- name: Install SLURM RPMs on compute
yum:
name: "{{ item }}"
#name: "{{ query('fileglob', ['/home/rpms/slurm*20*.rpm']) }}" <-- how it should work to avoid loop
with_fileglob:
- /home/rpms/slurm*20*.rpm
tags: install

- name: Install packages
package:
name: "{{ common_packages }}"
state: present
tags: install

0 comments on commit a7275b9

Please sign in to comment.