{"id":50886058,"url":"https://github.com/hops-ops/terraform-provider-openpanel","last_synced_at":"2026-06-15T17:02:23.174Z","repository":{"id":358603830,"uuid":"1241988937","full_name":"hops-ops/terraform-provider-openpanel","owner":"hops-ops","description":"Terraform provider for OpenPanel — manages Projects, Clients, and References via the OpenPanel /manage REST API.","archived":false,"fork":false,"pushed_at":"2026-05-18T06:55:51.000Z","size":105,"stargazers_count":0,"open_issues_count":3,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-18T07:37:45.445Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hops-ops.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":".github/CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-18T03:07:48.000Z","updated_at":"2026-05-18T06:55:56.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hops-ops/terraform-provider-openpanel","commit_stats":null,"previous_names":["hops-ops/terraform-provider-openpanel"],"tags_count":1,"template":false,"template_full_name":"hashicorp/terraform-provider-scaffolding-framework","purl":"pkg:github/hops-ops/terraform-provider-openpanel","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hops-ops%2Fterraform-provider-openpanel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hops-ops%2Fterraform-provider-openpanel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hops-ops%2Fterraform-provider-openpanel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hops-ops%2Fterraform-provider-openpanel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hops-ops","download_url":"https://codeload.github.com/hops-ops/terraform-provider-openpanel/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hops-ops%2Fterraform-provider-openpanel/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34372130,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-15T02:00:07.085Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-06-15T17:02:21.767Z","updated_at":"2026-06-15T17:02:23.167Z","avatar_url":"https://github.com/hops-ops.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Terraform Provider: OpenPanel\n\nA Terraform provider for [OpenPanel](https://openpanel.dev) — the\nself-hosted, open-source product analytics platform. Manages OpenPanel\n**Organizations**, **Projects**, **Clients**, and **References** via\nthe `/manage` REST API.\n\nUse this provider to:\n\n- Declaratively provision per-tenant Organizations and Projects from\n  CI / pull-requests rather than the OpenPanel dashboard.\n- Wire OpenPanel into a Crossplane-managed platform: this provider is\n  the upstream for [`provider-upjet-openpanel`][upjet], the Crossplane\n  provider generated from it.\n- Mint ingest-only Client credentials per environment from the same\n  IaC tree that defines your apps.\n\n[upjet]: https://github.com/hops-ops/provider-upjet-openpanel\n\n## Status\n\n| | |\n|---|---|\n| Tracks OpenPanel | [`hops-ops/openpanel-app`](https://github.com/hops-ops/openpanel-app) fork (admin-JWT auth + `/manage/organizations` endpoints; both pending upstream as [openpanel-dev/openpanel#371](https://github.com/openpanel-dev/openpanel/pull/371)) |\n| Auth modes | Client-pair (any OpenPanel install), OIDC `client_credentials`, static Bearer |\n| Latest release | See [Releases](https://github.com/hops-ops/terraform-provider-openpanel/releases) |\n\n\u003e The provider speaks the standard `/manage` REST API for Projects,\n\u003e Clients, and References (available in upstream OpenPanel since\n\u003e 2026-01-20). The Organizations resource and the OIDC + Bearer auth\n\u003e modes require the hops-ops fork's admin-JWT middleware until that\n\u003e patch lands upstream.\n\n## Installing\n\n### From the Terraform Registry\n\n```hcl\nterraform {\n  required_providers {\n    openpanel = {\n      source  = \"hops-ops/openpanel\"\n      version = \"~\u003e 0.1\"\n    }\n  }\n}\n```\n\n### Locally (for development)\n\nSet up [`dev_overrides`][dev-overrides] in `~/.terraformrc`:\n\n```hcl\nprovider_installation {\n  dev_overrides {\n    \"hops-ops/openpanel\" = \"/path/to/your/$GOPATH/bin\"\n  }\n  direct {}\n}\n```\n\nThen `go install` from a clone of this repo.\n\n[dev-overrides]: https://developer.hashicorp.com/terraform/cli/config/config-file#development-overrides-for-provider-developers\n\n## Authentication\n\nThe provider supports three auth modes. Configure exactly one.\n\n### Client-pair (default — works against any OpenPanel install)\n\nMint a root-typed Client through the OpenPanel dashboard (or via the\n[openpanel-chart][chart] Helm bootstrap Job, which writes the\ncredential to a chart-managed `openpanel-bootstrap-root` Secret at\ninstall time).\n\n```hcl\nprovider \"openpanel\" {\n  host          = \"https://analytics.example.com\"\n  client_id     = var.openpanel_client_id\n  client_secret = var.openpanel_client_secret\n}\n```\n\nEnvironment fallback: `OPENPANEL_HOST`, `OPENPANEL_CLIENT_ID`,\n`OPENPANEL_CLIENT_SECRET`.\n\n[chart]: https://github.com/hops-ops/openpanel-chart\n\n### OIDC `client_credentials` (fork-only)\n\nLets the provider authenticate via your platform IdP (Zitadel, Okta,\netc.) instead of a long-lived shared secret. Requires the hops-ops\nfork's `ADMIN_OIDC_ISSUER` configuration.\n\n```hcl\nprovider \"openpanel\" {\n  host = \"https://analytics.example.com\"\n\n  oidc {\n    issuer        = \"https://auth.example.com\"\n    client_id     = var.oidc_client_id\n    client_secret = var.oidc_client_secret\n    audience      = \"openpanel-admin\"\n  }\n}\n```\n\nThe provider runs the `client_credentials` grant against\n`\u003cissuer\u003e/.well-known/openid-configuration`, caches the JWT, and\nrefreshes ~60s before expiry.\n\n### Static Bearer\n\nWhen some external tool already issues a JWT:\n\n```hcl\nprovider \"openpanel\" {\n  host  = \"https://analytics.example.com\"\n  token = var.openpanel_token\n}\n```\n\n## Resources\n\n### `openpanel_organization`\n\nTop-level tenant primitive; scopes Projects, Clients, References,\nMembers.\n\n```hcl\nresource \"openpanel_organization\" \"acme\" {\n  name     = \"Acme\"\n  timezone = \"America/Chicago\"\n}\n```\n\n### `openpanel_project`\n\n```hcl\nresource \"openpanel_project\" \"marketing_site\" {\n  name   = \"Marketing site\"\n  domain = \"example.com\"\n  cors   = \"https://example.com https://www.example.com\"\n}\n```\n\n### `openpanel_client`\n\nPer-environment ingest credentials. Use Client `type = \"write\"` for\nSDKs; `type = \"root\"` for management API access.\n\n```hcl\nresource \"openpanel_client\" \"marketing_site_web\" {\n  name       = \"Marketing site web\"\n  type       = \"write\"\n  project_id = openpanel_project.marketing_site.id\n  cors       = \"https://example.com\"\n}\n\noutput \"marketing_site_client_id\" {\n  value = openpanel_client.marketing_site_web.id\n}\n\noutput \"marketing_site_client_secret\" {\n  value     = openpanel_client.marketing_site_web.secret\n  sensitive = true\n}\n```\n\n### `openpanel_reference`\n\nFree-form metadata for slicing analytics (release tags, deploys,\nfeature flags, etc.).\n\n```hcl\nresource \"openpanel_reference\" \"release_v1_2_0\" {\n  project_id = openpanel_project.marketing_site.id\n  name       = \"v1.2.0\"\n  date       = \"2026-05-18T00:00:00Z\"\n  description = \"Marketing-site relaunch\"\n}\n```\n\n## Full reference\n\nPer-resource attribute documentation lives under [`docs/`](./docs/);\nthe Terraform Registry surfaces the same content rendered with\nexamples.\n\n## Development\n\n### Requirements\n\n- Go ≥ 1.24\n- Terraform ≥ 1.13\n\n### Build \u0026 generate\n\n```shell\ngo install\nmake generate    # regenerates docs/ from the provider schema\n```\n\n### Tests\n\n```shell\nmake test     # unit\nmake testacc  # acceptance (creates real resources against a real OpenPanel; needs OPENPANEL_HOST etc.)\n```\n\n### Release\n\nReleases are driven by [vnext][vnext] from conventional commits on\n`main`. Pushing a `feat:` / `fix:` commit to main:\n\n1. CI runs build + lint + docs-up-to-date checks.\n2. `vnext` calculates the next semver and pushes a tag.\n3. The `on-version-tagged` workflow runs goreleaser, signs the\n   binaries with the repo's GPG key, and publishes them as a GitHub\n   Release. The Terraform Registry picks the release up automatically.\n\n[vnext]: https://github.com/unbounded-tech/vnext\n\n## Related repos\n\n| Repo | Purpose |\n|---|---|\n| [`hops-ops/openpanel-app`](https://github.com/hops-ops/openpanel-app) | OpenPanel fork with admin-JWT auth + `/manage/organizations` endpoints |\n| [`hops-ops/openpanel-chart`](https://github.com/hops-ops/openpanel-chart) | Helm chart with per-concern Secrets + root-Client bootstrap Job |\n| [`hops-ops/analytics-stack`](https://github.com/hops-ops/analytics-stack) | Crossplane composition that runs the chart + publishes the bootstrap credential to AWS Secrets Manager |\n| [`hops-ops/provider-upjet-openpanel`](https://github.com/hops-ops/provider-upjet-openpanel) | Crossplane provider generated from this Terraform provider via upjet |\n\n## License\n\nMPL-2.0\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhops-ops%2Fterraform-provider-openpanel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhops-ops%2Fterraform-provider-openpanel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhops-ops%2Fterraform-provider-openpanel/lists"}