Skip to content
CI/CD Inventory

galaxyproject/galaxy-hub (opens in new tab)

8 workflows

Galaxy Training Network news/events

.github/workflows/gtn-import.yml (opens in new tab)
Galaxy Training Network news/events status

Triggers

workflow_dispatch schedule

Jobs

Jobs for Galaxy Training Network news/events
Job Runs on Steps Actions used
Collect news/events from the Galaxy Training Network ubuntu-latest 5
actions/checkout@v4 actions/setup-python@v5
Raw YAML
---
# Pull news/events from the Galaxy Training Network's RSS feed and add them as
# Galaxy Hub posts.
name: Galaxy Training Network news/events

on:
  workflow_dispatch:
  schedule:
    - cron: "0 0,8,16 * * *"

jobs:
  collect:
    name: Collect news/events from the Galaxy Training Network
    runs-on: ubuntu-latest
    env:
      GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
      REPO_NAME: ${{ github.repository }}
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 1

      - name: Set up Python
        uses: actions/setup-python@v5
        with:
          python-version: "3.12"

      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install -r utils/gtn-import-requirements.txt

      - name: Parse GTN news RSS feed
        env:
          FEED_URL: https://training.galaxyproject.org/training-material/feed.xml
          IMPORT_TYPE: news
        run: python utils/gtn-import.py

      - name: Parse GTN events RSS feed
        env:
          FEED_URL: https://training.galaxyproject.org/training-material/events/feed.xml
          IMPORT_TYPE: events
          START_DATE: "2025-02-14"
        run: python utils/gtn-import.py

Last fetched:

Triggers

workflow_dispatch schedule

Jobs

Jobs for Check External Links
Job Runs on Steps Actions used
Check External Links ubuntu-latest 2
lycheeverse/lychee-action@v2 peter-evans/create-issue-from-file@v3
Raw YAML

Last fetched:

Triggers

workflow_dispatch

Jobs

Jobs for Check Internal Links
Job Runs on Steps Actions used
check_links_internal ubuntu-latest 6
actions/checkout@v4 actions/setup-node@v4 peter-evans/create-issue-from-file@v5
Raw YAML

Last fetched:

Triggers

pull_request workflow_dispatch

Jobs

Jobs for PR Tests
Job Runs on Steps Actions used
Lint & Format Check ubuntu-latest 5
actions/checkout@v5 actions/setup-node@v6
Metadata Validation ubuntu-latest 3
actions/checkout@v5 astral-sh/setup-uv@v5
Content Lint ubuntu-latest 3
actions/checkout@v5 actions/setup-node@v6
Unit Tests ubuntu-latest 5
actions/checkout@v5 actions/setup-node@v6
Playwright Tests ubuntu-latest 6
actions/checkout@v5 actions/setup-node@v6 actions/upload-artifact@v4
Raw YAML
name: PR Tests
on:
  pull_request:
  workflow_dispatch:

concurrency:
  group: primary-tests-${{ github.head_ref }}
  cancel-in-progress: true

defaults:
  run:
    working-directory: astro

jobs:
  lint:
    name: Lint & Format Check
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v5

      - name: Setup Node.js
        uses: actions/setup-node@v6
        with:
          node-version: '22'
          cache: 'npm'
          cache-dependency-path: astro/package-lock.json

      - name: Install dependencies
        run: npm ci

      - name: Run ESLint
        run: npm run lint

      - name: Check formatting
        run: npm run format:check

  metadata-validation:
    name: Metadata Validation
    runs-on: ubuntu-latest
    defaults:
      run:
        working-directory: .
    steps:
      - name: Checkout
        uses: actions/checkout@v5

      - name: Set up uv
        uses: astral-sh/setup-uv@v5
        with:
          python-version: "3.12"

      - name: Validate metadata
        run: uv run --python 3.12 --with pykwalify --with pyyaml make validate-metadata

  content-lint:
    name: Content Lint
    runs-on: ubuntu-latest
    defaults:
      run:
        working-directory: .
    steps:
      - name: Checkout
        uses: actions/checkout@v5

      - name: Setup Node.js
        uses: actions/setup-node@v6
        with:
          node-version: '22'
          cache: 'npm'
          cache-dependency-path: astro/package-lock.json

      - name: Lint content
        run: cd astro && npm ci && npm run content:lint

  unit-tests:
    name: Unit Tests
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v5

      - name: Setup Node.js
        uses: actions/setup-node@v6
        with:
          node-version: '22'
          cache: 'npm'
          cache-dependency-path: astro/package-lock.json

      - name: Install dependencies
        run: npm ci

      - name: Preprocess content
        run: npm run preprocess

      - name: Run unit tests
        run: npm run test:unit

  e2e-tests:
    name: Playwright Tests
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v5

      - name: Setup Node.js
        uses: actions/setup-node@v6
        with:
          node-version: '22'
          cache: 'npm'
          cache-dependency-path: astro/package-lock.json

      - name: Install dependencies
        run: npm ci

      - name: Install Playwright browsers
        run: npx playwright install --with-deps chromium

      - name: Run Playwright tests
        run: npm run test

      - name: Upload test artifacts
        uses: actions/upload-artifact@v4
        if: ${{ !cancelled() }}
        with:
          name: playwright-report
          path: astro/playwright-report/
          retention-days: 30

Last fetched:

Triggers

pull_request push workflow_dispatch schedule

Jobs

Jobs for Compress images
Job Runs on Steps Actions used
calibreapp/image-actions ubuntu-latest 3
actions/checkout@v4 calibreapp/image-actions@main peter-evans/create-pull-request@v7
Raw YAML
# This Action will run in the following scenarios:
# - on Pull Requests containing images (not including forks)
# - on pushing of images to `main` (for forks)
# - on demand (https://github.blog/changelog/2020-07-06-github-actions-manual-triggers-with-workflow_dispatch/)
# - at 11 PM every Sunday if anything gets missed with any of the above scenarios
# For Pull Requests, the images are added to the PR.
# For other scenarios, a new PR will be opened if any images are compressed.
name: Compress images
on:
  pull_request:
    paths:
      - "**.jpg"
      - "**.jpeg"
      - "**.png"
  push:
    branches:
      - main
    paths:
      - "**.jpg"
      - "**.jpeg"
      - "**.png"
  workflow_dispatch:
  schedule:
    - cron: "00 23 * * 0"
jobs:
  build:
    name: calibreapp/image-actions
    runs-on: ubuntu-latest
    permissions:
      contents: write
      pull-requests: write
    # Only run on main repo on and PRs that match the main repo.
    if: |
      github.repository == 'galaxyproject/galaxy-hub' &&
      (github.event_name != 'pull_request' ||
       github.event.pull_request.head.repo.full_name == github.repository)
    steps:
      - name: Checkout Branch
        uses: actions/checkout@v4
      - name: Compress Images
        id: calibre
        uses: calibreapp/image-actions@main
        with:
          githubToken: ${{ secrets.GITHUB_TOKEN }}
          # For non-Pull Requests, run in compressOnly mode and we'll PR after.
          ## compressOnly: ${{ github.event_name != 'pull_request' }}
          # Attempt to prevent webp recompression by minimizing diff.
          webpQuality: '90'
          minPctChange: '2.5'
      - name: Create Pull Request
        # If it's not a Pull Request then commit any changes as a new PR.
        if: |
          github.event_name != 'pull_request' &&
          steps.calibre.outputs.markdown != ''
        uses: peter-evans/create-pull-request@v7
        with:
          title: Auto Compress Images
          branch: action_compress_images
          commit-message: Compress Images
          body: ${{ steps.calibre.outputs.markdown }}

Last fetched:

Triggers

workflow_dispatch push schedule

Jobs

Jobs for Publish Hub
Job Runs on Steps Actions used
publish ubuntu-latest 8
actions/checkout@v5 actions/setup-node@v6 aws-actions/configure-aws-credentials@v4
Raw YAML
name: Publish Hub
on:
  workflow_dispatch:
  push:
    branches:
      - main
  schedule:
    - cron: "30 23 * * *"
concurrency:
  group: publish-${{ github.ref_name }}
jobs:
  publish:
    runs-on: ubuntu-latest
    if: github.repository_owner == 'galaxyproject'
    steps:
      - name: Checkout
        uses: actions/checkout@v5
      - name: Setup Node.js
        uses: actions/setup-node@v6
        with:
          node-version: '22'
      - name: Install dependencies
        run: cd astro && npm ci
      - name: Build Astro site
        run: cd astro && npm run build
      - name: Configure AWS credentials
        uses: aws-actions/configure-aws-credentials@v4
        with:
          aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
          aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
          aws-region: us-east-2
      - name: Sync to preview S3
        run: aws s3 sync astro/dist/ s3://astro-hub/ --delete
      - name: Set S3 redirect metadata
        run: S3_BUCKET=astro-hub node deploy/set-s3-redirects.mjs
      - name: Invalidate CloudFront cache
        run: aws cloudfront create-invalidation --distribution-id ${{ secrets.ASTRO_CLOUDFRONT_DISTRIBUTION_ID }} --paths "/*"

Last fetched:

Deploy CloudFront Rewrites Function

.github/workflows/rewrites.yml (opens in new tab)
Deploy CloudFront Rewrites Function status

Triggers

push pull_request

Jobs

Jobs for Deploy CloudFront Rewrites Function
Job Runs on Steps Actions used
test ubuntu-latest 3
actions/checkout@v5 actions/setup-node@v5
deploy ubuntu-latest 3
actions/checkout@v5 aws-actions/configure-aws-credentials@v4 dhollerbach/actions.deploy-cloudfront-function@v1
Raw YAML
name: Deploy CloudFront Rewrites Function

on:
  push:
    branches:
      - main
    paths:
      - 'deploy/rewrites.js'
  pull_request:
    branches:
      - main
    paths:
      - 'deploy/rewrites.js'

jobs:
  test:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v5

      - name: Setup Node.js
        uses: actions/setup-node@v5
        with:
          node-version: '24'

      - name: Run tests
        run: node deploy/test-rewrites.js

  deploy:
    runs-on: ubuntu-latest
    needs: test
    if: github.repository_owner == 'galaxyproject' && github.event_name == 'push' && github.ref == 'refs/heads/main'

    steps:
      - name: Checkout code
        uses: actions/checkout@v5

      - name: Configure AWS Credentials
        uses: aws-actions/configure-aws-credentials@v4
        with:
          aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
          aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
          aws-region: us-east-1

      - name: Deploy CloudFront Rewrites Function
        uses: dhollerbach/actions.deploy-cloudfront-function@v1
        with:
          function-name: hub-rewrites
          comment: Deployed from GitHub Actions
          source-file: ./deploy/rewrites.js

Last fetched:

Triggers

workflow_dispatch schedule

Jobs

Jobs for Sync Training Material Files
Job Runs on Steps Actions used
Sync files from training-material ubuntu-latest 4
actions/checkout@v4 peter-evans/create-pull-request@v6
Raw YAML
name: Sync Training Material Files

on:
  workflow_dispatch:
  schedule:
    # Run daily at 2 AM UTC
    - cron: "0 2 * * *"

jobs:
  sync-files:
    name: Sync files from training-material
    runs-on: ubuntu-latest
    if: github.repository_owner == 'galaxyproject'
    permissions:
      contents: write
      pull-requests: write
    steps:
      - name: Checkout current repository
        uses: actions/checkout@v4
        with:
          fetch-depth: 0

      - name: Download files from training-material
        run: |
          # Download the YAML files directly from GitHub's raw content
          curl -o content/CONTRIBUTORS.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/CONTRIBUTORS.yaml
          curl -o content/ORGANISATIONS.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/ORGANISATIONS.yaml
          curl -o content/GRANTS.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/GRANTS.yaml
          curl -o content/schema-contributors.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/bin/schema-contributors.yaml
          curl -o content/schema-grants.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/bin/schema-grants.yaml
          curl -o content/schema-organisations.yaml https://raw.githubusercontent.com/galaxyproject/training-material/main/bin/schema-organisations.yaml

      - name: Check for changes
        id: check-changes
        run: |
          if git diff --quiet content/CONTRIBUTORS.yaml content/ORGANISATIONS.yaml content/GRANTS.yaml content/schema-contributors.yaml content/schema-grants.yaml content/schema-organisations.yaml; then
            echo "changed=false" >> $GITHUB_OUTPUT
            echo "No changes detected in the files."
          else
            echo "changed=true" >> $GITHUB_OUTPUT
            echo "Changes detected in the files."
          fi

      - name: Create Pull Request
        if: steps.check-changes.outputs.changed == 'true'
        uses: peter-evans/create-pull-request@v6
        with:
          token: ${{ secrets.GITHUB_TOKEN }}
          commit-message: |
            Sync files from galaxyproject/training-material
            
            - Update CONTRIBUTORS.yaml
            - Update ORGANISATIONS.yaml
            - Update GRANTS.yaml
            - Update schema-contributors.yaml
            - Update schema-grants.yaml
            - Update schema-organisations.yaml
          title: 'Sync: Update files from training-material'
          body: |
            This PR automatically syncs the following files from [galaxyproject/training-material](https://github.com/galaxyproject/training-material):
            
            - `CONTRIBUTORS.yaml`
            - `ORGANISATIONS.yaml`
            - `GRANTS.yaml`
            - `schema-contributors.yaml`
            - `schema-grants.yaml`
            - `schema-organisations.yaml`
            
            Please review the changes and merge if everything looks correct.
          branch: sync/training-material
          delete-branch: true
          labels: automated, sync

Last fetched: