From 2d68479615df8829b58514d674ad8325728b3393 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Juli=C3=A1n=20Espina?= Date: Wed, 7 Aug 2024 16:55:10 -0600 Subject: [PATCH] docs: add README and fix charmcraft.yaml links --- README.md | 87 +++++++++++++++++++++++++++++++ charms/slurmctld/charmcraft.yaml | 20 +++---- charms/slurmd/charmcraft.yaml | 12 ++--- charms/slurmdbd/charmcraft.yaml | 8 +-- charms/slurmrestd/charmcraft.yaml | 8 +-- 5 files changed, 112 insertions(+), 23 deletions(-) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..94f88f4 --- /dev/null +++ b/README.md @@ -0,0 +1,87 @@ + +# Slurm charms + +[Juju](https://juju.is) charms for automating the Day 0 to Day 2 operations of the [Slurm workload manager](https://slurm.schedmd.com/overview.html) ⚖️🐧 + +[![CI](https://github.com/charmed-hpc/slurm-charms/actions/workflows/ci.yaml/badge.svg)](https://github.com/charmed-hpc/slurm-charms/actions/workflows/ci.yaml/badge.svg) +[![Release](https://github.com/charmed-hpc/slurm-charms/actions/workflows/release.yaml/badge.svg)](https://github.com/charmed-hpc/slurm-charms/actions/workflows/release.yaml/badge.svg) +[![Matrix](https://img.shields.io/matrix/ubuntu-hpc%3Amatrix.org?logo=matrix&label=ubuntu-hpc)](https://matrix.to/#/#hpc:ubuntu.com) + +The `slurm-charms` repository provides many of the Slurm daemons that are required to deploy, configure and manage a Slurm-based HPC cluster: + +- [`slurmctld`](./charms/slurmctld/): the central management daemon for Slurm. +- [`slurmd`](./charms/slurmd): the compute node daemon for Slurm. +- [`slurmdbd`](./charms/slurmdbd): the database daemon for Slurm. +- [`slurmrestd`](./charms/slurmrestd/): the REST API interface to Slurm. + +## ✨ Getting started + +This should be run using Juju 3.x or greater. + +```shell +$ juju deploy slurmctld --channel edge +$ juju deploy slurmd --channel edge +$ juju deploy slurmdbd --channel edge +$ juju deploy slurmrestd --channel edge +$ juju deploy mysql --channel 8.0/stable +$ juju deploy mysql-router slurmdbd-mysql-router --channel dpe/edge + +$ juju integrate slurmctld:slurmd slurmd:slurmctld +$ juju integrate slurmctld:slurmdbd slurmdbd:slurmctld +$ juju integrate slurmctld:slurmrestd slurmrestd:slurmctld +$ juju integrate slurmdbd-mysql-router:backend-database mysql:database +$ juju integrate slurmdbd:database slurmdbd-mysql-router:database +``` + +## 🤔 What's next? + +If you want to know more about the project, there are several links available for you to explore: + +* [Documentation](https://canonical-charmed-hpc.readthedocs-hosted.com/en/latest) +* [Open an issue](https://github.com/charmed-hpc/slurm-charms/issues/new?title=ISSUE+TITLE&body=*Please+describe+your+issue*) +* [Ask a question on Github](https://github.com/orgs/charmed-hpc/discussions/categories/q-a) + +## 🛠️ Development + +The project uses [tox](tox.wiki) as its command runner. It's very common to run the following four +commands to check that the codebase is in a good state. + +```shell +tox run -e fmt # Apply correct formatting to code. +tox run -e lint # Check code against coding style standards. +tox run -e type # Type checking. +tox run -e unit # Run unit tests. +``` + +You can also run integration tests if you desire, but be aware that it requires a significant amount +of computer resources to run them. + +```shell +tox run -e integration +``` + +If you don't have enough resources to run this check but you're planning to contribute changes to the repository, +opening a PR against the repository will also run the integration tests. + +If you're interested in contributing, take a look at our [contributing guidelines]((./CONTRIBUTING.md)). + +## 🤝 Project and Community + +The Slurm charms are a project of the [Ubuntu High-Performance Computing community](https://ubuntu.com/community/governance/teams/hpc). +Interested in contributing bug fixes, patches, documentation, or feedback? Want to join the Ubuntu HPC community? You’ve come to the right place 🤩 + +Here’s some links to help you get started with joining the community: + +* [Ubuntu Code of Conduct](https://ubuntu.com/community/ethos/code-of-conduct) +* [Contributing guidelines](./CONTRIBUTING.md) +* [Join the conversation on Matrix](https://matrix.to/#/#hpc:ubuntu.com) +* [Get the latest news on Discourse](https://discourse.ubuntu.com/c/hpc/151) +* [Ask and answer questions on GitHub](https://github.com/orgs/charmed-hpc/discussions/categories/q-a) + +## 📋 License + +The Slurm charms are free software, distributed under the Apache Software License, version 2.0. +See the [Apache-2.0 LICENSE](./LICENSE) file for further details. + +The Slurm workload manager is licensed under the GNU General Public License, version 2, or any later version. +See Slurm's [legal notice](https://slurm.schedmd.com/disclaimer.html) for further licensing information about Slurm. diff --git a/charms/slurmctld/charmcraft.yaml b/charms/slurmctld/charmcraft.yaml index f8e2fd8..81679c5 100644 --- a/charms/slurmctld/charmcraft.yaml +++ b/charms/slurmctld/charmcraft.yaml @@ -17,10 +17,10 @@ links: contact: https://matrix.to/#/#hpc:ubuntu.com issues: - - https://github.com/charmed-hpc/slurmctld-operator/issues + - https://github.com/charmed-hpc/slurm-charms/issues source: - - https://github.com/charmed-hpc/slurmctld-operator + - https://github.com/charmed-hpc/slurm-charms requires: slurmd: @@ -51,7 +51,7 @@ config: default: osd-cluster description: | Name to be recorded in database for jobs from this cluster. - + This is important if a single database is used to record information from multiple Slurm-managed clusters. @@ -67,7 +67,7 @@ config: default: "" description: | User supplied Slurm configuration as a multiline string. - + Example usage: $ juju config slurmcltd slurm-conf-parameters="$(cat additional.conf)" @@ -78,13 +78,13 @@ config: ConstrainCores=yes description: | User supplied configuration for `cgroup.conf`. - + health-check-params: default: "" type: string description: | Extra parameters for NHC command. - + This option can be used to customize how NHC is called, e.g. to send an e-mail to an admin when NHC detects an error set this value to. `-M admin@domain.com`. @@ -103,7 +103,7 @@ actions: show-current-config: description: | Display the currently used `slurm.conf`. - + Example usage: ```bash @@ -114,7 +114,7 @@ actions: drain: description: | Drain specified nodes. - + Example usage: $ juju run slurmctld/leader drain nodename="node-[1,2]" reason="Updating kernel" params: @@ -130,10 +130,10 @@ actions: resume: description: | Resume specified nodes. - + Note: Newly added nodes will remain in the `down` state until configured, with the `node-configured` action. - + Example usage: $ juju run slurmctld/leader resume nodename="node-[1,2]" params: nodename: diff --git a/charms/slurmd/charmcraft.yaml b/charms/slurmd/charmcraft.yaml index 1af8322..a3f5a00 100644 --- a/charms/slurmd/charmcraft.yaml +++ b/charms/slurmd/charmcraft.yaml @@ -7,7 +7,7 @@ summary: | description: | This charm provides slurmd, munged, and the bindings to other utilities that make lifecycle operations a breeze. - + slurmd is the compute node daemon of SLURM. It monitors all tasks running on the compute node, accepts work (tasks), launches tasks, and kills running tasks upon request. @@ -15,11 +15,11 @@ description: | links: contact: https://matrix.to/#/#hpc:ubuntu.com - issues: - - https://github.com/charmed-hpc/slurmd-operator/issues + issues: + - https://github.com/charmed-hpc/slurm-charms/issues source: - - https://github.com/charmed-hpc/slurmd-operator + - https://github.com/charmed-hpc/slurm-charms assumes: - juju @@ -59,8 +59,8 @@ config: Additional partition configuration parameters, specified as a space separated `key=value` in a single line. Find a list of all possible partition configuration parameters [here](https://slurm.schedmd.com/slurm.conf.html#SECTION_PARTITION-CONFIGURATION). - - + + Example usage: ```bash $ juju config slurmd partition-config="DefaultTime=45:00 MaxTime=1:00:00" diff --git a/charms/slurmdbd/charmcraft.yaml b/charms/slurmdbd/charmcraft.yaml index a9cd3a3..35790f7 100644 --- a/charms/slurmdbd/charmcraft.yaml +++ b/charms/slurmdbd/charmcraft.yaml @@ -19,11 +19,11 @@ description: | links: contact: https://matrix.to/#/#hpc:ubuntu.com - source: - - https://github.com/omnivector-solutions/slurmdbd-operator - issues: - - https://github.com/omnivector-solutions/slurmdbd-operator/issues + - https://github.com/charmed-hpc/slurm-charms/issues + + source: + - https://github.com/charmed-hpc/slurm-charms requires: database: diff --git a/charms/slurmrestd/charmcraft.yaml b/charms/slurmrestd/charmcraft.yaml index ab31126..d90d202 100644 --- a/charms/slurmrestd/charmcraft.yaml +++ b/charms/slurmrestd/charmcraft.yaml @@ -12,10 +12,12 @@ description: | links: contact: https://matrix.to/#/#hpc:ubuntu.com - source: - - https://github.com/omnivector-solutions/slurmrestd-operator + issues: - - https://github.com/omnivector-solutions/slurmrestd-operator/issues + - https://github.com/charmed-hpc/slurm-charms/issues + + source: + - https://github.com/charmed-hpc/slurm-charms provides: slurmctld: