mirror of
https://github.com/kreuzwerker/terraform-provider-docker.git
synced 2025-12-25 09:09:35 -05:00
* fix(service): remove image name suppress function * feat: add docker image data-source * docs(service): add example for iamge datasource usage * fix: image repo digest with tag determination * fix: always return a repoDigest * fix(image): deprecation notice for latest attribute * fix(ci): explicitly go get tfplugindocs * fix(ci): remove gocenter.io proxy
24 lines
459 B
HCL
24 lines
459 B
HCL
provider "docker" {
|
|
registry_auth {
|
|
address = "127.0.0.1:15000"
|
|
}
|
|
}
|
|
|
|
resource "docker_image" "tftest_image" {
|
|
name = "127.0.0.1:15000/tftest-service:v1"
|
|
keep_locally = false
|
|
force_remove = true
|
|
}
|
|
|
|
resource "docker_service" "foo" {
|
|
name = "tftest-service-basic"
|
|
task_spec {
|
|
container_spec {
|
|
image = docker_image.tftest_image.repo_digest
|
|
stop_grace_period = "10s"
|
|
}
|
|
}
|
|
mode {
|
|
replicated {}
|
|
}
|
|
}
|