With the following .infisical.json:
{
"workspaceId": "<REDACTED>",
"defaultEnvironment": "dev",
"gitBranchToEnvironmentMapping": null,
"domain": "https://eu.infisical.com"
}
The following deploy script:
INFISICAL_TOKEN=$($INFISICAL_CLI login --method=universal-auth --silent --plain)
export INFISICAL_TOKEN
exec $INFISICAL_CLI run --silent "$@" -- <REDACTED>
Results in:
Warning: Using domain 'https://eu.infisical.com' from .infisical.json; all requests and credentials will be sent there.
Warning: Using domain 'https://eu.infisical.com' from .infisical.json; all requests and credentials will be sent there.
Project ID is required when using machine identity
Considering that domain is correctly read and that workspaceId is defined in the same file, I would expect not to have to set the project id explicitly.
I have confirmed that the error stems from infisical run. I have confirmed that passing--projectId=<REDACTED> runs my command correctly.
With the following
.infisical.json:{ "workspaceId": "<REDACTED>", "defaultEnvironment": "dev", "gitBranchToEnvironmentMapping": null, "domain": "https://eu.infisical.com" }The following deploy script:
Results in:
Considering that
domainis correctly read and thatworkspaceIdis defined in the same file, I would expect not to have to set the project id explicitly.I have confirmed that the error stems from
infisical run. I have confirmed that passing--projectId=<REDACTED>runs my command correctly.