Open WardsParadox opened 1 year ago
It cannot be specified now. It's also something I would not be able to test since we don't have any special federated access. If you can give me an example of what sort of curl options you typically pass in other AutoPkg recipes to make them work, that might help.
Normally I pass something like ['--cookie-jar', '~/.tool/cookie']
where our internal CLI auth tool writes the cookie jar.
The cookie-jar is pre-defined in JamfUploader, and is used to ensure that you get a consistent cluster node behind the scenes which is essential when running multiple, co-dependent API calls in quick succession. If you overwrote it with your own you would probably break it.
Sorry correction, we have a cookie file, not a cookie jar. My mistakes. Being able to specify an additional cookie would be tremendously helpful.
I don't know enough about curl off the bat to known if you can supply multiple cookie files. I use --cookie
and --cookie-jar
, as these work as read and write options as far as I can tell. See https://github.com/grahampugh/jamf-upload/blob/main/JamfUploaderProcessors/JamfUploaderLib/JamfUploaderBase.py#L371-L387
I just tested, you can indeed specify multiple --cookie
files.
Since this will pull in via recipe override or preferences, thoughts on making this a preference level like JU_CURL_OPTS? Can be specified as either a preference or an override variable since we're just pulling those in via self.env.get
?
The current implementation does not allow for extending curl options down to the CURL call. This prevents us from specifying additional options (like a cookie jar) to attach to the curl call to pass through our federated access.
Initial thoughts are to support recipe options or a preference array of the options to pull into every jamf-upload run to extend the internal curl calls.
If this can be specified now, I haven't been able to find that in the code as a way around it via recipe or override.