Archy Setup Failing

Hello there!

My attempt to setup Archy is failing with the following error:

This is my first post and I have removed some of the log content due to restrictions on new users. I can add more log content in a follow-up post if needed.

2022-11-30T00:30:28.016Z: [INFO] running refresh command.
2022-11-30T00:30:28.017Z: [DEBUG] - setting the endTerminatesProcess to falsee[36m -- [ArchSession, ArchSessionId:'SJS95MEwi']e[39m
2022-11-30T00:30:28.017Z: [INFO]
2022-11-30T00:30:28.017Z: [INFO] startup Mode: Using client ID and secret. Treating as client credentials grant.
2022-11-30T00:30:28.018Z: [INFO]
2022-11-30T00:30:28.019Z: [DEBUG] - setting session status to 'running'.e[36m -- [ArchSession, ArchSessionId:'SJS95MEwi']e[39m
2022-11-30T00:30:28.031Z: [DEBUG] - architect scripting version: 0.34.1e[36m -- [ArchSession, ArchSessionId:'SJS95MEwi']e[39m
2022-11-30T00:30:28.032Z: [DEBUG] - core environment configuration. env: 'prod', host: 'apps.mypurecloud.de', region: 'eu-central-1', clientId: 'xxRemovedByPosterxx', clientSecret: 'xxRemovedByPosterxx', isClientCredentialsOAuthClient: 'true'e[36m -- [ArchSession, ArchSessionId:'SJS95MEwi']e[39m
2022-11-30T00:30:28.032Z: [DEBUG] - getting discovery properties...e[36m -- [ArchSession, ArchSessionId:'SJS95MEwi']e[39m
> 2022-11-30T00:30:28.032Z: [DEBUG] - calling urle[36m -- [apps dot mypurecloud dot de/services/discovery.properties]e[39m
> 2022-11-30T00:30:39.299Z: [ERROR] - ERROR! Unable to read discovery properties. Exception info: {"isRequestError":true,"response":{"code":"SELF_SIGNED_CERT_IN_CHAIN"},"status":0,"statusText":"","name":"Request Error","message":"self signed certificate in certificate chain (SELF_SIGNED_CERT_IN_CHAIN)","code":"SELF_SIGNED_CERT_IN_CHAIN","isAborted":false} ending the Session. Setting the exit code to 99.e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJS95MEwi']e[39m


2022-11-30T00:30:39.326Z: [INFO] Archy - Architect Yaml Flow Processor ver. 2.15.2 - Failure
2022-11-30T00:30:39.326Z: [INFO] *****************************************************************************************
2022-11-30T00:30:39.327Z: [INFO] DateTime: Tue Nov 29 2022 16:30:39 GMT-0800 (Pacific Standard Time)
2022-11-30T00:30:39.328Z: [INFO]
2022-11-30T00:30:39.328Z: [INFO] Summary
2022-11-30T00:30:39.329Z: [INFO]
2022-11-30T00:30:39.329Z: [INFO] Command: 'setup'
2022-11-30T00:30:39.330Z: [INFO]
2022-11-30T00:30:39.331Z: [INFO] Configuration Settings File
2022-11-30T00:30:39.331Z: [INFO] C:\Users\waqarm.archy_config
2022-11-30T00:30:39.332Z: [ERROR] unable to authenticate with the supplied client ID and secret. Are they valid and is the OAuth client set up with a client credentials grant?

2022-11-30T00:30:39.332Z: [INFO]
2022-11-30T00:30:39.333Z: [ERROR] error(s) encountered.
2022-11-30T00:30:39.333Z: [ERROR] - Architect Scripting errors will be listed above.
2022-11-30T00:30:39.334Z: [INFO]
2022-11-30T00:30:39.335Z: [INFO] Log: c:\Development\genesys\archy\archyHome\debug\archy-debug-> > > 2022-11-29T23.49.32.753Z.txt
2022-11-30T00:30:39.458Z: [INFO] did not fetch versions successfully ( attempt 1 out of 3 ), retrying.
2022-11-30T00:30:40.479Z: [DEBUG] version fetch error: Error: self signed certificate in certificate chain
2022-11-30T00:30:40.480Z: [INFO] execution complete.
2022-11-30T00:30:40.490Z: [ERROR]
2022-11-30T00:30:40.492Z: [ERROR] exit code: 116

Pasting the URL for discovery.properties into Chrome, Edge, and Firefox works (it downloads the file or asks me where to download a file):

Using a curl command with that URL (with and without elevated privileges) does not work:

curl: (35) schannel: next InitializeSecurityContext failed: Unknown error (0x80092012) - The revocation function was unable to check revocation for the certificate.'

I am able to make a version request from the terminal.

c:\Development\genesys\archy>archy version
Architect Scripting running under Node version '14.18.3'
ArchSessionId:ByzLUmSDj
2.15.2

Any suggestions for what else to try? Does the ability to download the file using a browser create any possibilities to bypass this part of the setup?

Thanks for any help!

Hi there WaqarM,

Thanks for posting! There is a similar post with this issue that you can find here - Archy error 116 - #3 by jon.vansteen

Does the environment that you are using Archy on happen to use a proxy at all? Per this info on the Archy FAQ page, Archy does not currently support proxy configurations at this time.

Similar to the post I linked, it seems like there is something going on at a network level since the error response on both the discovery properties and when checking for versions both responded with self signed certificate in certificate chain.

Unfortunately being able to access the discovery.properties via a browser does not allow being able to bypass that network call via the setup (and also other commands from Archy). Perhaps there is some configuration needed to allow your terminal to access the discovery.properties URL on your machine since you also were not able to curl that endpoint.

Thanks,
Jon

Hi Jon!

Thanks for responding.

I did take a look at the other posts.

I will look further into the proxy and whether there are any network security issues at play. Does a successful call from the terminal to get the version give us any information about network issues?

Best,

Waqar

Hi Jon!

To add more information and a question:

I am on Windows 10. I vaguely recalled that the curl command in Windows is different than in Unix/Linux, and that it also differs across Command Prompt and Powershell.

I tried using Powershell. My curl https://apps.mypurecloud.de/services/discovery.properties is successful. But my archy setup fails with the same error message.

Does a successful curl call help us rule out any issues?

Best,

Waqar

Hi again @WaqarM,

Yeah it seems some network configuration is also causing Archy to be unable to check for new versions of the application. So if you can use the archy checkVersion command successfully, other commands will also probably work. Are you able to run Archy from powershell with any different results?

Thanks,
Jon

Hi @jon.vansteen

Thanks you for your help with this issue. I have reached out to our network security team. I want to be armed with information and explain to them why I think it's a network issue when they get back to me.

I am able to successfully use the version command on Command Terminal and in Powershell but that call fails when it happens within the archy setup command across both types of terminals.

I can successfully make the curl call directly in Window Powershell. However, I still get the same error upon accessing the properties URL when the call is made within the Archy setup.

I am pasting below the log of the latest attempt. I have tried using both Command Prompt and Powershell with and without elevated privileges.

To gather the questions in one place:

  1. Would I be able to make a successful version call or curl call if there was a proxie issue--do these successful calls rule out a proxie issue and a network issue?
  2. If we cannot rule out a Proxie issue, it seems that you were able to tell that it was a proxie issue in a past discussion after looking at the log. Where do you look for that?
  3. That I am able to make the version and curl command successfully outside of the setup command makes me wonder if the issue is specific to configuring the setup. Are there are any options/flags I can set when running the archy setup command?
  4. I am confident that I have responded correctly to the prompts while archy setup is running (debug=true; location=where our instance is hosted; clientId copied from OAuth client I created; clientSecret copied from OAuth client I created; authToken: no value entered). Is there a need to see if the OAuth Client was configured correctly (roles and permissions)?

Best,

Waqar

2022-11-30T23:04:23.891Z: [DEBUG] readline - answer was 'Y'
2022-11-30T23:04:23.893Z: [INFO] getting ready to run refresh command.
2022-11-30T23:04:23.893Z: [INFO] processing the configuration setting 'homeDir'.
2022-11-30T23:04:23.896Z: [INFO] getting the value for the setting 'homeDir' from the Archy configuration file.
2022-11-30T23:04:23.899Z: [INFO] processing the configuration setting 'authToken'.
2022-11-30T23:04:23.900Z: [INFO] processing the configuration setting 'authTokenIsClientCredentials'.
2022-11-30T23:04:23.900Z: [DEBUG] the 'authTokenIsClientCredentials' value is being set to the default value 'false' since no value was specified on a command line parameter, options file or in the archy_config file.
2022-11-30T23:04:23.901Z: [INFO] processing the configuration setting 'clientId'.
2022-11-30T23:04:23.902Z: [INFO] getting the value for the setting 'clientId' from the Archy configuration file.
2022-11-30T23:04:23.903Z: [INFO] processing the configuration setting 'clientSecret'.
2022-11-30T23:04:23.903Z: [INFO] getting the value for the setting 'clientSecret' from the Archy configuration file.
2022-11-30T23:04:23.904Z: [INFO] processing the configuration setting 'location'.
2022-11-30T23:04:23.904Z: [INFO] getting the value for the setting 'location' from the Archy configuration file.
2022-11-30T23:04:23.905Z: [INFO]
2022-11-30T23:04:23.906Z: [INFO]
2022-11-30T23:04:23.906Z: [INFO] *****************************************************************************************
2022-11-30T23:04:23.907Z: [INFO] Runtime Input Values
2022-11-30T23:04:23.908Z: [INFO] *****************************************************************************************
2022-11-30T23:04:23.908Z: [INFO]
2022-11-30T23:04:23.909Z: [INFO]
2022-11-30T23:04:23.920Z: [INFO] version: '2.15.2'
2022-11-30T23:04:23.921Z: [INFO]
2022-11-30T23:04:23.922Z: [INFO] homeDir: 'c:\Development\genesys\archy\archyHome'
2022-11-30T23:04:23.922Z: [INFO] source - config file: 'C:\Users\waqarm.archy_config'
2022-11-30T23:04:23.923Z: [INFO]
2022-11-30T23:04:23.923Z: [INFO] running refresh command.
2022-11-30T23:04:23.925Z: [INFO] - setting the endTerminatesProcess to falsee[36m -- [ArchSession, ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:23.925Z: [INFO]
2022-11-30T23:04:23.928Z: [INFO] startup Mode: Using client ID and secret. Treating as client credentials grant.
2022-11-30T23:04:23.929Z: [INFO]
2022-11-30T23:04:23.930Z: [INFO] - setting session status to 'running'.e[36m -- [ArchSession, ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:23.931Z: [INFO] - architect scripting version: 0.34.1e[36m -- [ArchSession, ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:23.931Z: [INFO] - core environment configuration. env: 'prod', host: 'apps.mypurecloud.de', region: 'eu-central-1', clientId: 'xxxx', clientSecret: 'xxxx', isClientCredentialsOAuthClient: 'true'e[36m -- [ArchSession, ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:23.932Z: [INFO] - getting discovery properties...e[36m -- [ArchSession, ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:23.933Z: [INFO] - calling urle[36m -- [GET::https://apps.mypurecloud.de/services/discovery.properties]e[39m
2022-11-30T23:04:24.166Z: [ERROR] - ERROR! Unable to read discovery properties. Exception info: {"isRequestError":true,"response":{"code":"SELF_SIGNED_CERT_IN_CHAIN"},"status":0,"statusText":"","name":"Request Error","message":"self signed certificate in certificate chain (SELF_SIGNED_CERT_IN_CHAIN)","code":"SELF_SIGNED_CERT_IN_CHAIN","isAborted":false} ending the Session. Setting the exit code to 99.e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.172Z: [INFO] - waiting for any pending work to complete before ending the sessione[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.172Z: [INFO] - setting session status to 'ended'.e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.173Z: [INFO] - waiting for any pending work to complete before ending the sessione[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.174Z: [INFO] - ending with exit code: 99e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.174Z: [INFO] - the session is ending but is not configured to terminate the process in which it is running.e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.175Z: [INFO] - resolving session start promise.e[36m -- [ArchSession, Environment:'prod', Host:'apps.mypurecloud.de', Region:'eu-central-1', ArchSessionId:'SJ9BZDHvj']e[39m
2022-11-30T23:04:24.175Z: [ERROR] setting the Archy exit code to 116
2022-11-30T23:04:24.176Z: [ERROR] An error occurred.
2022-11-30T23:04:24.176Z: [INFO]
2022-11-30T23:04:24.183Z: [INFO]
2022-11-30T23:04:24.184Z: [INFO] *****************************************************************************************
2022-11-30T23:04:24.185Z: [INFO] Archy - Architect Yaml Flow Processor ver. 2.15.2 - Failure
2022-11-30T23:04:24.185Z: [INFO] *****************************************************************************************
2022-11-30T23:04:24.186Z: [INFO] DateTime: Wed Nov 30 2022 15:04:24 GMT-0800 (Pacific Standard Time)
2022-11-30T23:04:24.186Z: [INFO]
2022-11-30T23:04:24.187Z: [INFO] Summary
2022-11-30T23:04:24.187Z: [INFO]
2022-11-30T23:04:24.188Z: [INFO] Command: 'setup'
2022-11-30T23:04:24.188Z: [INFO]
2022-11-30T23:04:24.189Z: [INFO] Configuration Settings File
2022-11-30T23:04:24.189Z: [INFO] C:\Users\waqarm.archy_config
2022-11-30T23:04:24.189Z: [ERROR] unable to authenticate with the supplied client ID and secret. Are they valid and is the OAuth client set up with a client credentials grant?
2022-11-30T23:04:24.190Z: [INFO]
2022-11-30T23:04:24.190Z: [ERROR] error(s) encountered.
2022-11-30T23:04:24.191Z: [ERROR] - Architect Scripting errors will be listed above.
2022-11-30T23:04:24.191Z: [INFO]
2022-11-30T23:04:24.192Z: [INFO] Log: c:\Development\genesys\archy\archyHome\debug\archy-debug-2022-11-30T23.03.30.027Z.txt
2022-11-30T23:04:24.340Z: [INFO] did not fetch versions successfully ( attempt 1 out of 3 ), retrying.
2022-11-30T23:04:25.354Z: [DEBUG] version fetch error: Error: self signed certificate in certificate chain
2022-11-30T23:04:25.362Z: [INFO] execution complete.
2022-11-30T23:04:25.365Z: [ERROR]
2022-11-30T23:04:25.375Z: [ERROR] exit code: 116
2022-11-30T23:04:25.376Z: [INFO]
2022-11-30T23:04:25.377Z: [DEBUG] ensureDirectoryExists - the directory 'c:\Development\genesys\archy\archyHome\debug' exists.
2022-11-30T23:04:25.377Z: [DEBUG] Writing log contents to 'c:\Development\genesys\archy\archyHome\debug\archy-debug-2022-11-30T23.03.30.027Z.txt'.

Hi @WaqarM,
So when you say this:

Do you mean that you can use archy version or are you running archy checkVersion? The checkVersion command is the one that I had meant actually that I was also seeing the self signed cert issue. For example in your logs above it shows this:

2022-11-30T23:04:24.340Z: [INFO] did not fetch versions successfully ( attempt 1 out of 3 ), retrying.
2022-11-30T23:04:25.354Z: [DEBUG] version fetch error: Error: self signed certificate in certificate chain
2022-11-30T23:04:25.362Z: [INFO] execution complete.

which is what the checkVersion command also will attempt to do. So to answer your questions.

  1. I do not think you would be able to make a successful checkVersion call (and maybe not the curl call for the discovery properties) if there was a proxy. Archy currently does not support proxy configurations.

  2. I believe in the past there were situations similar to what you are seeing, and the users usually had a proxy configuration for their network. Im not sure if its possible to try Archy on this machine on a different network at all.

  3. The fact you can make the curl command successfully outside of Archy makes me wonder if theres some other kind of maybe firewall/security policy in place where an application needs to be allowed network permissions? That might be an additional thing to ask about. For example maybe powershell.exe or cmd.exe
    are applications that are allowed to make network requests but maybe the Archy executable needs an exception? Also you actually could try using Archy to create a flow. The refresh part of the setup is not required to use the other Archy commands. So for testing purposes you could go to the Architect UI, create a new flow, export it to YAML via the export dropdown on the button bar, and then use archy create --file PATH_TO_DOWNLOADED_YAML_FILE.

  4. There shouldnt be a need to check if the OAuth client was configured correctly. The discovery properties api call doesnt rely on anything configured within the oauth client.

Hopefully I answered your questions, but if you need any more clarification or have additional questions feel free to reach out!

Thanks,
Jon

@jon.vansteen

Hi Jon!

Thanks for the helpful email :slight_smile:

I was using archy version and archy checkVersion does indeed fail with exit code 115 (and asks to check if I am connected to a network).

I am working with our cybersecurity team and will be back after that. Meanwhile I wanted to thank you for your post.

Best,

Waqar

@WaqarM sounds good, keep me updated on what is found!

Just as an additional note, you can also use terraform with the genesyscloud_flow resource to use YAML files for publishing flows within Architect outside of the Archy CLI. You can find the documentation here for CX as Code. Im not sure if you would encounter the same problem there, but I figured I would at least suggest it in case you wanted to look into it :grinning_face_with_smiling_eyes:

Thanks,
Jon

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.