Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Replace unsupported repeated yaml anchors w/ merge #8

Merged
merged 1 commit into from
May 5, 2023
Merged

Fix: Replace unsupported repeated yaml anchors w/ merge #8

merged 1 commit into from
May 5, 2023

Conversation

dotWee
Copy link
Contributor

@dotWee dotWee commented May 4, 2023

The use of duplicate YAML merge keys (<<) is now rejected from latest docker-compose spec.

It fails with the following syntax error due to go/yaml/v3 update:

$ docker-compose --project-name myidp -f docker-compose-ref.yml up -d
parsing ./docker-compose-ref.yml: yaml: unmarshal errors:
  line 32: mapping key "<<" already defined at line 31
  line 55: mapping key "<<" already defined at line 54

goyaml/v3 does not support repeated anchors (due to internal storage using << as key during parsing) but allows use of multi-values in anchors.

References:

Duplicate YAML merge keys `(<<)` are now rejected from latest docker-compose spec. 

It fails with the following syntax error due to go/yaml/v3 update:

```sh
$ docker-compose --project-name myidp -f docker-compose-ref.yml up -d
parsing ./docker-compose-ref.yml: yaml: unmarshal errors:
  line 32: mapping key "<<" already defined at line 31
  line 55: mapping key "<<" already defined at line 54
```

"goyaml/v3 does not support repeated anchors (due to internal storage
using << as key during parsing) but allows use of multi-values in
anchors"

See:
- docker/compose#10411 (comment)
- https://yaml.org/type/merge.html
@RStaeber RStaeber merged commit 85ff4dd into gematik:master May 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants