github.com/hugorut/terraform@v1.1.3/website/docs/language/settings/backends/artifactory.mdx (about)

     1  ---
     2  page_title: 'Backend Type: artifactory'
     3  description: Terraform can store state in artifactory.
     4  ---
     5  
     6  # artifactory
     7  
     8  Stores the state as an artifact in a given repository in
     9  [Artifactory](https://www.jfrog.com/artifactory/).
    10  
    11  Generic HTTP repositories are supported, and state from different
    12  configurations may be kept at different subpaths within the repository.
    13  
    14  -> **Note:** The URL must include the path to the Artifactory installation.
    15  It will likely end in `/artifactory`.
    16  
    17  This backend does **not** support [state locking](/language/state/locking).
    18  
    19  ## Example Configuration
    20  
    21  ```hcl
    22  terraform {
    23    backend "artifactory" {
    24      username = "SheldonCooper"
    25      password = "AmyFarrahFowler"
    26      url      = "https://custom.artifactoryonline.com/artifactory"
    27      repo     = "foo"
    28      subpath  = "terraform-bar"
    29    }
    30  }
    31  ```
    32  
    33  ## Data Source Configuration
    34  
    35  ```hcl
    36  data "terraform_remote_state" "foo" {
    37    backend = "artifactory"
    38    config = {
    39      username = "SheldonCooper"
    40      password = "AmyFarrahFowler"
    41      url      = "https://custom.artifactoryonline.com/artifactory"
    42      repo     = "foo"
    43      subpath  = "terraform-bar"
    44    }
    45  }
    46  ```
    47  
    48  ## Configuration variables
    49  
    50  The following configuration options / environment variables are supported:
    51  
    52  - `username` / `ARTIFACTORY_USERNAME` (Required) - The username
    53  - `password` / `ARTIFACTORY_PASSWORD` (Required) - The password
    54  - `url` / `ARTIFACTORY_URL` (Required) - The URL. Note that this is the base url to artifactory not the full repo and subpath.
    55  - `repo` (Required) - The repository name
    56  - `subpath` (Required) - Path within the repository