Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ PUBLIC_QLEVER_UI_URL=https://catplus.swisscustodian.ch/default
PUBLIC_CATPLUS_ONTOLOGY_URL=https://sdsc-ordes.github.io/catplus-ontology/
PUBLIC_SWISSCAT_URL=https://www.epfl.ch/research/facilities/swisscat/
PUBLIC_SDSC_URL=https://www.datascience.ch/
PUBLIC_CHEMBOARD_GITHUB_URL=https://github.com/sdsc-ordes/catplus-chemboard.git
PUBLIC_CHEMBORD_GITHUB_URL=https://github.com/sdsc-ordes/catplus-chembord.git

# Qlever Access
QLEVER_API_URL=https://catplus.swisscustodian.ch/sparql/default/
Expand All @@ -16,7 +16,7 @@ AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=

# Sveltekit Configuration
BASE_PATH=/chemboard
BASE_PATH=/chembord
ORIGIN=http://localhost:3000
PROTOCOL_HEADER=x-forwarded-proto
ADDRESS_HEADER=True-Client-IP
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,5 @@ jobs:
# Only push the image if the event is a 'push' (to main or a tag).
push: ${{ github.event_name == 'push' }}
tags: |
ghcr.io/sdsc-ordes/catplus-chemboard:latest
ghcr.io/sdsc-ordes/catplus-chemboard:${{ github.sha }}
ghcr.io/sdsc-ordes/catplus-chembord:latest
ghcr.io/sdsc-ordes/catplus-chembord:${{ github.sha }}
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Catplus Chemboard
# Catplus Chembord

Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).

Expand All @@ -19,15 +19,15 @@ cp .env.example .env

Then let docker run the container with variables loaded from the env file:
```bash
docker run -p 3000:3000 --env-file .env ghcr.io/sdsc-ordes/catplus-chemboard:latest
docker run -p 3000:3000 --env-file .env ghcr.io/sdsc-ordes/catplus-chembord:latest
```

## Development Environment

### Pre-requisites

The development setup requires the following:
* nix
* nix
* just

Additionally, we recommend using direnv to automatically activate the development environment when entering the project directory.
Expand Down
2 changes: 1 addition & 1 deletion src/lib/components/Footer.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
</div>

<p class="text-sm text-surface-500 dark:text-surface-400">
Chemboard 2025
Chembord 2025
</p>

</footer>
4 changes: 2 additions & 2 deletions src/lib/components/Header.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
<a href="{base}/search" class="flex items-center mx-4 gap-x-2"><Search size={20} />Search</a>
<a href="{base}/data" class="flex items-center mx-4 gap-x-2"><Database size={20} />Data</a>
{/snippet}
<span class="text-2xl font-bold">HT Chemboard</span>
<span class="text-2xl font-bold">HT Chembord</span>
{#snippet trail()}
<a href="{publicConfig.PUBLIC_CHEMBOARD_GITHUB_URL}"
<a href="{publicConfig.PUBLIC_CHEMBORD_GITHUB_URL}"
target="_blank" rel="noopener" class="opacity-75 hover:opacity-100 transition-opacity">
<img
src="{base}/github-mark.png"
Expand Down
4 changes: 2 additions & 2 deletions src/lib/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ export const publicConfig = {
PUBLIC_RESULTS_PER_PAGE: parseInt(publicEnv.PUBLIC_RESULTS_PER_PAGE || process.env.PUBLIC_RESULTS_PER_PAGE),
PUBLIC_SWISSCAT_URL: publicEnv.PUBLIC_SWISSCAT_URL || process.env.PUBLIC_SWISSCAT_URL,
PUBLIC_SDSC_URL: publicEnv.PUBLIC_SDSC_URL || process.env.PUBLIC_SDSC_URL,
PUBLIC_CHEMBOARD_GITHUB_URL: publicEnv.PUBLIC_CHEMBOARD_GITHUB_URL || process.env.PUBLIC_CHEMBOARD_GITHUB_URL,
PUBLIC_CHEMBORD_GITHUB_URL: publicEnv.PUBLIC_CHEMBORD_GITHUB_URL || process.env.PUBLIC_CHEMBORD_GITHUB_URL,
}

export function validatePublicConfiguration(): void {
Expand All @@ -133,7 +133,7 @@ export function validatePublicConfiguration(): void {
'PUBLIC_RESULTS_PER_PAGE',
'PUBLIC_SWISSCAT_URL',
'PUBLIC_SDSC_URL',
'PUBLIC_CHEMBOARD_GITHUB_URL'
'PUBLIC_CHEMBORD_GITHUB_URL'
];

const missingVars: string[] = [];
Expand Down
2 changes: 1 addition & 1 deletion svelte.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const config = {
kit: {
adapter: adapter(),
paths: {
base: '/chemboard',
base: '/chembord',
},
csrf: {
checkOrigin: false
Expand Down
12 changes: 6 additions & 6 deletions tools/deploy/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# CatPlus ChemBoard Kubernetes Deployment
# CatPlus ChemBord Kubernetes Deployment

This directory contains Kubernetes manifests for deploying catplus-chemboard using [ytt](https://carvel.dev/ytt/).
This directory contains Kubernetes manifests for deploying catplus-chembord using [ytt](https://carvel.dev/ytt/).

## Quick Start

Expand Down Expand Up @@ -33,19 +33,19 @@ Define `values.yaml` for your deployment, for example:

#@data/values
---
name: catplus-chemboard
name: catplus-chembord
version: latest
namespace: chemboard
namespace: chembord

image:
repository: ghcr.io/sdsc-ordes/catplus-chemboard
repository: ghcr.io/sdsc-ordes/catplus-chembord
tag: latest
pullPolicy: Always

s3:
region: us-east-1
endpoint: https://s3.custom-endpoint.example.com
bucketName: catplus-chemboard-bucket
bucketName: catplus-chembord-bucket
accessKeyId: ''
secretAccessKey: ''

Expand Down
18 changes: 9 additions & 9 deletions tools/deploy/schema.yaml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#@data/values-schema
#@schema/desc "Deployment schema for the CAT+ ChemBoard frontend"
#@schema/desc "Deployment schema for the CAT+ ChemBord frontend"
---
name: 'catplus-chemboard'
name: 'catplus-chembord'
version: 'latest'
namespace: 'chemboard'
namespace: 'chembord'

image:
repository: 'ghcr.io/sdsc-ordes/catplus-chemboard'
repository: 'ghcr.io/sdsc-ordes/catplus-chembord'
tag: 'latest'
pullPolicy: 'Always'

Expand All @@ -27,8 +27,8 @@ service:
port: 80

app:
#@schema/desc "Base path for reverse proxy deployment (e.g., '/chemboard' for path-based routing). Leave empty for root deployment."
#@schema/example "/chemboard"
#@schema/desc "Base path for reverse proxy deployment (e.g., '/chembord' for path-based routing). Leave empty for root deployment."
#@schema/example "/chembord"
basePath: ""
#@schema/desc "Absolute url of the instance"
#@schema/example "http://localhost:3000"
Expand All @@ -46,8 +46,8 @@ app:
#@schema/example "https://www.datascience.ch/"
sdscUrl: ""
#@schema/desc "URL to SwissCat Project Page."
#@schema/example "https://github.com/sdsc-ordes/catplus-chemboard.git"
chemboardGithubUrl: ""
#@schema/example "https://github.com/sdsc-ordes/catplus-chembord.git"
chembordGithubUrl: ""
#@schema/desc "Results per page"
resultsPerPage: "10"
#@schema/desc "Catplus Ontology Homepage Url"
Expand All @@ -58,7 +58,7 @@ ingress:
#@schema/desc "Whether to create an Ingress resource"
enabled: true
#@schema/desc "Hostname for the ingress"
#@schema/example "chemboard.example.com"
#@schema/example "chembord.example.com"
host: ''
#@schema/desc "Path prefix for the ingress rule"
path: '/'
Expand Down
2 changes: 1 addition & 1 deletion tools/deploy/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ data:
RESULTS_PER_PAGE: #@ data.values.app.resultsPerPage
SWISSCAT_URL: #@ data.values.app.swisscatUrl
SDSC_URL: #@ data.values.app.sdscUrl
CHEMBOARD_GITHUB_URL: #@ data.values.app.chemboardGithubUrl
CHEMBORD_GITHUB_URL: #@ data.values.app.chembordGithubUrl
4 changes: 2 additions & 2 deletions tools/deploy/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ spec:
configMapKeyRef:
name: #@ data.values.name + "-config"
key: SWISSCAT_URL
- name: PUBLIC_CHEMBOARD_GITHUB_URL
- name: PUBLIC_CHEMBORD_GITHUB_URL
valueFrom:
configMapKeyRef:
name: #@ data.values.name + "-config"
key: CHEMBOARD_GITHUB_URL
key: CHEMBORD_GITHUB_URL
- name: PUBLIC_CATPLUS_ONTOLOGY_URL
valueFrom:
configMapKeyRef:
Expand Down
8 changes: 4 additions & 4 deletions tools/image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

ENV NODE_ENV=production
ENV PORT=3000
ENV BASE_PATH="/chemboard"
ENV ORIGIN="http://chemboard"
ENV BASE_PATH="/chembord"
ENV ORIGIN="http://chembord"

# Install pnpm
RUN npm install -g pnpm
Expand Down Expand Up @@ -45,13 +45,13 @@

# AWS/S3 Configuration - these can be overridden at runtime
ENV AWS_REGION=""
ENV AWS_ACCESS_KEY_ID=""

Check warning on line 48 in tools/image/Dockerfile

View workflow job for this annotation

GitHub Actions / build-and-push

Sensitive data should not be used in the ARG or ENV commands

SecretsUsedInArgOrEnv: Do not use ARG or ENV instructions for sensitive data (ENV "AWS_ACCESS_KEY_ID") More info: https://docs.docker.com/go/dockerfile/rule/secrets-used-in-arg-or-env/
ENV AWS_SECRET_ACCESS_KEY=""

Check warning on line 49 in tools/image/Dockerfile

View workflow job for this annotation

GitHub Actions / build-and-push

Sensitive data should not be used in the ARG or ENV commands

SecretsUsedInArgOrEnv: Do not use ARG or ENV instructions for sensitive data (ENV "AWS_SECRET_ACCESS_KEY") More info: https://docs.docker.com/go/dockerfile/rule/secrets-used-in-arg-or-env/
ENV S3_BUCKET_NAME=""
ENV AWS_S3_ENDPOINT=""

# Base path for reverse proxy deployment (e.g., '/chemboard' for path-based routing)
ENV BASE_PATH="/chemboard"
# Base path for reverse proxy deployment (e.g., '/chembord' for path-based routing)
ENV BASE_PATH="/chembord"

# Command to run the application
CMD ["node", "build/index.js"]
2 changes: 1 addition & 1 deletion tools/just/image.just
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ root_dir := `git rev-parse --show-toplevel`
ctr := env("CTR", "podman")

version := env("VERSION", "latest")
image := "ghcr.io/sdsc-ordes/catplus-chemboard:" + version
image := "ghcr.io/sdsc-ordes/catplus-chembord:" + version
image_dir := root_dir + "/tools/image"

# Default recipe to list all recipes.
Expand Down
2 changes: 1 addition & 1 deletion tools/just/manifests.just
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# manifests.just - Kubernetes manifests management for Cat+ Chemboard
# manifests.just - Kubernetes manifests management for Cat+ Chembord
set positional-arguments
set shell := ["bash", "-cue"]
root_dir := `git rev-parse --show-toplevel`
Expand Down
2 changes: 1 addition & 1 deletion tools/nix/flake.nix
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
description = "catplus-chemboard";
description = "catplus-chembord";

nixConfig = {
extra-substituters = [
Expand Down