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
When resolving file parameters, the source strategy (i.e. type) e.g. env, value etc is ignored and porter always assumes that the provided hint is either a path to a file or a base64-encoded string with the file contents.
Create example data files: echo this is DATA > DATA && echo this is my-data > my-data
Apply the parameter set porter apply parameters.yaml
Install the bundle DATA=my-data porter install --parameter-set test test
Note that the string data has been resolved to the value of DATA (my-data) whereas the file data has been read from a file with the same name as the environment variable.
❯ DATA='my-data' porter install --parameter-set=test test --force
Just-in-time resolving credentials...
Just-in-time resolving parameters...
executing install action from porter-file-param-test (installation: /test)
Install
data-file: this is DATA
data-string: my-data
execution completed successfully!
Expected behavior
Porter resolves the value using the provided strategy, then checks if it is the path to a local file or base64-encoded data.
Version
porter v1.2.1
The text was updated successfully, but these errors were encountered:
erikced
changed the title
Porter assumes file parameter should always be resolved using the value strategy
Porter always resolves file parameters using the value strategy
Mar 10, 2025
Describe the bug
When resolving file parameters, the source strategy (i.e. type) e.g.
env
,value
etc is ignored and porter always assumes that the provided hint is either a path to a file or a base64-encoded string with the file contents.To Reproduce
Use the following bundle
and parameter set
echo this is DATA > DATA && echo this is my-data > my-data
porter apply parameters.yaml
DATA=my-data porter install --parameter-set test test
DATA
(my-data
) whereas the file data has been read from a file with the same name as the environment variable.Expected behavior
Porter resolves the value using the provided strategy, then checks if it is the path to a local file or base64-encoded data.
Version
porter v1.2.1
The text was updated successfully, but these errors were encountered: