GithubHelp home page GithubHelp logo

canonical / iam-bundle-integration Goto Github PK

View Code? Open in Web Editor NEW
1.0 4.0 1.0 28 KB

A Terraform Module for the Canonical Identity Platform Juju Bundle

License: Apache License 2.0

HCL 94.53% Makefile 5.47%
juju-bundle terraform

iam-bundle-integration's Introduction

Identity Platform Juju Bundle Terraform Module

Build Latest Release Juju Provider Terraform Conventional Commits License

This Identity Platform Juju bundle Terraform module aims to deploy the Identity Platform Juju Bundle via Terraform.

Getting started

Prerequisites

Make sure the following software and tools are installed and running in the local environment.

  • microk8s (v1.25.0+)
  • juju (3.1.0+)
  • terraform (v1.5.0+)

Deploy locally with Terraform

Create a target Juju model:

$ juju add-model <juju model>

Make sure two ingresses (e.g. traefik-k8s) are deployed in the model, and the external ingress provides a Juju offer:

# Deploy external ingress
$ juju deploy traefik-k8s <external ingress app> --trust --channel <channel>

# Deploy internal ingress
$ juju deploy traefik-k8s <internal ingress app> --trust --channel <channel>

# Create the juju offer
$ juju offer <external ingress app>:ingress <offer name>

Because the bundle uses an external Idp provider (e.g. Microsoft Azure), it needs to provide additional variables for the module to run. More information about the Idp provider configuration can be found here. Please create a Terraform variable definition (.tfvars) file in the root directory as follows.

# vars.tfvars
model = <juju model>

idp_provider_config = {
  client_id           = <client id>
  provider            = <provider name>
  provider_id         = <provider id>
  microsoft_tenant_id = <tenant id> # if using Microsoft Azure
}

idp_provider_credentials = {
  client_secret = <client secret>
}

internal_ingress = {
  name     = <Juju app name of the internal ingress>
  endpoint = "ingress"
}

juju_offers = {
  external_ingress_offer = <Juju offer url provided by external ingress>
}

Run the following commands to deploy the bundle.

$ terraform init
$ terraform apply -var-file="./vars.tfvars"

Run juju switch <juju model> to switch to the target Juju model.

# Observe the status of the applications and integrations
$ juju status --relations

Deploy to the ProdStack 6 Cloud

Please refer to the deployment documentation to learn how to deploy the module to the ProdStack Cloud.

Terraform Module Specifications

Please refer to the module specifications to learn the module specifications.

Contributing

Please refer to the contribution documentation to learn how to contribute to the project.

iam-bundle-integration's People

Contributors

bencekov avatar canonical-iam avatar github-actions[bot] avatar wood-push-melon avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

wood-push-melon

iam-bundle-integration's Issues

test: provide testing strategies

The terraform module lacks testing strategies. There are several options dedicated to the terraform module testing:

We probably need to provide the following tests:

  • Unit tests
  • Integration tests
  • E2E tests - specifically for the after-deployment testing

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.