terraform-provider-ignition icon indicating copy to clipboard operation
terraform-provider-ignition copied to clipboard

ignition_directory and ignition_file support only decimal value for mode

Open PawelZ-iHQ opened this issue 4 years ago • 8 comments

Ignition documentation for ignition_file and ignition_directory state that mode argument can be provided either octal or decimal:

mode - (Optional) The directory's permission mode. Note that the mode can be specified as either an octal value (e.g 0755) or a decimal value (i.e. 493 as equivalent to the octal 0755).

While provided values are evaluated as decimals only, even with leading 0. For example 0755 results with --wxrw--wx 0363 octal and 243 decimal. Quick look at the code suggests that mode is evaluated as TypeInt.

Please either extend code, so both octal and decimal are evaluated correctly or update documentation to state that only decimal values are accepted.

PawelZ-iHQ avatar Apr 20 '20 11:04 PawelZ-iHQ