Skip to content

Commit

Permalink
merge
Browse files Browse the repository at this point in the history
  • Loading branch information
volodymyr-basiuk committed Dec 24, 2024
2 parents b86a298 + 3062fec commit d1e0cff
Show file tree
Hide file tree
Showing 111 changed files with 6,416 additions and 680 deletions.
2 changes: 1 addition & 1 deletion .env-ui.sample
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ ISSUER_UI_BUILD_TAG=
ISSUER_UI_WARNING_MESSAGE=
ISSUER_UI_IPFS_GATEWAY_URL=https://ipfs-proxy-cache.privado.id
ISSUER_UI_SCHEMA_EXPLORER_AND_BUILDER_URL=https://tools.privado.id
ISSUER_UI_SCHEMA_EXPLORER_AND_BUILDER_URL=https://display-method-dev.privado.id
ISSUER_UI_DISPLAY_METHOD_BUILDER_URL=https://display-method-dev.privado.id
ISSUER_UI_INSECURE=false
17 changes: 11 additions & 6 deletions .github/workflows/delete_testing_env.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: Delete Helm Release

on: [delete]
on:
workflow_dispatch:
inputs:
branch:
description: 'Branch to target'
required: true

env:
BRANCH_NAME: ${{ github.event.ref }}
BRANCH_NAME: ${{ github.event.inputs.branch }}

jobs:
delete:
Expand All @@ -24,14 +29,14 @@ jobs:
echo "Extracted URL: $url"
echo "::set-output name=url::$url"
- name: Cambiar contexto de kubectl
- name: change k3s context
run: |
kubectl config use-context k3s
- name: Verificar conexión al clúster
- name: check if the cluster exists
run: kubectl cluster-info

- name: Check if helm chart exists
- name: check if helm chart exists
id: helm_check
run: |
result=$(helm list --namespace "${{ steps.extract-url.outputs.url }}" -q | grep "^${{ steps.extract-url.outputs.url }}$" || echo 'not_found')
Expand All @@ -48,7 +53,7 @@ jobs:
overrule_existing_kubeconfig: "true"
if: steps.helm_check.outputs.result != 'not_found'

- name: "Delete namespace"
- name: "delete namespace"
run: |
kubectl delete namespace ${{ env.BRANCH_NAME }}
if: steps.helm_check.outputs.result != 'not_found'
4 changes: 2 additions & 2 deletions .github/workflows/deploy_testing_env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,12 +114,12 @@ jobs:
exec: helm install "${{ steps.extract-url.outputs.url }}" --create-namespace ./k8s/helm --wait --atomic --timeout 5m --namespace="${{ steps.extract-url.outputs.url }}" --values=./k8s/helm/values.yaml --set apidomain="${{ env.API_DOMAIN }}" --set uidomain="${{ env.UI_DOMAIN }}" --set privateKey=${{ secrets.ISSUER_NODE_TESTING_PRIVATE_KEY }} --set ingressEnabled="true" --set vaultpwd="foo" --set issuerUiInsecure=true --set issuerResolverFile="${{ secrets.ISSUER_NODE_TESTING_ISSUER_RESOLVER_FILE }}" --set issuernode_repository_image="${{ env.ISSUER_NODE_API_IMAGE }}" --set issuernode_repository_tag="${{ steps.version.outputs.VERSION }}" --set issuernode_ui_repository_image="${{ env.ISSUER_NODE_UI_IMAGE }}" --set issuernode_ui_repository_tag="${{ steps.version.outputs.VERSION }}"
kubeconfig: "${{ secrets.KUBECONFIG }}"
overrule_existing_kubeconfig: "true"
if: steps.helm_check.outputs.result == 'not_found'
if: steps.helm_check.outputs.result == 'not_found' && steps.extract-url.outputs.url != ''

- name: "Update helm chart"
uses: WyriHaximus/[email protected]
with:
exec: helm upgrade "${{ steps.extract-url.outputs.url }}" ./k8s/helm/ --wait --atomic --timeout 5m --namespace="${{ steps.extract-url.outputs.url }}" --values=./k8s/helm/values.yaml --set apidomain="${{ env.API_DOMAIN }}" --set uidomain="${{ env.UI_DOMAIN }}" --set privateKey=${{ secrets.ISSUER_NODE_TESTING_PRIVATE_KEY }} --set ingressEnabled="true" --set vaultpwd="foo" --set issuerUiInsecure=true --set issuerResolverFile="${{ secrets.ISSUER_NODE_TESTING_ISSUER_RESOLVER_FILE }}" --set issuernode_repository_image="${{ env.ISSUER_NODE_API_IMAGE }}" --set issuernode_repository_tag="${{ steps.version.outputs.VERSION }}" --set issuernode_ui_repository_image="${{ env.ISSUER_NODE_UI_IMAGE }}" --set issuernode_ui_repository_tag="${{ steps.version.outputs.VERSION }}"
kubeconfig: "${{ secrets.KUBECONFIG }}"
overrule_existing_kubeconfig: "true"
if: steps.helm_check.outputs.result != 'not_found'
if: steps.helm_check.outputs.result != 'not_found' && steps.extract-url.outputs.url != ''
Loading

0 comments on commit d1e0cff

Please sign in to comment.