FINOS Legend GitLab Integrator
- FINOS
Channel | Revision | Published | Runs on |
---|---|---|---|
latest/stable | 35 | 14 Aug 2023 | |
latest/edge | 35 | 08 Aug 2023 |
juju deploy finos-legend-gitlab-integrator-k8s
Deploy Kubernetes operators easily with Juju, the Universal Operator Lifecycle Manager. Need a Kubernetes cluster? Install MicroK8s to create a full CNCF-certified Kubernetes system in under 60 seconds.
Platform:
charms.finos_legend_gitlab_integrator_k8s.v0.legend_gitlab
-
- Last updated 22 Oct 2021
- Revision Library version 0.4
Charm library formalizing FINOS GitLab relations.
Index
def
set_legend_gitlab_creds_in_relation_data(
relation_data,
creds,
validate_creds
)
Set connection data for GitLab in the provided relation data.
Arguments
Data of the relation to set the info into.
Whether or not to check the structure of the data.
Returns
True if the provided creds were successfully set.
def
set_legend_gitlab_redirect_uris_in_relation_data(
relation_data,
redirect_uris
)
Set redirect URI list for OAuth redirects in the provided relation data.
Arguments
list of strings of redirect URLs for this service.
Returns
True if the provided creds are of a valid structure, else False.
class LegendGitlabConsumer
Description
Class facilitating and formalizing interactions with the GitLab integrator. None
Methods
LegendGitlabConsumer. __init__( self , charm , relation_name )
LegendGitlabConsumer. get_legend_gitlab_creds( self , relation_id )
Get GitLab OAuth connection data from the provided relation.
Description
Args: relation_id: ID of the relation to fetch data from.
Returns: Dictionary with the following structure: { "client_id": "<client_id>", "client_secret": "<client_secret>" "openid_discovery_url": "<URL>", "gitlab_host": "<GitLab hostname or IP>", "gitlab_port": <port>, "gitlab_scheme": "<http/https>", "gitlab_host_cert_b64": "<base64 DER certificate>" }
Raises: TooManyRelatedAppsError if relation id is not provided and multiple relation of the same name are present. ValueError: if the GitLab creds are misformatted.
LegendGitlabConsumer. get_legend_redirect_uris( self , relation_id )
Get GitLab redirect URIs from the provided relation.
Description
Args: relation_id: ID of the relation to fetch data from.
Returns: List of strings of redirect URIs.
Raises: TooManyRelatedAppsError if relation id is not provided and multiple relation of the same name are present. ValueError: if the GitLab redirect URIs are misformatted.