You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] -.json:10,5-19: Invalid name; only "[a-zA-Z0-9_-]+" are allowed #12919
It seems that recent change to docker compose and usage of bake by default to build images have introduced some incompatibility. Service names containing a dot character are valid according to the spec. Yet when building docker compose projects with service names with dots I'm getting:
-.json:10,5-19: Invalid name; only "[a-zA-Z0-9_-]+" are allowed
When one does docker config > bake.yaml and then docker buildx bake -f bake.yaml everything builds as expected. Only running docker compose up and similar gives the error.
It seems that recent change to docker compose and usage of bake by default to build images have introduced some incompatibility. Service names containing a dot character are valid according to the spec. Yet when building docker compose projects with service names with dots I'm getting:
-.json:10,5-19: Invalid name; only "[a-zA-Z0-9_-]+" are allowed
Activity
serious-angel commentedon Jun 9, 2025
Wonderful day! ✨
The only place with the regex mentioned found:
Source
And, it seems like the message originates from:
Source
Therefore, it could be a Dockerfile target.
furai commentedon Jun 12, 2025
I've just confirmed that #12925 has fixed the issue.