https://pulumi.com logo
#aws
Title
# aws
a

average-kilobyte-47828

10/17/2020, 9:58 PM
aws and awsx namespaces... I'm defining container registries and there are 2 ecr.Repository classes, one from aws and one from awsx, each taking a subset of possible arguments. From awsx I can get lifecyclepolicy and from aws I can have imageScanningConfiguration and imageTagImmutability but not both. Am I doing something stupid?
f

faint-table-42725

10/19/2020, 4:39 PM
Not at all!
awsx
is a higher-level abstraction library that provides a convenient, opinionated way on using
aws
a

average-kilobyte-47828

10/25/2020, 9:56 PM
Thanks @faint-table-42725 This much I’ve understood. What I’m asking is how can I have all 3 of lifecyclePolicy, imageScanningConfiguration and imageTagMutablility when choosing either library. Or how can I use both for defining a single resource?
f

faint-table-42725

10/26/2020, 10:13 PM
You have a couple options here. You can wire this up in
aws
and if you did that, then you’d use
Repository
for the scanning and tag immutability along with the
LifecyclePolicy
resource to handle the lifecycle part (https://www.pulumi.com/docs/reference/pkg/aws/ecr/)
👍 1
Alternatively, if you wanted to use
awsx
, you can pass a
transformation
(https://www.pulumi.com/docs/intro/concepts/programming-model/#transformations) to the
awsx.Repository
to modify the underlying
aws.Repository
resource to include the
imageScanningConfiguration
and
imageTagImmutability
properties.
👍 1