From 8e2a97ce308b481c81eb0945af3ca9972beedf78 Mon Sep 17 00:00:00 2001 From: Felix Hennig Date: Tue, 25 Feb 2025 13:00:55 +0100 Subject: [PATCH] make md and mdx files indent at 2 --- docs/.prettierrc | 6 + .../for-administrators/data-use-terms.mdx | 12 +- .../existing-preprocessing-pipelines.md | 4 +- .../for-administrators/sequence-reporting.md | 8 +- .../setup-with-k3d-and-nginx.mdx | 118 +++++----- .../setup-with-kubernetes.md | 216 +++++++++--------- .../docs/for-users/submit-sequences.md | 14 +- docs/src/content/docs/index.mdx | 52 ++--- .../docs/reference/helm-chart-config.mdx | 10 +- 9 files changed, 223 insertions(+), 217 deletions(-) diff --git a/docs/.prettierrc b/docs/.prettierrc index 1b5bd8dd9b..b52d8ff57d 100644 --- a/docs/.prettierrc +++ b/docs/.prettierrc @@ -13,6 +13,12 @@ "options": { "parser": "astro" } + }, + { + "files": ["*.md", "*.mdx"], + "options": { + "tabWidth": 2 + } } ] } diff --git a/docs/src/content/docs/for-administrators/data-use-terms.mdx b/docs/src/content/docs/for-administrators/data-use-terms.mdx index 8d16714201..471fd287b4 100644 --- a/docs/src/content/docs/for-administrators/data-use-terms.mdx +++ b/docs/src/content/docs/for-administrators/data-use-terms.mdx @@ -14,17 +14,17 @@ You can then enable data use terms like this: ```yaml dataUseTerms: - enabled: true + enabled: true ``` Optionally, you can provide links to pages where the data use terms are descripted: ```yaml dataUseTerms: - enabled: true - urls: - open: https://example.org/open - restricted: https://example.org/restricted + enabled: true + urls: + open: https://example.org/open + restricted: https://example.org/restricted ``` ## Disabling data use terms @@ -33,5 +33,5 @@ To disable data use terms, set `enabled` to `false`: ```yaml dataUseTerms: - enabled: false + enabled: false ``` diff --git a/docs/src/content/docs/for-administrators/existing-preprocessing-pipelines.md b/docs/src/content/docs/for-administrators/existing-preprocessing-pipelines.md index 4ca4b588ee..cdbb3010af 100644 --- a/docs/src/content/docs/for-administrators/existing-preprocessing-pipelines.md +++ b/docs/src/content/docs/for-administrators/existing-preprocessing-pipelines.md @@ -16,8 +16,8 @@ Given a nextclade dataset this pipeline uses [nextclade run](https://docs.nextst ```yaml preprocessing: - - configFile: - nextclade_dataset_name: nextstrain/mpox/all-clades + - configFile: + nextclade_dataset_name: nextstrain/mpox/all-clades ``` Additionally the pipeline performs checks on the metadata fields. The checks are defined by custom preprocessing functions in the `values.yaml` file. These checks can be applied to and customized for other metadata fields, see [Preprocessing Checks](https://github.com/loculus-project/loculus/blob/main/preprocessing/nextclade/README.md#preprocessing-checks) for more info. diff --git a/docs/src/content/docs/for-administrators/sequence-reporting.md b/docs/src/content/docs/for-administrators/sequence-reporting.md index 06b79dc843..1e6edd3427 100644 --- a/docs/src/content/docs/for-administrators/sequence-reporting.md +++ b/docs/src/content/docs/for-administrators/sequence-reporting.md @@ -9,10 +9,10 @@ You can enable it in the `values.yaml` by configuring the `sequenceFlagging` sec ```yaml sequenceFlagging: - github: - organization: pathoplexus - repository: curation_reports - issueTemplate: sequence-metadata-issue.md # (optional) + github: + organization: pathoplexus + repository: curation_reports + issueTemplate: sequence-metadata-issue.md # (optional) ``` Sequence reporting is done through GitHub issues. diff --git a/docs/src/content/docs/for-administrators/setup-with-k3d-and-nginx.mdx b/docs/src/content/docs/for-administrators/setup-with-k3d-and-nginx.mdx index 78eabaed23..e0cf105757 100644 --- a/docs/src/content/docs/for-administrators/setup-with-k3d-and-nginx.mdx +++ b/docs/src/content/docs/for-administrators/setup-with-k3d-and-nginx.mdx @@ -98,62 +98,62 @@ runDevelopmentMainDatabase: true runDevelopmentKeycloakDatabase: true website: - runtimeConfig: - public: - backendUrl: 'https://api./backend' - lapisUrlTemplate: 'https://api./%organism%' - keycloakUrl: 'https://auth.' + runtimeConfig: + public: + backendUrl: 'https://api./backend' + lapisUrlTemplate: 'https://api./%organism%' + keycloakUrl: 'https://auth.' auth: - verifyEmail: false - resetPasswordAllowed: false - registrationAllowed: true - smtp: null - identityProviders: null + verifyEmail: false + resetPasswordAllowed: false + registrationAllowed: true + smtp: null + identityProviders: null disableIngest: true disableEnaSubmission: true seqSets: - enabled: false + enabled: false secrets: - keycloak-admin: - type: raw - data: - initialAdminPassword: '' + keycloak-admin: + type: raw + data: + initialAdminPassword: '' organisms: - angelovirus: - schema: - organismName: 'Angelovirus' - metadata: - - name: country - type: string - initiallyVisible: true - - name: city - type: string - initiallyVisible: true - website: - tableColumns: - - country - - city - defaultOrder: descending - defaultOrderBy: country - preprocessing: - - version: 1 - image: ghcr.io/loculus-project/preprocessing-nextclade - args: - - 'prepro' - configFile: - log_level: DEBUG - genes: [] - batch_size: 100 - referenceGenomes: - nucleotideSequences: - - name: 'main' - sequence: 'NNN' # We are not performing alignment here, so this sequence doesn't matter - genes: [] + angelovirus: + schema: + organismName: 'Angelovirus' + metadata: + - name: country + type: string + initiallyVisible: true + - name: city + type: string + initiallyVisible: true + website: + tableColumns: + - country + - city + defaultOrder: descending + defaultOrderBy: country + preprocessing: + - version: 1 + image: ghcr.io/loculus-project/preprocessing-nextclade + args: + - 'prepro' + configFile: + log_level: DEBUG + genes: [] + batch_size: 100 + referenceGenomes: + nucleotideSequences: + - name: 'main' + sequence: 'NNN' # We are not performing alignment here, so this sequence doesn't matter + genes: [] ``` ## Step 4: Install and deploy @@ -300,20 +300,20 @@ Then, adapt `my-values.yaml` and add under the `secrets` key: ```yaml secrets: - database: - type: raw - data: - url: 'jdbc:postgresql://:/' - username: '' - password: '' - keycloak-database: - type: raw - data: - addr: '' - port: '' - database: '' - username: '' - password: '' + database: + type: raw + data: + url: 'jdbc:postgresql://:/' + username: '' + password: '' + keycloak-database: + type: raw + data: + addr: '' + port: '' + database: '' + username: '' + password: '' ``` To reinstall Loculus, execute: diff --git a/docs/src/content/docs/for-administrators/setup-with-kubernetes.md b/docs/src/content/docs/for-administrators/setup-with-kubernetes.md index 907ce24c9a..56e2b12afb 100644 --- a/docs/src/content/docs/for-administrators/setup-with-kubernetes.md +++ b/docs/src/content/docs/for-administrators/setup-with-kubernetes.md @@ -37,20 +37,20 @@ These details are configured in the `secrets` section of the `values.yaml` file. ```yaml secrets: - database: - type: raw - data: - url: 'jdbc:postgresql://loculus-database-service/loculus' - username: 'postgres' - password: 'password' - keycloak-database: - type: raw - data: - addr: 'loculus-keycloak-database-service' - database: 'keycloak' - username: 'postgres' - password: 'unsecure' - port: '5432' + database: + type: raw + data: + url: 'jdbc:postgresql://loculus-database-service/loculus' + username: 'postgres' + password: 'password' + keycloak-database: + type: raw + data: + addr: 'loculus-keycloak-database-service' + database: 'keycloak' + username: 'postgres' + password: 'unsecure' + port: '5432' ``` You can also use sealed secrets, see the [Sealed Secrets](#sealedsecret) section for more information. @@ -71,65 +71,65 @@ Here's an example of how the organism configuration might look: ```yaml organisms: - ebolavirus-sudan: - schema: - image: 'https://cdn.britannica.com/01/179201-050-FED1B381/filamentous-ebolavirus-particles-scanning-electron-micrograph-cell.jpg?w=400&h=300&c=crop' - organismName: 'Ebolavirus Sudan' - metadata: - - name: date - type: date - header: 'Collection Data' - - name: region - type: string - generateIndex: true - autocomplete: true - header: 'Collection Data' - - name: country - type: string - generateIndex: true - autocomplete: true - header: 'Collection Data' - - name: division - type: string - generateIndex: true - autocomplete: true - header: 'Collection Data' - - name: host - type: string - autocomplete: true - - name: pangoLineage - type: string - autocomplete: true - required: true - - name: insdcAccessionFull - type: string - displayName: INSDC accession - customDisplay: - type: link - url: 'https://www.ncbi.nlm.nih.gov/nuccore/__value__' - website: - tableColumns: - - country - - division - - date - - pangoLineage - defaultOrder: descending - defaultOrderBy: date - silo: - dateToSortBy: date - partitionBy: pangoLineage - preprocessing: - image: ghcr.io/loculus-project/preprocessing-dummy - args: - - '--watch' - warnings: true - errors: true - randomWarnError: true - referenceGenomes: - nucleotideSequences: - - name: 'main' - sequence: '[[URL:https://cov2tree.nyc3.cdn.digitaloceanspaces.com/reference.txt]]' - genes: [] + ebolavirus-sudan: + schema: + image: 'https://cdn.britannica.com/01/179201-050-FED1B381/filamentous-ebolavirus-particles-scanning-electron-micrograph-cell.jpg?w=400&h=300&c=crop' + organismName: 'Ebolavirus Sudan' + metadata: + - name: date + type: date + header: 'Collection Data' + - name: region + type: string + generateIndex: true + autocomplete: true + header: 'Collection Data' + - name: country + type: string + generateIndex: true + autocomplete: true + header: 'Collection Data' + - name: division + type: string + generateIndex: true + autocomplete: true + header: 'Collection Data' + - name: host + type: string + autocomplete: true + - name: pangoLineage + type: string + autocomplete: true + required: true + - name: insdcAccessionFull + type: string + displayName: INSDC accession + customDisplay: + type: link + url: 'https://www.ncbi.nlm.nih.gov/nuccore/__value__' + website: + tableColumns: + - country + - division + - date + - pangoLineage + defaultOrder: descending + defaultOrderBy: date + silo: + dateToSortBy: date + partitionBy: pangoLineage + preprocessing: + image: ghcr.io/loculus-project/preprocessing-dummy + args: + - '--watch' + warnings: true + errors: true + randomWarnError: true + referenceGenomes: + nucleotideSequences: + - name: 'main' + sequence: '[[URL:https://cov2tree.nyc3.cdn.digitaloceanspaces.com/reference.txt]]' + genes: [] ``` In this example, the configuration for the "ebolavirus-sudan" organism is defined. It includes schema settings, website display options, silo configuration, preprocessing details, and reference genome information. @@ -140,15 +140,15 @@ Your preprocessing pipeline can be customized for each organism. Currently, we u ```yaml preprocessing: - - version: 1 - image: ghcr.io/loculus-project/preprocessing-nextclade - args: - - 'prepro' - configFile: - log_level: DEBUG - nextclade_dataset_name: nextstrain/ebola/zaire - genes: [NP, VP35, VP40, GP, sGP, ssGP, VP30, VP24, L] - batch_size: 100 + - version: 1 + image: ghcr.io/loculus-project/preprocessing-nextclade + args: + - 'prepro' + configFile: + log_level: DEBUG + nextclade_dataset_name: nextstrain/ebola/zaire + genes: [NP, VP35, VP40, GP, sGP, ssGP, VP30, VP24, L] + batch_size: 100 ``` Additionally, the `tableColumns` section defines which metadata fields are shown as columns in the search results. @@ -161,15 +161,15 @@ In Loculus, sequence data from multi-segmented viruses is stored in accessioned ```yaml organisms: - cchf: - schema: - organismName: 'Crimean-Congo Hemorrhagic Fever Virus' - nucleotideSequences: [L, M, S] - metadata: - - name: length - type: int - header: 'Length' - perSegment: true + cchf: + schema: + organismName: 'Crimean-Congo Hemorrhagic Fever Virus' + nucleotideSequences: [L, M, S] + metadata: + - name: length + type: int + header: 'Length' + perSegment: true ``` Additionally, if you are using the preprocessing or ingest pipelines, `nucleotideSequences` must also be defined in those sections of the config. @@ -188,12 +188,12 @@ This is the simplest type of secret, it is just a key value pair. ```yaml secrets: - database: - type: raw - data: - url: 'jdbc:postgresql://loculus-database-service/loculus' - username: 'postgres' - password: 'password' + database: + type: raw + data: + url: 'jdbc:postgresql://loculus-database-service/loculus' + username: 'postgres' + password: 'password' ``` ### `sealedsecret` @@ -202,13 +202,13 @@ This is a sealed secret, it is encrypted and can only be decrypted by the cluste ```yaml secrets: - database: - type: sealedsecret - clusterWide: 'false' # If true the secret can be decrypted in any namespace, but must have been created with this setting enabled - encryptedData: - url: '[Encrypted Data]' - username: '[Encrypted Data]' - password: '[Encrypted Data]' + database: + type: sealedsecret + clusterWide: 'false' # If true the secret can be decrypted in any namespace, but must have been created with this setting enabled + encryptedData: + url: '[Encrypted Data]' + username: '[Encrypted Data]' + password: '[Encrypted Data]' ``` ### `autogen` @@ -217,10 +217,10 @@ This is a secret that is automatically generated by the helm chart. ```yaml secrets: - secretKey: - type: autogen - data: - myKey: '' + secretKey: + type: autogen + data: + myKey: '' ``` ## Ready to Deploy? diff --git a/docs/src/content/docs/for-users/submit-sequences.md b/docs/src/content/docs/for-users/submit-sequences.md index 88dec5bf0b..0cdd63cb62 100644 --- a/docs/src/content/docs/for-users/submit-sequences.md +++ b/docs/src/content/docs/for-users/submit-sequences.md @@ -39,13 +39,13 @@ To upload sequences through the HTTP API you will need to: 2. Retrieve an authentication JSON web token: see the [Authenticating via API guide](../authenticate-via-api/). 3. Identify the Group ID of your group: you can find it on the page of your group. 4. Send a POST request: - - The API path to use is: `//submit` - - Add your group ID to the query parameters: `?groupId=` - - If Data use Terms are configured for your Loculus instance, add `&dataUseTermsType=OPEN` for _open_ data use terms or `&dataUseTermsType=RESTRICTED&restrictedUntil=YYYY-MM-DD` (where `YYYY-MM-DD` refers to a date like 2025-01-31) for _restricted_ data use terms - with a date until when this restriction will be in place. If your Loculus instance doesn't use Data use Terms, you can leave out these settings. - - The header should contain - - `Authorization: Bearer ` - - `Content-Type: multipart/form-data` - - The request body should contain the FASTA and metadata TSV files with the keys `sequenceFile` and `metadataFile` + - The API path to use is: `//submit` + - Add your group ID to the query parameters: `?groupId=` + - If Data use Terms are configured for your Loculus instance, add `&dataUseTermsType=OPEN` for _open_ data use terms or `&dataUseTermsType=RESTRICTED&restrictedUntil=YYYY-MM-DD` (where `YYYY-MM-DD` refers to a date like 2025-01-31) for _restricted_ data use terms - with a date until when this restriction will be in place. If your Loculus instance doesn't use Data use Terms, you can leave out these settings. + - The header should contain + - `Authorization: Bearer ` + - `Content-Type: multipart/form-data` + - The request body should contain the FASTA and metadata TSV files with the keys `sequenceFile` and `metadataFile` Below you can see an example of submitting to the API with cURL (with open data use terms): diff --git a/docs/src/content/docs/index.mdx b/docs/src/content/docs/index.mdx index 4bf590275f..b18e926044 100644 --- a/docs/src/content/docs/index.mdx +++ b/docs/src/content/docs/index.mdx @@ -3,18 +3,18 @@ title: Learn about Loculus description: Loculus is a software package for microbial genome databases template: splash hero: - tagline: Loculus is open-source software that powers microbial genome databases - image: - file: ../../assets/db.webp - actions: - - text: Read more - link: ./introduction/what-is-loculus/ - icon: right-arrow - variant: primary - - text: View a demo instance - link: https://main.loculus.org - icon: external - variant: secondary + tagline: Loculus is open-source software that powers microbial genome databases + image: + file: ../../assets/db.webp + actions: + - text: Read more + link: ./introduction/what-is-loculus/ + icon: right-arrow + variant: primary + - text: View a demo instance + link: https://main.loculus.org + icon: external + variant: secondary --- import { CardGrid, LinkCard } from '@astrojs/starlight/components'; @@ -36,30 +36,30 @@ import members from '../../team.json'; ## Team

## Contact diff --git a/docs/src/content/docs/reference/helm-chart-config.mdx b/docs/src/content/docs/reference/helm-chart-config.mdx index e5b79270db..22bb1c09ef 100644 --- a/docs/src/content/docs/reference/helm-chart-config.mdx +++ b/docs/src/content/docs/reference/helm-chart-config.mdx @@ -46,11 +46,11 @@ Here's an example of a `lineageDefinitions` section: ```yaml lineageSystemDefinitions: - pangoLineage: # Lineage name to use in metadata fields - 1: https://example.org/lineage_defintions_v1.yaml # Definition per pipeline version - 2: https://example.org/lineage_defintions_v2.yaml - myLineage: - 1: ... + pangoLineage: # Lineage name to use in metadata fields + 1: https://example.org/lineage_defintions_v1.yaml # Definition per pipeline version + 2: https://example.org/lineage_defintions_v2.yaml + myLineage: + 1: ... ```