Restoring access when an external service fails
На этой странице
Let’s say that in the “Shturval” platform you have connected an external service for authentication, for example, Keycloak or Blitz. There are situations when a failure may occur on the side of the external authentication service. In this case, it is possible to disable the external authentication service and restore access to the platform for all users.
To ensure that work in the platform is not interrupted if an external service fails, do the following:
Connect to the management cluster using kubeconfig received during platform installation. Kubeconfig can also be taken from the Control Plane of the
/etc/kubernetes/admin.confplatform node.Prepare a YAML file, for example, named shturval-auth.yaml and with an object manifest ShturvalServicePatch (PatchSSC) for application to specification (ssc)
shturval-auth. In PatchSSC, specifyfalsein theAUTH_IDP_ACTIVEparameter and set the application priority in theorderparameter, as in the example below.
Example ShturvalServicePatch
apiVersion: ops.shturval.tech/v1beta2
kind: ShturvalServicePatch
metadata:
name: shturval-auth-disable
spec:
shturvalServiceConfigName: shturval-auth
patchOrder: 1
customvalues:
AUTH_IDP_ACTIVE: false
Please note! The value of the patchOrder parameter in ShturvalServicePatch to disable the external provider must be less than in the applied ShturvalServicePatch with the connection configuration for the external authentication provider (keycloak, blitz).
- Apply the changes.
Command
kubectl apply -f SPECIFY-PATCHSSC-MANIFEST-FILE
An example manifest file name is shturval-auth-disable.yaml.
- Once the changes are applied, authentication should work correctly.