Skip to content

Commit

Permalink
feat: Added repository_name as output
Browse files Browse the repository at this point in the history
  • Loading branch information
antonbabenko committed Apr 5, 2024
1 parent 44b41d4 commit 28a8ec9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
10 changes: 10 additions & 0 deletions examples/complete/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
# Private Repository
################################################################################

output "repository_name" {
description = "Name of the repository"
value = module.ecr.repository_name
}

output "repository_arn" {
description = "Full ARN of the repository"
value = module.ecr.repository_arn
Expand All @@ -21,6 +26,11 @@ output "repository_url" {
# Public Repository
################################################################################

output "public_repository_name" {
description = "Name of the repository"
value = module.public_ecr.repository_name
}

output "public_repository_arn" {
description = "Full ARN of the repository"
value = module.public_ecr.repository_arn
Expand Down
5 changes: 5 additions & 0 deletions outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
# Repository (Public and Private)
################################################################################

output "repository_name" {
description = "Name of the repository"
value = try(aws_ecr_repository.this[0].name, aws_ecrpublic_repository.this[0].id, null)
}

output "repository_arn" {
description = "Full ARN of the repository"
value = try(aws_ecr_repository.this[0].arn, aws_ecrpublic_repository.this[0].arn, null)
Expand Down

0 comments on commit 28a8ec9

Please sign in to comment.