Resource nexus_repository_apt_proxy

Use this resource to create a hosted apt repository.

Example Usage

resource "nexus_repository_apt_proxy" "bionic_proxy" {
  name   = "bionic-proxy"
  online = true

  routing_rule = "string"
  distribution = "bionic"
  flat         = false

  storage {
    blob_store_name                = "default"
    strict_content_type_validation = true
  }

  proxy {
    remote_url       = "https://remote.repository.com"
    content_max_age  = 1440
    metadata_max_age = 1440
  }

  negative_cache {
    enabled = true
    ttl     = 1440
  }

  http_client {
    blocked    = false
    auto_block = true

    connection {
      retries                   = 0
      user_agent_suffix         = "string"
      timeout                   = 60
      enable_circular_redirects = false
      enable_cookies            = false
      use_trust_store           = false
    }

    authentication {
      type     = "username"
      username = "admin"
      password = "admin-password"
    }
  }
}

Schema

Required

Optional

Read-Only

Nested Schema for http_client

Required:

Optional:

Nested Schema for http_client.authentication

Required:

Optional:

Nested Schema for http_client.connection

Optional:

Nested Schema for proxy

Required:

Optional:

Nested Schema for storage

Required:

Optional:

Nested Schema for cleanup

Optional:

Nested Schema for negative_cache

Optional:

Import is supported using the following syntax:

# import using the name of repository
terraform import nexus_repository_apt_proxy.bionic_proxy bionic-proxy