# Terraform Provider Immich A Terraform/OpenTofu provider for managing [Immich](https://immich.app/). Immich is a high-performance self-hosted photo and video management solution. This provider allows you to manage users, API keys, albums, and shared links programmatically. ## Documentation Full documentation for the provider can be found on the [Terraform Registry](https://registry.terraform.io/providers/immich-app/immich/latest/docs). ## Requirements - [Terraform](https://www.terraform.io/downloads.html) >= 1.0 - [Go](https://golang.org/doc/install) >= 1.21 (to build the provider plugin) ## Installation To use this provider, add the following to your Terraform configuration: ```hcl terraform { required_providers { immich = { source = "registry.terraform.io/immich-app/immich" } } } provider "immich" { # endpoint = "http://your-immich-instance:2283/api" # api_key = "your-admin-api-key" } ``` The provider can be configured via environment variables: - `IMMICH_ENDPOINT`: The full URL of the Immich API (e.g., `http://192.168.1.10:2283/api`) - `IMMICH_API_KEY`: Your Immich API key. ## Building The Provider 1. Clone the repository 2. Enter the repository directory 3. Build the provider using the Go `install` command: ```shell go install . ``` ## Documentation Generation The documentation is generated using `terraform-plugin-docs`. To generate the documentation, run: ```shell go generate ./... ``` (Note: This requires `tfplugindocs` to be installed and a `//go:generate` directive in `main.go`) ## License MIT License - see the [LICENSE](LICENSE) file for details.