diff --git a/.gitea/workflows/deploy-pages.yml b/.gitea/workflows/deploy-pages.yml new file mode 100644 index 0000000..3588b20 --- /dev/null +++ b/.gitea/workflows/deploy-pages.yml @@ -0,0 +1,39 @@ +--- +name: Build and Deploy Documentation + +on: + push: + branches: + - master + workflow_dispatch: + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + container: + image: gitea.psi.ch/hpce/gitea-pages + env: + JEKYLL_ENV: production + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Build Jekyll website + run: | + bundle exec jekyll --version + bundle exec jekyll build -d public + + - name: Configure Git + run: | + git config --global user.name "Gitea Actions" + git config --global user.email "actions@gitea.local" + + - name: Push to gitea-pages branch + run: | + git checkout --orphan gitea-pages + git reset --hard + ls -la + cp -r ./public/* . + git add . + git commit -m "Deploy site" + git push -f https://${{secrets.GITHUB_TOKEN}}@gitea.psi.ch/${{ github.repository }}.git gitea-pages diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index 4b87a79..0000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,48 +0,0 @@ -stages: - - test - - deploy - -image: alpine:3.13 - -variables: - JEKYLL_ENV: production - -before_script: - - apk list -I - - > - apk --no-cache add libatomic readline readline-dev libxml2 libxml2-dev - ncurses-terminfo-base ncurses-terminfo - libxslt libxslt-dev zlib-dev zlib - ruby ruby-dev yaml yaml-dev - libffi-dev build-base git nodejs - - gem install etc --no-document - - gem install bundler -v 2.4.22 --no-document - - pwd - - ls -l - - bundle install - -###################################################################### -# this defines the job (for gitlab-pages it has the special name "pages") -pages: - stage: deploy - script: - - pwd - - ls -l - - bundle exec jekyll --version - - bundle exec jekyll build -d public - -# defines what is produced by the scripts (the "artifacts") - artifacts: - paths: - - public - - # the tags define which runners (builders) will be selected. A - # suitable runner must have an identical tag - tags: - - shared - - gitlab-pages - - docker - - # the "pages" job is only to be run for the master branch - only: - - master diff --git a/Dockerfile b/Dockerfile index 17b5135..05da615 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,24 +1,24 @@ FROM alpine:3.13 WORKDIR /tmp -ADD Gemfile /tmp/ -ADD Gemfile.lock /tmp/ +COPY Gemfile /tmp/ +COPY Gemfile.lock /tmp/ -RUN apk list -I && \ - apk --no-cache add libatomic readline readline-dev libxml2 libxml2-dev \ +RUN apk list -I && apk --no-cache add \ + libatomic readline readline-dev libxml2 libxml2-dev \ ncurses-terminfo-base ncurses-terminfo \ libxslt libxslt-dev zlib-dev zlib \ ruby ruby-dev yaml yaml-dev \ - libffi-dev build-base git nodejs -RUN gem env -RUN gem install etc --no-document -RUN gem install bundler -v 2.4.22 --no-document -RUN pwd -RUN ls -l -RUN bundle install + libffi-dev build-base git nodejs \ + && gem env \ + && gem install etc --no-document \ + && gem install bundler -v 2.4.22 --no-document \ + && pwd \ + && ls -l \ + && bundle install VOLUME /src EXPOSE 4001 WORKDIR /src -ENTRYPOINT ["jekyll", "serve", "--livereload", "-H", "0.0.0.0"] +CMD ["jekyll", "serve", "--livereload", "-H", "0.0.0.0"] diff --git a/README.md b/README.md index 3c416a5..310b5aa 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,7 @@ # HPCE Documentation -This site documents HCPE services at Paul Scherrer Institute, particularly the *Merlin 6* cluster. -Live pages are available at https://lsm-hpce.gitpages.psi.ch. - +This site contains internal documentation of HCPE services at Paul Scherrer Institute, particularly the *Merlin 6* and *Merlin 7* clusters. +Live pages are available at . ## Installation @@ -45,7 +44,8 @@ by Tom Johnson. - Documentation is organized within the `pages` directory - Add the following frontmatter to each (Merlin6) page: - ``` + + ```md --- title: Introduction sidebar: merlin6_sidebar @@ -53,12 +53,19 @@ by Tom Johnson. keywords: key1, key2 --- ``` + - Sidebars are specified in data files, e.g. `_data/sidebars/merlin6_sidebar.yml`. - The top menu is controlled by `_data/topnav.yml` - News can be addin in `_posts`. Filenames must include the date. - Lots of features still need to be configured (e.g. pdf output, tags, etc) - The search bar uses finds substring of the title, tags, keywords, and summary frontmatter. +## Deployment + +We use the Gitea workflow (see `.gitea/workflow/deploy-pages.yml` for details). The +pages are automatically re-generated on each push to `master` branch. The resulting website +is stored under the `gitea-pages` branch, and is automatically exposed. + ## License Theme content is licensed under the MIT license. diff --git a/_config.yml b/_config.yml index 2c2f854..c3bfeba 100644 --- a/_config.yml +++ b/_config.yml @@ -1,5 +1,3 @@ -repository: lsm-hpce/lsm-hpce.gitpages.psi.ch - output: web # this property is useful for conditional filtering of content that is separate from the PDF. @@ -123,7 +121,7 @@ description: "Merlin is the HPC cluster at Paul Scherrer Institute in Switzerlan # the description is used in the feed.xml file # needed for sitemap.xml file only -url: "https://lsm-hpce.gitpages.psi.ch" +url: "https://hpce.pages.psi.ch" baseurl: / diff --git a/_posts/2019-06-12-launching-merlin6-docs.md b/_posts/2019-06-12-launching-merlin6-docs.md index 1c4529a..e8f53bb 100644 --- a/_posts/2019-06-12-launching-merlin6-docs.md +++ b/_posts/2019-06-12-launching-merlin6-docs.md @@ -6,6 +6,6 @@ summary: "More pages will be coming soon." tags: [news, getting_started] --- -Merlin 6 docs are now available at https://lsm-hpce.gitpages.psi.ch/merlin6! +Merlin 6 docs are now available at https://hpce.pages.psi.ch/merlin6! More complete documentation will be coming shortly. diff --git a/_posts/2024-08-07-merlin7-preprod-docs.md b/_posts/2024-08-07-merlin7-preprod-docs.md index 061bcfd..cf9cb14 100644 --- a/_posts/2024-08-07-merlin7-preprod-docs.md +++ b/_posts/2024-08-07-merlin7-preprod-docs.md @@ -9,6 +9,6 @@ tags: [news, getting_started] The Merlin7 cluster is officially in preproduction. This phase will be tested by a few users and slowly we will contact other users to be part of it. Keep in mind that access is restricted. -Merlin7 documentation is now available https://lsm-hpce.gitpages.psi.ch/merlin7/slurm-configuration.html. +Merlin7 documentation is now available https://hpce.pages.psi.ch/merlin7/slurm-configuration.html. More complete documentation will be coming shortly. diff --git a/pages/merlin7/03-Slurm-General-Documentation/slurm-examples.md b/pages/merlin7/03-Slurm-General-Documentation/slurm-examples.md index 9fdbfd9..7bcb7b4 100644 --- a/pages/merlin7/03-Slurm-General-Documentation/slurm-examples.md +++ b/pages/merlin7/03-Slurm-General-Documentation/slurm-examples.md @@ -12,7 +12,7 @@ permalink: /merlin7/slurm-examples.html {{site.data.alerts.warning}}The Merlin7 documentation is Work In Progress. Please do not use or rely on this documentation until this becomes official. -This applies to any page under https://lsm-hpce.gitpages.psi.ch/merlin7/ +This applies to any page under https://hpce.pages.psi.ch/merlin7/ {{site.data.alerts.end}} ## Single core based job examples