BIG-RAT / jamfcpr

Replicate packages between Jamf Pro Servers
Apache License 2.0
75 stars 3 forks source link

"Save only" mode does not work #24

Open entusdictus opened 4 months ago

entusdictus commented 4 months ago

There are multiple issues with "Save only" mode in jamfcpr. First issue to reproduce:

Second issue to reproduce:

BIG-RAT commented 4 months ago

Thanks for the details. Issue has been addressed in jamfcpr_5.0.0-b2

entusdictus commented 3 months ago

This issue is fixed, but a new one arrived:

Unable to locate the destination: /Users/enti/Library/Containers/jamf.ie.jamfcpr/Data/Downloads/jamfcpr Verify the folder exists and/or the appropriate share is mounted.

This happens when I select "Save only" and then "List".

BIG-RAT commented 3 months ago

Nice catch. Folder isn't created if you run Save Only before ever copying packages from one distro to another. Fixed in latest beta

entusdictus commented 3 months ago

Confirmed, fixed from my end but a new one arrived (I'm sorry, really... 😁)

Steps to reproduce:

I fixed it by disabling "save only", hit "list" once to query both source and destination, selected "save only" again and now listing works even after re-launching the app and for other sources.

20240318_143123 -------------------------------------------------------
20240318_143123 -   jamf CPR Version: 5.0.0-b3 Build: 20240318.125643
20240318_143123 -------------------------------------------------------
20240318_143123 searching the keychain for JPMA-YOURINSTANCE.jamfcloud.com
20240318_143123 searching the keychain for JPMA-YOURINSTANCEdev.jamfcloud.com
20240318_143126 [ViewController.reset]
20240318_143126 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143126 [ViewController.reloadFileList] display packages from source JCDS
20240318_143126 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143126 searching the keychain for JPMA-YOURINSTANCE.jamfcloud.com
20240318_143126 searching the keychain for JPMA-YOURINSTANCEdev.jamfcloud.com
20240318_143126 [VewController.list_Button] cleared current package list
20240318_143126 [VewController.list_Button] get token for https://YOURINSTANCE.jamfcloud.com
20240318_143126 [VewController.list_Button] Generate token for  source Jamf Pro...
20240318_143126 [JamfPro.getToken] Source is using username / password for authenication
20240318_143126 [JamfPro.getToken] Attempting to retrieve token from https://YOURINSTANCE.jamfcloud.com/api/v1/auth/token
20240318_143126 [ViewController.reset]
20240318_143126 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143126 [ViewController.reloadFileList] display packages from source JCDS
20240318_143126 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143229 [JamfPro.getToken] token response error from https://YOURINSTANCE.jamfcloud.com. Verify url and port
20240318_143300 searching the keychain for JPMA-YOURINSTANCE.jamfcloud.com
20240318_143300 [ViewController.reset]
20240318_143300 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143300 [ViewController.reloadFileList] display packages from source JCDS
20240318_143300 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143300 searching the keychain for JPMA-YOURINSTANCE.jamfcloud.com
20240318_143300 searching the keychain for JPMA-YOURINSTANCEdev.jamfcloud.com
20240318_143300 [VewController.list_Button] cleared current package list
20240318_143300 [VewController.list_Button] get token for https://YOURINSTANCE.jamfcloud.com
20240318_143300 [VewController.list_Button] Generate token for  source Jamf Pro...
20240318_143300 [JamfPro.getToken] Source is using username / password for authenication
20240318_143300 [JamfPro.getToken] Attempting to retrieve token from https://YOURINSTANCE.jamfcloud.com/api/v1/auth/token
20240318_143300 [ViewController.reset]
20240318_143300 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143300 [ViewController.reloadFileList] display packages from source JCDS
20240318_143300 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143522 [JamfPro.getToken] token response error from https://YOURINSTANCE.jamfcloud.com. Verify url and port
20240318_143524 [ViewController.reset]
20240318_143524 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143524 [ViewController.reloadFileList] display packages from source JCDS
20240318_143524 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143524 searching the keychain for JPMA-YOURINSTANCE.jamfcloud.com
20240318_143524 searching the keychain for JPMA-YOURINSTANCEdev.jamfcloud.com
20240318_143524 [VewController.list_Button] cleared current package list
20240318_143524 [VewController.list_Button] get token for https://YOURINSTANCE.jamfcloud.com
20240318_143524 [VewController.list_Button] Generate token for  source Jamf Pro...
20240318_143524 [JamfPro.getToken] Source is using username / password for authenication
20240318_143524 [JamfPro.getToken] Attempting to retrieve token from https://YOURINSTANCE.jamfcloud.com/api/v1/auth/token
20240318_143524 [ViewController.reset]
20240318_143524 [ViewController.reloadFileList] source: https://YOURINSTANCE.jamfcloud.com
20240318_143524 [ViewController.reloadFileList] display packages from source JCDS
20240318_143524 [ViewController.reloadFileList] call packageTableView.reloadData()
20240318_143525 [JamfPro.getToken] new token created for https://YOURINSTANCE.jamfcloud.com
20240318_143525 [JamfPro.getToken] Source will be renewed: false
20240318_143525 [ApiAction.action] Token retrieved from https://YOURINSTANCE.jamfcloud.com/uapi/v1/jamf-pro-version.
20240318_143525 [JamfPro.getVersion] Source Jamf Pro Version: 11.3.2-t1710427376
20240318_143525 [JamfPro.getVersion] https://YOURINSTANCE.jamfcloud.com set to use OAuth
20240318_143525 [VewController.list_Button] Querying source JCDS...
20240318_143525 [VewController.list_Button] found 38 packages on the source distribution point.
20240318_143525 [VewController.list_Button] Querying source Jamf Pro Server...
20240318_143525 [ApiAction.getPackages] enter
20240318_143525 [ApiAction.getPackages] Getting packages
20240318_143525 [ApiAction.getPackages] URL: https://YOURINSTANCE.jamfcloud.com/JSSResource/packages
20240318_143525 [ApiAction.getPackages] Getting all endpoints from: https://YOURINSTANCE.jamfcloud.com/JSSResource/packages
20240318_143525 [ApiAction.getPackages] endpointJSON: ["packages": <__NSArrayI 0x14680b250>(
{
    id = 398;
    name = "Adobe Creative Cloud 6.0.0.pkg";
},
.......
)
])
BIG-RAT commented 3 months ago

All good - sounds like I need to get a clean profile to do more testing on. I had have random issues with the account info looking like it's there but when I try to run it's giving a similar message to the one you saw. Change something or just tab through the server/username/password fields and it works fine.