From a2dfbda04cd05cdcdcb9f6a421ce257c78852357 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hampus=20N=C3=A4sstr=C3=B6m?= Date: Mon, 11 Nov 2024 12:04:42 +0100 Subject: [PATCH] 36 update docs with new repository name (#37) Updated repository actions and instructions to reflect the new repository name --- .github/workflows/initialize.yml | 16 ++++++++-------- README.md | 24 ++++++++++++------------ configs/nomad.yaml | 2 +- docker-compose.yaml | 8 ++++---- 4 files changed, 25 insertions(+), 25 deletions(-) diff --git a/.github/workflows/initialize.yml b/.github/workflows/initialize.yml index 5ed2e66..6cfe15c 100644 --- a/.github/workflows/initialize.yml +++ b/.github/workflows/initialize.yml @@ -16,7 +16,7 @@ permissions: jobs: initialize_repository: - if: github.repository != 'FAIRmat-NFDI/nomad-distribution-template' + if: github.repository != 'FAIRmat-NFDI/nomad-distro-template' runs-on: ubuntu-latest steps: @@ -27,25 +27,25 @@ jobs: run: | sed -i "/# NOMAD Oasis Distribution/,/button on the right./d" README.md export image_name="${{ github.repository }}" - sed -i "s|fairmat-nfdi/nomad-distribution-template|${image_name,,}|g" README.md - sed -i "s|FAIRmat-NFDI/nomad-distribution-template|${{ github.repository }}|g" README.md + sed -i "s|fairmat-nfdi/nomad-distro-template|${image_name,,}|g" README.md + sed -i "s|FAIRmat-NFDI/nomad-distro-template|${{ github.repository }}|g" README.md sed -i "s|FAIRmat-NFDI|${{ github.repository_owner }}|g" README.md - sed -i "s|nomad-distribution-template|${{ github.event.repository.name }}|g" README.md - sed -i "s|template https://github.com/${{ github.repository }}|template https://github.com/FAIRmat-NFDI/nomad-distribution-template|g" README.md - sed -i "s|${{ github.repository }}/releases/latest|FAIRmat-NFDI/nomad-distribution-template/releases/latest|g" README.md + sed -i "s|nomad-distro-template|${{ github.event.repository.name }}|g" README.md + sed -i "s|template https://github.com/${{ github.repository }}|template https://github.com/FAIRmat-NFDI/nomad-distro-template|g" README.md + sed -i "s|${{ github.repository }}/releases/latest|FAIRmat-NFDI/nomad-distro-template/releases/latest|g" README.md sed -i "s|@ git+https://github.com/${{ github.repository_owner }}|@ git+https://github.com/FAIRmat-NFDI|g" README.md # Replaces the template repository name in the docker config file with the new one - name: Update docker-compose.yaml run: | export image_name="${{ github.repository }}" - sed -i "s|fairmat-nfdi/nomad-distribution-template|${image_name,,}|g" docker-compose.yaml + sed -i "s|fairmat-nfdi/nomad-distro-template|${image_name,,}|g" docker-compose.yaml # Replaces the template repository name in the nomad config with the new one - name: Update nomad.yaml run: | export image_name="${{ github.repository }}" - sed -i "s|fairmat-nfdi/nomad-distribution-template|${image_name,,}|g" configs/nomad.yaml + sed -i "s|fairmat-nfdi/nomad-distro-template|${image_name,,}|g" configs/nomad.yaml # Deletes this workflow file to prevent it from running on branch creation - name: Delete initialization workflow diff --git a/README.md b/README.md index 682fe73..8b49f39 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -![docker image](https://github.com/FAIRmat-NFDI/nomad-distribution-template/actions/workflows/docker-publish.yml/badge.svg) +![docker image](https://github.com/FAIRmat-NFDI/nomad-distro-template/actions/workflows/docker-publish.yml/badge.svg) # NOMAD Oasis Distribution *Template* This repository is a template for creating your own custom NOMAD Oasis distribution image. -Click [here](https://github.com/new?template_name=nomad-distribution-template&template_owner=FAIRmat-NFDI) +Click [here](https://github.com/new?template_name=nomad-distro-template&template_owner=FAIRmat-NFDI) to use this template, or click the `Use this template` button in the upper right corner of the main GitHub page for this template. @@ -54,16 +54,16 @@ Below are instructions for how to deploy this NOMAD Oasis distribution 2. Clone the repository or download the repository as a zip file. ```sh - git clone https://github.com/FAIRmat-NFDI/nomad-distribution-template.git - cd nomad-distribution-template + git clone https://github.com/FAIRmat-NFDI/nomad-distro-template.git + cd nomad-distro-template ``` or ```sh - curl-L -o nomad-distribution-template.zip "https://github.com/FAIRmat-NFDI/nomad-distribution-template/archive/main.zip" - unzip nomad-distribution-template.zip - cd nomad-distribution-template + curl-L -o nomad-distro-template.zip "https://github.com/FAIRmat-NFDI/nomad-distro-template/archive/main.zip" + unzip nomad-distro-template.zip + cd nomad-distro-template ``` 3. _On Linux only,_ recursively change the owner of the `.volumes` directory to the nomad user (1000) @@ -118,7 +118,7 @@ You can find more details on setting up and maintaining an Oasis in the NOMAD do ### For an existing Oasis If you already have an Oasis running you only need to change the image being pulled in -your `docker-compose.yaml` with `ghcr.io/fairmat-nfdi/nomad-distribution-template:main` for the services +your `docker-compose.yaml` with `ghcr.io/fairmat-nfdi/nomad-distro-template:main` for the services `worker`, `app`, `north`, and `logtransfer`. If you want to use the `nomad.yaml` from this repository you also need to comment out @@ -183,7 +183,7 @@ This image has been added to the [`configs/nomad.yaml`](configs/nomad.yaml) duri The image is quite large and might cause a timeout the first time it is run. In order to avoid this you can pre pull the image with: ``` -docker pull ghcr.io/fairmat-nfdi/nomad-distribution-template/jupyter:main +docker pull ghcr.io/fairmat-nfdi/nomad-distro-template/jupyter:main ``` If you want additional python packages to be available to all users in the jupyter hub you can add those to the jupyter table in the [`pyproject.toml`](pyproject.toml): @@ -205,7 +205,7 @@ jupyter = [ In order to update an existing distribution with any potential changes in the template you can add a new `git remote` for the template and merge with that one while allowing for unrelated histories: ``` -git remote add template https://github.com/FAIRmat-NFDI/nomad-distribution-template +git remote add template https://github.com/FAIRmat-NFDI/nomad-distro-template git fetch template git merge template/main --allow-unrelated-histories ``` @@ -217,7 +217,7 @@ git checkout --theirs Dockerfile git checkout --theirs .github/workflows/docker-publish.yml ``` -For detailed instructions on how to resolve the merge conflicts between different version we refer you to the latest template release [notes](https://github.com/FAIRmat-NFDI/nomad-distribution-template/releases/latest) +For detailed instructions on how to resolve the merge conflicts between different version we refer you to the latest template release [notes](https://github.com/FAIRmat-NFDI/nomad-distro-template/releases/latest) Once the merge conflicts are resolved you should add the changes and commit them @@ -230,7 +230,7 @@ Ideally all workflows should be triggered automatically but you might need to ru ## FAQ/Trouble shooting -_I get an_ `Error response from daemon: Head "https://ghcr.io/v2/FAIRmat-NFDI/nomad-distribution-template/manifests/main": unauthorized` +_I get an_ `Error response from daemon: Head "https://ghcr.io/v2/FAIRmat-NFDI/nomad-distro-template/manifests/main": unauthorized` _when trying to pull my docker image._ Most likely you have not made the package public or provided a personal access token (PAT). diff --git a/configs/nomad.yaml b/configs/nomad.yaml index b23f063..b7493ff 100644 --- a/configs/nomad.yaml +++ b/configs/nomad.yaml @@ -11,7 +11,7 @@ north: tools: options: jupyter: - image: ghcr.io/fairmat-nfdi/nomad-distribution-template/jupyter:main + image: ghcr.io/fairmat-nfdi/nomad-distro-template/jupyter:main meta: deployment: "oasis" diff --git a/docker-compose.yaml b/docker-compose.yaml index 2fbfb4d..f9c2726 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -68,7 +68,7 @@ services: # nomad worker (processing) worker: restart: unless-stopped - image: ghcr.io/fairmat-nfdi/nomad-distribution-template:main + image: ghcr.io/fairmat-nfdi/nomad-distro-template:main container_name: nomad_oasis_worker environment: NOMAD_SERVICE: nomad_oasis_worker @@ -91,7 +91,7 @@ services: # nomad app (api + proxy) app: restart: unless-stopped - image: ghcr.io/fairmat-nfdi/nomad-distribution-template:main + image: ghcr.io/fairmat-nfdi/nomad-distro-template:main container_name: nomad_oasis_app environment: NOMAD_SERVICE: nomad_oasis_app @@ -130,7 +130,7 @@ services: # nomad remote tools hub (JupyterHUB, e.g. for AI Toolkit) north: restart: unless-stopped - image: ghcr.io/fairmat-nfdi/nomad-distribution-template:main + image: ghcr.io/fairmat-nfdi/nomad-distro-template:main container_name: nomad_oasis_north environment: NOMAD_SERVICE: nomad_oasis_north @@ -165,7 +165,7 @@ services: # to enable the logtransfer service run "docker compose --profile with_logtransfer up" logtransfer: restart: unless-stopped - image: ghcr.io/fairmat-nfdi/nomad-distribution-template:main + image: ghcr.io/fairmat-nfdi/nomad-distro-template:main container_name: nomad_oasis_logtransfer environment: NOMAD_SERVICE: nomad_oasis_logtransfer