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

Support for Access Organizations #1382

Closed
trjstewart opened this issue Jan 13, 2022 · 2 comments · Fixed by #1961
Closed

Support for Access Organizations #1382

trjstewart opened this issue Jan 13, 2022 · 2 comments · Fixed by #1961
Labels
kind/enhancement Categorizes issue or PR as related to improving an existing feature. service/access Categorizes issue or PR as related to the Access service. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Milestone

Comments

@trjstewart
Copy link
Contributor

trjstewart commented Jan 13, 2022

Current Terraform and Cloudflare provider version

v3.7.0

Description

I ran into an issue a few weeks ago where I needed to get ahold of our access auth domain within Terraform and quickly found out that it wasn't currently possible. Being able to create and manage Access Organizations using this provider would be handy for managing our Cloudflare environment end-to-end with Terraform. The cloudflare-go library looks like it has support for it already.

I'd like to propose the creation of a new data source and resource, called cloudflare_access_organization.

I'll throw up a work in progress PR shortly. I've already written and have been using the data source internally for the past few weeks but need to add the resource and tests for both, and any nessicarry documentation.

Use cases

Management of Access Organizations using Terraform.

Potential Terraform configuration

data "cloudflare_access_organization" "default" {
  account_id = var.cloudflare_account_id
}

resource "cloudflare_access_organization" "default" {
  account_id  = var.cloudflare_account_id  
  name        = "Widget Corps Internal Applications"
  auth_domain = "widget.cloudflareaccess.com"

  login_design {
    background_color = "#c5ed1b"
    logo_path        = "https://example.com/logo.png"
    header_text      = "Widget Corps"
    footer_text      = "Widget Corps"
  }
}

References

No response

@trjstewart trjstewart added kind/enhancement Categorizes issue or PR as related to improving an existing feature. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 13, 2022
@jacobbednarz jacobbednarz added the service/access Categorizes issue or PR as related to the Access service. label Feb 16, 2022
@jacobbednarz jacobbednarz added triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels May 13, 2022
@nitrocode
Copy link

nitrocode commented Sep 8, 2022

I hit a similar issue when trying to get the account_id which is available using the REST API.

https://gist.github.com/nitrocode/c5be3e043623c26c4048d39a9c4dd9b7

Hope this helps people while we wait for a cloudflare data source to do the above

@github-actions
Copy link
Contributor

github-actions bot commented Nov 2, 2022

This functionality has been released in v3.27.0 of the Terraform Cloudflare Provider.

Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Categorizes issue or PR as related to improving an existing feature. service/access Categorizes issue or PR as related to the Access service. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
3 participants