- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-19-2020 01:06 PM
I am attempting to set up my Ansible Spoke (Connected to AWX Ansible Tower) in ServiceNow using the instructions found at: https://docs.servicenow.com/bundle/orlando-servicenow-platform/page/administer/integrationhub-store-...
The error comes when I try to get the OAuth Token where the window will first ask for my login info into the tower and then once I am logged in and I authorize the ServiceNow Application, it displays this:
I am following the token URL template found in the instructions, https://<Ansible-Tower-Instance>.com/api/o/token/ with my tower instance replace what is found within the <>. Is there any insight why this is not working or where I could find the correct Token URL?
Thanks.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2021 12:27 PM
After working with this a few times, the issue will arise with OAuth when your endpoints cannot communicate due to security/network issues. ServiceNow is public facing while your ansible tower is most likely not. Mid-servers cannot be used to authenticate OAuth 2.0, as stated here: https://docs.servicenow.com/bundle/paris-application-development/page/integrate/outbound-rest/concept/c_OutboundRESTAuth.html
If you cannot loosen security between the two, then I would suggest using basic authentication, which you can find instructions for here: https://docs.servicenow.com/bundle/quebec-servicenow-platform/page/administer/integrationhub-store-spokes/task/setup-ansible.html#setup-ansible
This will allow you to use a mid-server and the credentials for a tower service account to connect tower to your instance. Hope that helps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-03-2020 02:55 PM
Thank you very much for quick response. I will try that out. It was helpful
Thank you
Achu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-14-2020 02:51 PM
Is there any other way to make it work? Please let me know.
Thanks,
Achu
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2021 11:51 AM
We have the same error. Any resolution?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2021 12:27 PM
After working with this a few times, the issue will arise with OAuth when your endpoints cannot communicate due to security/network issues. ServiceNow is public facing while your ansible tower is most likely not. Mid-servers cannot be used to authenticate OAuth 2.0, as stated here: https://docs.servicenow.com/bundle/paris-application-development/page/integrate/outbound-rest/concept/c_OutboundRESTAuth.html
If you cannot loosen security between the two, then I would suggest using basic authentication, which you can find instructions for here: https://docs.servicenow.com/bundle/quebec-servicenow-platform/page/administer/integrationhub-store-spokes/task/setup-ansible.html#setup-ansible
This will allow you to use a mid-server and the credentials for a tower service account to connect tower to your instance. Hope that helps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-24-2022 07:11 AM
Hi Garret;
As per the doc link you mentioned above, I have set up ansible ac using basic authentication and configured the mid-server connectivity.
How to test the connectivity from ServiceNow to ansible through REST outbound. What needs to select in the REST outbound Aunthtication tab? like Authentication Type, Basic auth profile, etc?
Thanks
Balaji Prusty