From ff8ac33aa1258d97a4232ddd89dfc5a3e1513103 Mon Sep 17 00:00:00 2001 From: Stephan Egli Date: Wed, 23 Nov 2022 13:00:59 +0100 Subject: [PATCH] Deploy fe: `cd6e799` * Includes ability to apply configuration at runtime * Apply changes on qa * Apply changes on production --- .github/workflows/reusable.build-deploy.yml | 1 - .github/workflows/scicat-fe.yml | 5 +- frontend | 2 +- helm_configs/frontend/development/config.json | 132 ++++++++ .../frontend/development/environment.ts | 77 ----- helm_configs/frontend/development/values.yaml | 4 - helm_configs/frontend/help.component.html | 97 ------ helm_configs/frontend/login.component.html | 75 ----- helm_configs/frontend/production/config.json | 132 ++++++++ .../frontend/production/environment.ts | 77 ----- helm_configs/frontend/production/values.yaml | 4 - helm_configs/frontend/qa/config.json | 132 ++++++++ helm_configs/frontend/qa/environment.ts | 77 ----- helm_configs/frontend/qa/values.yaml | 4 - helm_configs/frontend/styles.scss | 305 ------------------ helm_configs/frontend/values.yaml | 46 ++- 16 files changed, 416 insertions(+), 754 deletions(-) create mode 100644 helm_configs/frontend/development/config.json delete mode 100644 helm_configs/frontend/development/environment.ts delete mode 100644 helm_configs/frontend/help.component.html delete mode 100644 helm_configs/frontend/login.component.html create mode 100644 helm_configs/frontend/production/config.json delete mode 100644 helm_configs/frontend/production/environment.ts create mode 100644 helm_configs/frontend/qa/config.json delete mode 100644 helm_configs/frontend/qa/environment.ts delete mode 100644 helm_configs/frontend/styles.scss diff --git a/.github/workflows/reusable.build-deploy.yml b/.github/workflows/reusable.build-deploy.yml index c951a55..0072c04 100644 --- a/.github/workflows/reusable.build-deploy.yml +++ b/.github/workflows/reusable.build-deploy.yml @@ -135,7 +135,6 @@ jobs: namespace: '${{ inputs.namespace_prefix }}${{ inputs.environment }}' chart: '${{ inputs.helm_chart }}' helm: helm3 - timeout: 10m values: | ciRepository: ${{ inputs.registry }}/${{ inputs.image_name }} ciTag: ${{ inputs.tag }} diff --git a/.github/workflows/scicat-fe.yml b/.github/workflows/scicat-fe.yml index 268fb08..2e25dcd 100644 --- a/.github/workflows/scicat-fe.yml +++ b/.github/workflows/scicat-fe.yml @@ -61,10 +61,7 @@ jobs: ciVars=$(cat < - - - Where is the official documentation? - - This is our documentation homepage. - Following the documentation link (blue button at top left) you will find detailed information for - Users, Developers, Operators and Ingestors - -

- - -

- - - How to get started - - The - Getting Started Guide - (PSI intranet only) gives a brief description on how to get started - using the data catalog. - -

- -

- - - Where is my data? - - Your data is stored and can be accessed by logging into {{ facility }} using - sftp to download a file. Alternatively, individual datafiles can be - downloaded by clicking on a datafiles tab for a given dataset, however this - is not recommended for large datasets - -

- -

- - - Where is my data? - - The data catalog keeps the *metadata* for your raw and derived datasets. - The actual files comprising the datasets are however stored outside the catalog. - Often the data will reside initially on disk. - The data catalog allows you to archive these files. In this way - the files on disk will be copied to tape and can be retrieved later to - a location of your choice. Here are the - details on the archive and retrieve workflows see - -

- -

- - - How can I publish a dataset? - - Select datasets in the dataset table and add to Cart. Once in - Cart, click Publish and follow instructions. - -

- -

- - - Ingest Manual - - The - Ingest Manual - (PSI intranet only) provides detailed information on how to - make your data available to the catalog as well as archiving - and retrieval of datasets. - -

- -

- - - - Where are my proposals? - - - Once logged in, you can see your proposals at - Proposals - -

- -

- - - - Where are my samples? - - - Once logged in, you can see your samples at - Samples - -

diff --git a/helm_configs/frontend/login.component.html b/helm_configs/frontend/login.component.html deleted file mode 100644 index 9a2ed1a..0000000 --- a/helm_configs/frontend/login.component.html +++ /dev/null @@ -1,75 +0,0 @@ - diff --git a/helm_configs/frontend/production/config.json b/helm_configs/frontend/production/config.json new file mode 100644 index 0000000..b984e99 --- /dev/null +++ b/helm_configs/frontend/production/config.json @@ -0,0 +1,132 @@ +{ + "lbBaseURL": "https://dacat.psi.ch", + "accessTokenPrefix": "", + "archiveWorkflowEnabled": true, + "retrieveDestinations": [ + { + "option": "PSI" + }, + { + "option": "PSI-RA" + } + ], + "externalAuthEndpoint": null, + "editMetadataEnabled": false, + "editSampleEnabled": false, + "editPublishedData": true, + "scienceSearchEnabled": true, + "facility": "PSI", + "multipleDownloadEnabled": false, + "shoppingCartEnabled": true, + "shoppingCartOnHeader": true, + "ingestManual": "http://melanie.gitpages.psi.ch/SciCatPages/", + "gettingStarted": "http://melanie.gitpages.psi.ch/SciCatPages/SciCatGettingStartedSLSSummary.pdf", + "jupyterHubUrl": "https://jupyterhub.apps.ocp4a.psi.ch/hub/login", + "riotBaseUrl": null, + "datasetReduceEnabled": false, + "fileColorEnabled": false, + "jsonMetadataEnabled": true, + "localColumns": [ + { + "name": "select", + "order": 0, + "type": "standard", + "enabled": true + }, + { + "name": "datasetName", + "order": 1, + "type": "standard", + "enabled": true + }, + { + "name": "runNumber", + "order": 2, + "type": "custom", + "enabled": false + }, + { + "name": "sourceFolder", + "order": 3, + "type": "standard", + "enabled": true + }, + { + "name": "size", + "order": 4, + "type": "standard", + "enabled": true + }, + { + "name": "creationTime", + "order": 5, + "type": "standard", + "enabled": true + }, + { + "name": "type", + "order": 6, + "type": "standard", + "enabled": true + }, + { + "name": "image", + "order": 7, + "type": "standard", + "enabled": false + }, + { + "name": "metadata", + "order": 8, + "type": "standard", + "enabled": false + }, + { + "name": "proposalId", + "order": 9, + "type": "standard", + "enabled": true + }, + { + "name": "ownerGroup", + "order": 10, + "type": "standard", + "enabled": true + }, + { + "name": "dataStatus", + "order": 11, + "type": "standard", + "enabled": true + } + ], + "logbookEnabled": false, + "metadataPreviewEnabled": false, + "maxDirectDownloadSize": 5000000000, + "multipleDownloadAction": null, + "searchSamples": true, + "sftpHost": null, + "tableSciDataEnabled": false, + "shareEnabled": true, + "searchPublicDataEnabled": true, + "landingPage": "doi.psi.ch/detail/", + "fileDownloadEnabled": false, + "jobsEnabled": true, + "policiesEnabled": true, + "addDatasetEnabled": false, + "editDatasetSampleEnabled": false, + "scienceSearchUnitsEnabled": false, + "metadataStructure": "tree", + "loginFormEnabled": true, + "oAuth2Endpoints": [ + { + "displayText": "PSI account", + "displayImage": "../../../assets/images/keycloak_icon_256px.svg", + "authURL": "auth/keycloak" + } + ], + "helpMessages": { + "gettingStarted": "(PSI intranet only) gives a brief description on how to get started using the data catalog.", + "ingestManual": "(PSI intranet only) provides detailed information on how to make your data available to the catalog as well as archiving and retrieval of datasets." + } +} diff --git a/helm_configs/frontend/production/environment.ts b/helm_configs/frontend/production/environment.ts deleted file mode 100644 index b73ac95..0000000 --- a/helm_configs/frontend/production/environment.ts +++ /dev/null @@ -1,77 +0,0 @@ -import { TableColumn } from "state-management/models"; - -// The file contents for the current environment will overwrite these during build. -// The build system defaults to the dev environment which uses `environment.ts`, but if you do -// `ng build --env=prod` then `environment.prod.ts` will be used instead. -// The list of which env maps to which file can be found in `angular-cli.json`. - -export const environment = { - production: true, - lbBaseURL: "https://dacat.psi.ch", - archiveWorkflowEnabled: true, - retrieveDestinations: [ - {option: "PSI"}, - {option:"PSI-RA"} - ], - externalAuthEndpoint: "/auth/msad", - editMetadataEnabled: false, - editSampleEnabled: false, - editPublishedData: true, - scienceSearchEnabled: true, - disabledDatasetColumns: [], - facility: "PSI", - multipleDownloadEnabled: false, - shoppingCartEnabled: true, - shoppingCartOnHeader: true, - columnSelectEnabled: true, - ingestManual: "http://melanie.gitpages.psi.ch/SciCatPages/", - gettingStarted: "http://melanie.gitpages.psi.ch/SciCatPages/SciCatGettingStartedSLSSummary.pdf", - jupyterHubUrl: "", - fileserverBaseURL: null, - synapseBaseUrl: null, - riotBaseUrl: null, - datasetReduceEnabled: false, - fileColorEnabled: false, - jsonMetadataEnabled: true, - localColumns: [ - { name: "select", order: 0, type: "standard", enabled: true }, - { name: "datasetName", order: 1, type: "standard", enabled: true }, - { name: "runNumber", order: 2, type: "custom", enabled: false }, - { name: "sourceFolder", order: 3, type: "standard", enabled: true }, - { name: "size", order: 4, type: "standard", enabled: true }, - { name: "creationTime", order: 5, type: "standard", enabled: true }, - { name: "type", order: 6, type: "standard", enabled: true }, - { name: "image", order: 7, type: "standard", enabled: false }, - { name: "metadata", order: 8, type: "standard", enabled: false }, - { name: "proposalId", order: 9, type: "standard", enabled: true }, - { name: "ownerGroup", order: 10, type: "standard", enabled: true }, - { name: "dataStatus", order: 11, type: "standard", enabled: true }, - // { name: "derivedDatasetsNum", order: 12, type: "standard", enabled: false } - ] as TableColumn[], - logbookEnabled: false, - metadataPreviewEnabled: false, - maxDirectDownloadSize: 5000000000, - multipleDownloadAction: null, - searchProposals: true, - searchSamples: true, - sftpHost: null, - tableSciDataEnabled: false, - shareEnabled: true, - userProfileImageEnabled: true, - searchPublicDataEnabled: true, - landingPage: "doi.psi.ch/detail/", - fileDownloadEnabled: false, - jobsEnabled: true, - policiesEnabled: true, - addDatasetEnabled: false, - editDatasetSampleEnabled: false, - scienceSearchUnitsEnabled: false, - metadataStructure: "tree", - userNamePromptEnabled: false, - loginFormEnabled: true, - oAuth2Endpoints: [{ - displayText: "PSI account", displayImage: - "../../../assets/images/keycloak_icon_256px.svg", authURL: - "auth/keycloak" - }] -}; diff --git a/helm_configs/frontend/production/values.yaml b/helm_configs/frontend/production/values.yaml index 9accab8..6677ced 100644 --- a/helm_configs/frontend/production/values.yaml +++ b/helm_configs/frontend/production/values.yaml @@ -1,5 +1 @@ -envFile: environment.prod.ts - -envValue: production - host: discovery.psi.ch diff --git a/helm_configs/frontend/qa/config.json b/helm_configs/frontend/qa/config.json new file mode 100644 index 0000000..8092815 --- /dev/null +++ b/helm_configs/frontend/qa/config.json @@ -0,0 +1,132 @@ +{ + "lbBaseURL": "https://dacat-qa.psi.ch", + "accessTokenPrefix": "", + "archiveWorkflowEnabled": true, + "retrieveDestinations": [ + { + "option": "PSI" + }, + { + "option": "PSI-RA" + } + ], + "externalAuthEndpoint": null, + "editMetadataEnabled": false, + "editSampleEnabled": false, + "editPublishedData": true, + "scienceSearchEnabled": true, + "facility": "PSI", + "multipleDownloadEnabled": false, + "shoppingCartEnabled": true, + "shoppingCartOnHeader": true, + "ingestManual": "http://melanie.gitpages.psi.ch/SciCatPages/", + "gettingStarted": "http://melanie.gitpages.psi.ch/SciCatPages/SciCatGettingStartedSLSSummary.pdf", + "jupyterHubUrl": "https://jupyterhub.apps.ocp4a.psi.ch/hub/login", + "riotBaseUrl": null, + "datasetReduceEnabled": false, + "fileColorEnabled": false, + "jsonMetadataEnabled": true, + "localColumns": [ + { + "name": "select", + "order": 0, + "type": "standard", + "enabled": true + }, + { + "name": "datasetName", + "order": 1, + "type": "standard", + "enabled": true + }, + { + "name": "runNumber", + "order": 2, + "type": "custom", + "enabled": false + }, + { + "name": "sourceFolder", + "order": 3, + "type": "standard", + "enabled": true + }, + { + "name": "size", + "order": 4, + "type": "standard", + "enabled": true + }, + { + "name": "creationTime", + "order": 5, + "type": "standard", + "enabled": true + }, + { + "name": "type", + "order": 6, + "type": "standard", + "enabled": true + }, + { + "name": "image", + "order": 7, + "type": "standard", + "enabled": false + }, + { + "name": "metadata", + "order": 8, + "type": "standard", + "enabled": false + }, + { + "name": "proposalId", + "order": 9, + "type": "standard", + "enabled": true + }, + { + "name": "ownerGroup", + "order": 10, + "type": "standard", + "enabled": true + }, + { + "name": "dataStatus", + "order": 11, + "type": "standard", + "enabled": true + } + ], + "logbookEnabled": false, + "metadataPreviewEnabled": false, + "maxDirectDownloadSize": 5000000000, + "multipleDownloadAction": null, + "searchSamples": true, + "sftpHost": null, + "tableSciDataEnabled": false, + "shareEnabled": true, + "searchPublicDataEnabled": true, + "landingPage": "doi2.psi.ch/detail/", + "fileDownloadEnabled": false, + "jobsEnabled": true, + "policiesEnabled": true, + "addDatasetEnabled": false, + "editDatasetSampleEnabled": false, + "scienceSearchUnitsEnabled": false, + "metadataStructure": "tree", + "loginFormEnabled": true, + "oAuth2Endpoints": [ + { + "displayText": "PSI account", + "displayImage": "../../../assets/images/keycloak_icon_256px.svg", + "authURL": "auth/keycloak" + } + ], + "helpMessages": { + "gettingStarted": "(PSI intranet only) gives a brief description on how to get started using the data catalog.", + "ingestManual": "(PSI intranet only) provides detailed information on how to make your data available to the catalog as well as archiving and retrieval of datasets." + } +} diff --git a/helm_configs/frontend/qa/environment.ts b/helm_configs/frontend/qa/environment.ts deleted file mode 100644 index 3fb54e0..0000000 --- a/helm_configs/frontend/qa/environment.ts +++ /dev/null @@ -1,77 +0,0 @@ -import { TableColumn } from "state-management/models"; - -// The file contents for the current environment will overwrite these during build. -// The build system defaults to the dev environment which uses `environment.ts`, but if you do -// `ng build --env=qa` then `environment.qa.ts` will be used instead. -// The list of which env maps to which file can be found in `angular-cli.json`. - -export const environment = { - production: true, - lbBaseURL: "https://dacat-qa.psi.ch", - archiveWorkflowEnabled: true, - retrieveDestinations: [ - {option: "PSI"}, - {option:"PSI-RA"} - ], - externalAuthEndpoint: "/auth/msad", - editMetadataEnabled: false, - editSampleEnabled: false, - editPublishedData: true, - scienceSearchEnabled: true, - disabledDatasetColumns: [], - facility: "PSI", - multipleDownloadEnabled: false, - shoppingCartEnabled: true, - shoppingCartOnHeader: true, - columnSelectEnabled: true, - ingestManual: "http://melanie.gitpages.psi.ch/SciCatPages/", - gettingStarted: "http://melanie.gitpages.psi.ch/SciCatPages/SciCatGettingStartedSLSSummary.pdf", - jupyterHubUrl: "", - fileserverBaseURL: null, - synapseBaseUrl: null, - riotBaseUrl: null, - datasetReduceEnabled: false, - fileColorEnabled: false, - jsonMetadataEnabled: true, - localColumns: [ - { name: "select", order: 0, type: "standard", enabled: true }, - { name: "datasetName", order: 1, type: "standard", enabled: true }, - { name: "runNumber", order: 2, type: "custom", enabled: true }, - { name: "sourceFolder", order: 3, type: "standard", enabled: true }, - { name: "size", order: 4, type: "standard", enabled: true }, - { name: "creationTime", order: 5, type: "standard", enabled: true }, - { name: "type", order: 6, type: "standard", enabled: true }, - { name: "image", order: 7, type: "standard", enabled: false }, - { name: "metadata", order: 8, type: "standard", enabled: false }, - { name: "proposalId", order: 9, type: "standard", enabled: true }, - { name: "ownerGroup", order: 10, type: "standard", enabled: true }, - { name: "dataStatus", order: 11, type: "standard", enabled: true }, - // { name: "derivedDatasetsNum", order: 12, type: "standard", enabled: false } - ] as TableColumn[], - logbookEnabled: false, - metadataPreviewEnabled: false, - maxDirectDownloadSize: 5000000000, - multipleDownloadAction: null, - searchProposals: true, - searchSamples: true, - sftpHost: null, - tableSciDataEnabled: false, - shareEnabled: true, - userProfileImageEnabled: true, - searchPublicDataEnabled: true, - landingPage: "doi2.psi.ch/detail/", - fileDownloadEnabled: false, - jobsEnabled: true, - policiesEnabled: true, - addDatasetEnabled: false, - editDatasetSampleEnabled: false, - scienceSearchUnitsEnabled: false, - metadataStructure: "tree", - userNamePromptEnabled: false, - loginFormEnabled: true, - oAuth2Endpoints: [{ - displayText: "PSI account", displayImage: - "../../../assets/images/keycloak_icon_256px.svg", authURL: - "auth/keycloak" - }] -}; diff --git a/helm_configs/frontend/qa/values.yaml b/helm_configs/frontend/qa/values.yaml index 79e9b0d..981c166 100644 --- a/helm_configs/frontend/qa/values.yaml +++ b/helm_configs/frontend/qa/values.yaml @@ -1,5 +1 @@ -envFile: environment.qa.ts - -envValue: qa - host: discovery-qa.psi.ch diff --git a/helm_configs/frontend/styles.scss b/helm_configs/frontend/styles.scss deleted file mode 100644 index 9cac738..0000000 --- a/helm_configs/frontend/styles.scss +++ /dev/null @@ -1,305 +0,0 @@ -// Custom Theming for Angular Material -// For more information: https://material.angular.io/guide/theming -@use '@angular/material' as mat; -@use "./app/app-theme" as app; -@use "./app/_layout/app-header/app-header-theme" as app-header; -@use "./app/datasets/batch-view/batch-view-theme" as batch-view; -@use "./app/datasets/dashboard/dashboard-theme" as dashboard; -@use "./app/datasets/datafiles/datafiles-theme" as datafiles; -@use "./app/datasets/dataset-detail/dataset-detail-theme" as dataset-detail; -@use "./app/datasets/dataset-details-dashboard/dataset-details-dashboard-theme" as dataset-details-dashboard; -@use "./app/datasets/dataset-lifecycle/dataset-lifecycle-theme" as dataset-lifecycle; -@use "./app/datasets/dataset-table/dataset-table-theme" as dataset-table; -@use "./app/datasets/dataset-table-settings/dataset-table-settings-theme" as dataset-table-settings; -@use "./app/datasets/reduce/reduce-theme" as reduce; -@use "./app/instruments/instrument-details/instrument-details-theme" as instrument-details; -@use "./app/logbooks/logbooks-detail/logbooks-detail-theme" as logbooks-detail; -@use "./app/logbooks/logbooks-table/logbooks-table-theme" as logbooks-table; -@use "./app/proposals/proposal-detail/proposal-detail-theme" as proposal-detail; -@use "./app/publisheddata/publisheddata-details/publisheddata-details-theme" as publisheddata-details; -@use "./app/samples/sample-dashboard/sample-dashboard-theme" as sample-dashboard; -@use "./app/samples/sample-detail/sample-detail-theme" as sample-detail; -@use "./app/shared/modules/breadcrumb/breadcrumb-theme" as breadcrumb; -@use "./app/shared/modules/error-page/error-page-theme" as error-page; -@use "./app/shared/modules/shared-table/shared-table-theme" as shared-table; -@use "./app/shared/modules/table/table-theme" as table; -@use "./app/users/user-settings/user-settings-theme" as user-settings; - -$custom-typography: mat.define-typography-config( - $font-family: '"Titillium Web", Calibri, sans-serif;', -); -// Include the common styles for Angular Material. We include this here so that you only -// have to load a single css file for Angular Material in your app. -// Be sure that you only ever include this mixin once! -@include mat.core($custom-typography); - -// Define the palettes for your theme using the Material Design palettes available in palette.scss -// (imported above). For each palette, you can optionally specify a default, lighter, and darker -// hue. Available color palettes: https://material.io/design/color/ - -$cyan: ( - 50: #f2f9fc, - 100: #e5f4f9, - 200: #cceaf4, - 300: #b2e0ee, - 400: #99d5e9, - 500: #7fcbe3, - 600: #66c1de, - 700: #4cb6d8, - 800: #32acd3, - 900: #19a2cd, - 1000: #0099c8, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 300: #000000, - 400: #000000, - 500: #000000, - 600: #ffffff, - 700: #ffffff, - 800: #ffffff, - 900: #ffffff, - 1000: #ffffff, - ), -); - -$navy: ( - 50: #f2f4f7, - 100: #e5eaef, - 200: #ccd6e0, - 400: #99adc1, - 600: #6684a3, - 800: #325b84, - 1000: #003366, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 400: #000000, - 600: #ffffff, - 800: #ffffff, - 1000: #ffffff, - ), -); - -$grass: ( - 50: #f9fbf2, - 100: #f4f8e5, - 200: #eaf2cc, - 400: #d6e599, - 600: #c1d866, - 800: #adcb32, - 1000: #99be00, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 400: #000000, - 600: #ffffff, - 800: #ffffff, - 1000: #ffffff, - ), -); - -$forest: ( - 50: #f2f7f5, - 100: #e5efec, - 200: #cce0da, - 400: #99c1b5, - 600: #66a390, - 800: #32846a, - 1000: #006646, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 400: #000000, - 600: #ffffff, - 800: #ffffff, - 1000: #ffffff, - ), -); - -$orange: ( - 50: #fff8f2, - 100: #fff2e5, - 200: #ffe5cc, - 400: #ffcb99, - 600: #ffb166, - 800: #ff9732, - 1000: #ff7d00, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 400: #000000, - 600: #ffffff, - 800: #ffffff, - 1000: #ffffff, - ), -); - -$purple: ( - 50: #f8f3f8, - 100: #f2e7f2, - 200: #e6d0e6, - 400: #cda1cd, - 600: #b472b4, - 800: #9b429b, - 1000: #821482, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 400: #000000, - 600: #ffffff, - 800: #ffffff, - 1000: #ffffff, - ), -); - -$grey: ( - 50: #f2f2f2, - 100: #e5e5e5, - 200: #cccccc, - 300: #b2b2b2, - 400: #999999, - 500: #7f7f7f, - contrast: ( - 50: #000000, - 100: #000000, - 200: #000000, - 300: #000000, - 400: #000000, - 500: #000000, - ), -); - -$yellow: ( - 50: #e1dc7d, - 100: #ffbe00, - 200: #d28c14, - contrast: ( - 50: #000000, - 100: #ffffff, - 200: #ffffff, - ), -); - -$red: ( - 50: #ff6e6e, - 100: #c81919, - 200: #820019, - contrast: ( - 50: #000000, - 100: #ffffff, - 200: #ffffff, - ), -); - -$primary: mat.define-palette($cyan, 1000, 400, 800); -$accent: mat.define-palette($grass, 1000, 400, 800); -$warn: mat.define-palette($red, 100, 50, 200); -$warn-2: mat.define-palette($yellow, 100, 50, 200); -$header-1: mat.define-palette($navy, 1000, 400, 800); -$header-2: mat.define-palette($forest, 1000, 400, 800); -$header-3: mat.define-palette($orange, 1000, 400, 800); -$header-4: mat.define-palette($purple, 1000, 400, 800); -$hover: mat.define-palette($grey, 500, 100, 300); - -@function custom-light-theme( - $primary, - $accent, - $warn, - $warn-2, - $header-1, - $header-2, - $header-3, - $header-4, - $hover -) { - @return map-merge( - mat.define-light-theme($primary, $accent, $warn), - ( - warn-2: $warn-2, - header-1: $header-1, - header-2: $header-2, - header-3: $header-4, - header-4: $header-4, - hover: $hover, - ) - ); -} - -// Create the theme object. A theme consists of configurations for individual -// theming systems such as "color" or "typography". -$theme: custom-light-theme( - $primary, - $accent, - $warn, - $warn-2, - $header-1, - $header-2, - $header-3, - $header-4, - $hover -); - -// Include theme styles for core and each component used in your app. -// Alternatively, you can import and @include the theme mixins for each component -// that you are using. -@include mat.all-component-themes($theme); -@include app.theme($theme); -@include app-header.theme($theme); -@include batch-view.theme($theme); -@include dashboard.theme($theme); -@include datafiles.theme($theme); -@include dataset-detail.theme($theme); -@include dataset-details-dashboard.theme($theme); -@include dataset-lifecycle.theme($theme); -@include dataset-table.theme($theme); -@include dataset-table-settings.theme($theme); -@include reduce.theme($theme); -@include instrument-details.theme($theme); -@include logbooks-detail.theme($theme); -@include logbooks-table.theme($theme); -@include proposal-detail.theme($theme); -@include publisheddata-details.theme($theme); -@include sample-dashboard.theme($theme); -@include sample-detail.theme($theme); -@include breadcrumb.theme($theme); -@include error-page.theme($theme); -@include shared-table.theme($theme); -@include table.theme($theme); -@include user-settings.theme($theme); - -/* You can add global styles to this file, and also import other style files */ - -html, -body { - height: 100vh; - margin: 0; - border: 0; - padding: 0; -} - -a { - text-decoration: none; -} - -a:hover { - cursor: pointer; -} - -.no-hover-effect.mat-button .mat-button-focus-overlay { - background-color: transparent; -} - -.snackbar-success { - background-color: mat.get-color-from-palette($primary, "default"); -} - -.snackbar-error { - background-color: mat.get-color-from-palette($warn, "default"); -} diff --git a/helm_configs/frontend/values.yaml b/helm_configs/frontend/values.yaml index 0da483a..078c117 100644 --- a/helm_configs/frontend/values.yaml +++ b/helm_configs/frontend/values.yaml @@ -33,49 +33,39 @@ volumes: - name: downloaddir emptyDir: {} -probeChecks: - initialDelaySeconds: 360 - configMaps: "{{ .Release.Name }}-cm": - environment.ts: "{{ .Values.ciVars.ENVIRONMENT }}" + config.json: "{{ .Values.ciVars.ENVIRONMENT }}" keycloak-icon-256px.svg: "{{ .Values.ciVars.KEYCLOAK_ICON }}" - styles.scss: "{{ .Values.ciVars.STYLES }}" - login.component.html: "{{ .Values.ciVars.LOGIN_COMPONENT }}" - help.component.html: "{{ .Values.ciVars.HELP_COMPONENT }}" initContainers: - name: install image: busybox command: - - wget - - "-O" - - "/download-dir/site.png" - - https://raw.githubusercontent.com/paulscherrerinstitute/scicat-ci/main/helm_configs/frontend/site.png + - "/bin/sh" + - -c + args: + - >- + wget + -O /download-dir/site.png + https://raw.githubusercontent.com/paulscherrerinstitute/scicat-ci/main/helm_configs/frontend/site.png; + wget + -O /download-dir/site-logo.png + https://raw.githubusercontent.com/paulscherrerinstitute/scicat-ci/main/helm_configs/frontend/site-logo.png; volumeMounts: - name: downloaddir mountPath: "/download-dir" volumeMounts: - name: config-volume - mountPath: /usr/src/app/src/environments/{{ .Values.envFile }} - subPath: environment.ts + mountPath: /usr/share/nginx/html/assets/config.json + subPath: config.json - name: config-volume - mountPath: /usr/src/app/src/assets/images/keycloak_icon_256px.svg + mountPath: /usr/share/nginx/html/assets/images/keycloak_icon_256px.svg subPath: keycloak-icon-256px.svg - - name: config-volume - mountPath: /usr/src/app/src/styles.scss - subPath: styles.scss - - name: config-volume - mountPath: /usr/src/app/src/app/users/login/login.component.html - subPath: login.component.html - - name: config-volume - mountPath: /usr/src/app/src/app/help/help/help.component.html - subPath: help.component.html - name: downloaddir - mountPath: /usr/src/app/src/assets/images/site.png + mountPath: /usr/share/nginx/html/assets/images/site.png subPath: site.png - -env: - - name: env - value: "{{ .Values.envValue }}" + - name: downloaddir + mountPath: /usr/share/nginx/html/assets/images/site-logo.png + subPath: site-logo.png