-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Constraint build argument types. Numbers are cast into strings. #2938
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
Conversation
compose/config/config.py
Outdated
| build['args'] = resolve_build_args(build) | ||
| build['args'] = dict( | ||
| [(k, str(v)) for k, v in resolve_build_args(build).items()] | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since we do this in a couple places, could we make this a function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done 👍
ee187ea to
ba25db6
Compare
Numerical driver_opts are also valid and typecast into strings. Additional config tests. Signed-off-by: Joffrey F <[email protected]>
ba25db6 to
1952b52
Compare
compose/config/config.py
Outdated
| main_file = config_details.config_files[0] | ||
| volumes = load_mapping(config_details.config_files, 'get_volumes', 'Volume') | ||
| volumes = load_volumes(config_details.config_files) | ||
| networks = load_mapping(config_details.config_files, 'get_networks', 'Network') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just noticed we have the same issue with network.driver_opts. Probably makes sense to fix it here as well?
Signed-off-by: Joffrey F <[email protected]>
|
Updated to include network |
|
LGTM |
Constraint build argument types. Numbers are cast into strings.
Numerical
driver_optsare also valid and typecast into strings.FIxes #2927