Skip to content
Snippets Groups Projects
Commit 802b497c authored by Xiao Gui's avatar Xiao Gui
Browse files

maint: move code snippet to experimental, remove legacy deployments

parent 41e77484
No related branches found
No related tags found
No related merge requests found
name: Trigger deploy on OKD
on:
workflow_call:
inputs:
FULL_DEPLOY_ID:
required: true
type: string
OKD_ENDPOINT:
required: true
type: string
OKD_PROJECT:
required: true
type: string
DEPLOY_ID:
required: false
type: string
BRANCH_NAME:
required: false
type: string
ROUTE_HOST:
required: false
type: string
ROUTE_PATH:
required: false
type: string
BUILD_TEXT:
required: false
type: string
secrets:
OKD_TOKEN:
required: true
env:
OC_TEMPLATE_NAME: 'siibra-explorer-branch-deploy-2'
jobs:
trigger-deploy:
runs-on: ubuntu-latest
steps:
- name: 'Login'
run: |
oc login ${{ inputs.OKD_ENDPOINT }} --token=${{ secrets.OKD_TOKEN }}
oc project ${{ inputs.OKD_PROJECT }}
- name: 'Login and import image'
run: |
if oc get dc ${{ inputs.FULL_DEPLOY_ID }}; then
# trigger redeploy if deployconfig exists already
echo "dc ${{ inputs.FULL_DEPLOY_ID }} already exist, redeploy..."
oc rollout latest dc/${{ inputs.FULL_DEPLOY_ID }}
else
# create new app if deployconfig does not yet exist
echo "dc ${{ inputs.FULL_DEPLOY_ID }} does not yet exist, create new app..."
if [[ -z "${{ inputs.ROUTE_HOST }}" ]]
then
echo "ROUTE_HOST not defined!"
exit 1
fi
if [[ -z "${{ inputs.ROUTE_PATH }}" ]]
then
echo "ROUTE_PATH not defined!"
exit 1
fi
if [[ -z "${{ inputs.BUILD_TEXT }}" ]]
then
echo "BUILD_TEXT not defined!"
exit 1
fi
if [[ -z "${{ inputs.BRANCH_NAME }}" ]]
then
echo "BRANCH_NAME not defined!"
exit 1
fi
oc new-app --template ${{ env.OC_TEMPLATE_NAME }} \
-p BRANCH_NAME=${{ inputs.BRANCH_NAME }} \
-p DEPLOY_ID=${{ inputs.DEPLOY_ID }} \
-p ROUTE_HOST=${{ inputs.ROUTE_HOST }} \
-p ROUTE_PATH=${{ inputs.ROUTE_PATH }} \
-p BUILD_TEXT=${{ inputs.BUILD_TEXT }}
fi
......@@ -141,18 +141,6 @@ jobs:
echo "SXPLR_VERSION=$SXPLR_VERSION"
echo "SXPLR_VERSION=$SXPLR_VERSION" >> $GITHUB_OUTPUT
trigger-deploy-master-prod:
if: ${{ needs.setting-vars.outputs.BRANCH_NAME == 'master' && success() }}
needs:
- build-docker-img
- setting-vars
uses: ./.github/workflows/deploy-on-okd.yml
with:
FULL_DEPLOY_ID: siibra-explorer-branch-deploy-2-prodpathviewer
OKD_ENDPOINT: https://okd.hbp.eu:443
OKD_PROJECT: interactive-viewer
secrets:
okd_token: ${{ secrets.OKD_PROD_SECRET }}
trigger-deploy-rc-rancher:
if: ${{ needs.setting-vars.outputs.BRANCH_NAME == 'staging' && success() }}
......@@ -192,33 +180,3 @@ jobs:
IMAGE_DIGEST: ${{ needs.build-docker-img.outputs.GIT_DIGEST }}
secrets:
KUBECONFIG: ${{ secrets.KUBECONFIG }}
trigger-deploy-staging-viewer-validation:
if: ${{ needs.setting-vars.outputs.BRANCH_NAME == 'staging' && success() }}
needs:
- build-docker-img
- setting-vars
uses: ./.github/workflows/deploy-on-okd.yml
with:
FULL_DEPLOY_ID: siibra-explorer-branch-deploy-2-stagingpathed
OKD_ENDPOINT: https://okd.hbp.eu:443
OKD_PROJECT: interactive-viewer
secrets:
okd_token: ${{ secrets.OKD_PROD_SECRET }}
# cluster offline
# TODO need to find new home for data-validation
# trigger-deploy-staging-data-validation:
# if: ${{ needs.setting-vars.outputs.BRANCH_NAME == 'staging' && success() }}
# needs:
# - build-docker-img
# - setting-vars
# uses: ./.github/workflows/deploy-on-okd.yml
# with:
# FULL_DEPLOY_ID: siibra-explorer-rc
# OKD_ENDPOINT: https://okd.jsc.hbp.eu:443
# OKD_PROJECT: siibra-explorer
# secrets:
# okd_token: ${{ secrets.OKD_JSC_TOKEN }}
\ No newline at end of file
......@@ -38,6 +38,7 @@
<mat-action-list class="overview-container">
<ng-template sxplrExperimentalFlag [experimental]="true">
<button mat-list-item
code-snippet
[routeParam]="{
......@@ -63,6 +64,7 @@
</ng-template>
</div>
</button>
</ng-template>
<!-- parcellation button -->
<button
......
......@@ -64,6 +64,7 @@
</ng-template>
<!-- code -->
<ng-template sxplrExperimentalFlag [experimental]="true">
<button mat-list-item
code-snippet
[routeParam]="{
......@@ -86,6 +87,7 @@
</ng-template>
</div>
</button>
</ng-template>
<!-- anchor -->
<ng-template [ngIf]="view.concept">
......
......@@ -25,6 +25,7 @@ import { BehaviorSubject } from "rxjs";
import { TPBRViewCmp } from "./TPBRView/TPBRView.component";
import { DialogModule } from "src/ui/dialogInfo";
import { CodeSnippet } from "src/atlasComponents/sapi/codeSnippets/codeSnippet.directive";
import { ExperimentalFlagDirective } from "src/experimental/experimental-flag.directive";
@NgModule({
imports: [
......@@ -46,6 +47,7 @@ import { CodeSnippet } from "src/atlasComponents/sapi/codeSnippets/codeSnippet.d
AtlasColorMapIntents,
TPBRViewCmp,
CodeSnippet,
ExperimentalFlagDirective,
],
declarations: [
EntryComponent,
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment