The characters allowed to represent a container name is represented by the regex :
src code
// RestrictedNameChars collects the characters allowed to represent a name, normally used to validate container and volume names.
const RestrictedNameChars = `[a-zA-Z0-9][a-zA-Z0-9_.-]`
see #3138
And only the images name has a limited size of 30 chars.