Skip to content
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

Package upload stuck on Availability Pending #20

Closed
lighterless opened this issue Feb 8, 2021 · 2 comments
Closed

Package upload stuck on Availability Pending #20

lighterless opened this issue Feb 8, 2021 · 2 comments

Comments

@lighterless
Copy link

I am having issues uploading a package using the JamfPackageUploader processor. It looks like everything uploads correctly but then the package stays in the Pending state on JamfCloud and if I look in Jamf Admin, it says the package is missing.

image

I have tried with several different packages, different recipes. Always the same issue. If I upload the file manually, it works. I'm happy to provide whatever logs you need.

@grahampugh
Copy link
Owner

Hi Ben,
I've read in Macadmins Slack that many people are having problems uploading packages to Jamf Cloud at the moment (not a thing specific to this processor).

As an experiment, you can try uploading via Jamf Admin. Are your uploads always successful?

If yes, you can also experiment using my standalone jamf-pkg-upload.py script. This is a bit more involved, but you would need to clone the following repository: https://github.com/grahampugh/jamf-upload

git clone https://github.com/grahampugh/jamf-upload

Then, run the script as follows:

/usr/local/autopkg/python ./jamf-pkg-upload.py --prefs /Users/YOURUSERNAME/Library/Preferences/com.github.autopkg.plist --pkg /path/to/Google_Drive_intel.pkg --replace_pkg

This uses the same upload method as the JamfPackageUploader processor (it uses curl). But, with this standalone you can try four different methods; nscurl, requests and "direct" (web-emulation):

/usr/local/autopkg/python ./jamf-pkg-upload.py --prefs /Users/YOURUSERNAME/Library/Preferences/com.github.autopkg.plist --pkg /path/to/Google_Drive_intel.pkg --replace_pkg --nscurl

/usr/local/autopkg/python ./jamf-pkg-upload.py --prefs /Users/YOURUSERNAME/Library/Preferences/com.github.autopkg.plist --pkg /path/to/Google_Drive_intel.pkg --replace_pkg --requests

/usr/local/autopkg/python ./jamf-pkg-upload.py --prefs /Users/YOURUSERNAME/Library/Preferences/com.github.autopkg.plist --pkg /path/to/Google_Drive_intel.pkg --replace_pkg --direct

Note that for the last two options, the python requests module has to be installed, so if you don't already have JSSImporter installed, you'll have to install it using pip (or pip3 most likely). This command would install it in your AutoPkg environment, but if you're testing this on another machine you might be using a different python. Adjust accordingly:

/Library/AutoPkg/Python3/Python.framework/Versions/3.7/bin/pip3 install requests --user

@lighterless
Copy link
Author

Thanks for the quick reply @grahampugh. I think I found the issue. As it turns out, the pkg_name parameter is actually looking for the value of pkg_path and here I thought it was just a string for the package name on Jamf. Appending .pkg to the end of the pkg_name results in a successful upload using autopkg. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants