Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Azure to beta command #2291

Merged
merged 2 commits into from
Nov 5, 2024
Merged

Add Azure to beta command #2291

merged 2 commits into from
Nov 5, 2024

Conversation

mrsimonemms
Copy link
Contributor

@mrsimonemms mrsimonemms commented Sep 23, 2024

Description

Adds Azure support as a beta command.

Related Issue(s)

Fixes #

How to test

This assumes you're running the console, API and CLI in local debug mode.

  1. Create personal keys for our Terraform service principal for ARM_CLIENT_SECRET.
  2. Get the tenant ID for ARM_TENANT_ID.
  3. Get the Subscription ID for ARM_SUBSCRIPTION_ID.
  4. Get the Application (client) ID for ARM_CLIENT_ID.
  5. Set ARM_CLIENT_ID, ARM_CLIENT_SECRET, ARM_TENANT_ID and ARM_SUBSCRIPTION_ID envvars
  6. Run your desired command in the CLI

Example CLI commands:

Azure DNS

You will need to create a DNS Zone with your desired domain registered. I have the domains registered elsewhere and setup a subdomain in Azure (eg, azure.domain.com) and then setup an NS record on my domain registrar.

Azure puts everything in resource groups, which is a logical grouping of multiple resources. You will need to provide the name of that in --dns-azure-resource-group.

go mod tidy
go run . beta azure create \
  --alerts-email <your-email> \
  --github-org <github-org> \
  --domain-name <domain-name> \
  --gitops-template-branch sje/azure \
  --dns-azure-resource-group <dns-zone-resource-group>

Cloudflare

go mod tidy
go run . beta azure create \
  --alerts-email <your-email> \
  --github-org <github-org> \
  --domain-name <domain> \
  --gitops-template-branch sje/azure \
  --cluster-name <cluster-name> \
  --dns-provider cloudflare \
  --cloud-region <region> \
  --subdomain <cloudflare-subdomain>

@mrsimonemms mrsimonemms changed the title Sje/azure Add Azure to beta command Oct 29, 2024
@mrsimonemms mrsimonemms force-pushed the sje/azure branch 2 times, most recently from 4179d62 to 1a1ed1c Compare October 29, 2024 12:16
@mrsimonemms mrsimonemms marked this pull request as ready for review October 29, 2024 14:59
@mrsimonemms
Copy link
Contributor Author

This can be reviewed but will be in a failing state until the Kubefirst API changes are incorporated - I could do this now, but would rather wait until it's published to main

@fharper
Copy link
Contributor

fharper commented Nov 4, 2024

I tested it once and it's working fine for me. Keep in min that this implementation doesn't have workload clusters yet and it's specific to GitHub.

@mrsimonemms mrsimonemms merged commit 1a994b6 into main Nov 5, 2024
8 checks passed
@mrsimonemms mrsimonemms deleted the sje/azure branch November 5, 2024 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants