nutritious-hair-72580
01/26/2023, 12:08 PMpants.ci.toml
Then, in your CI script or config, set the environment variableIn my testing, i seem to need to specifyto use this new config file, in addition toPANTS_CONFIG_FILES=pants.ci.toml
.pants.toml
PANTS_CONFIG_FILES="['pants.toml', 'pants.ci.toml']"
for the options to get mergednutritious-hair-72580
01/26/2023, 12:12 PM[docker.registries.primary]
address = "<http://1111111.dkr.ecr.us-east-1.amazonaws.com|1111111.dkr.ecr.us-east-1.amazonaws.com>"
default = true
use_local_alias = true
extra_image_tags = [
"blah"
]
in pants.ci.toml
[docker.registries.primary]
address = "<http://9999999.dkr.ecr.us-east-1.amazonaws.com|9999999.dkr.ecr.us-east-1.amazonaws.com>"
but without needing to also specify the other options in pants.ci.toml - but maybe this is not possible?curved-television-6568
01/26/2023, 12:50 PM--docker-registries="{'key1': val1, 'key2': val2, ...}"
So the value for your registries key primary
gets replaced rather than merged. For this case, you’d need some other method of changing the address, like relying on an external env var could work:
address = "%(env.DKR_ECR_ADDRESS)s"
curved-television-6568
01/26/2023, 12:52 PM--docker-registries="{'key1': val1, 'key2': val2, ...}"
PANTS_DOCKER_REGISTRIES
registries
default: {}
current value: {...} (from pants.ci.toml, pants.toml)
curved-television-6568
01/26/2023, 12:52 PMcurved-television-6568
01/26/2023, 12:52 PMPANTS_CONFIG_FILES=pants.ci.toml ./pants docker --help
nutritious-hair-72580
01/26/2023, 1:49 PMhappy-kitchen-89482
01/26/2023, 9:09 PMcurved-television-6568
01/26/2023, 10:15 PMcurved-television-6568
01/26/2023, 10:16 PM[docker.registries.primary.add] address = "foo"
but that didn’t workcurved-television-6568
01/26/2023, 10:16 PM.add
wrong.. ? 😉happy-kitchen-89482
01/26/2023, 10:27 PM