Ziti-console breaks when tryin to login for first time

Hi! I just installed ziti in Oracle Cloud, the service seems to be running well, but when I run the ziti-console it stops when trying to login for the first time. In the step where asksfor user and password.

Error in the console follows.

Ziti Server running on port 1408
undefined:1
Client sent an HTTP request to an HTTPS server.
^

SyntaxError: Unexpected token C in JSON at position 0
    at JSON.parse (<anonymous>)
    at Request._callback (/home/opc/.ziti/quickstart/vize/ziti-console/server.js:199:20)
    at Request.self.callback (/home/opc/.ziti/quickstart/vize/ziti-console/node_modules/request/request.js:185:22)
    at Request.emit (events.js:400:28)
    at Request.<anonymous> (/home/opc/.ziti/quickstart/vize/ziti-console/node_modules/request/request.js:1154:10)
    at Request.emit (events.js:400:28)
    at IncomingMessage.<anonymous> (/home/opc/.ziti/quickstart/vize/ziti-console/node_modules/request/request.js:1076:12)
    at Object.onceWrapper (events.js:519:28)
    at IncomingMessage.emit (events.js:412:35)
    at endReadableNT (internal/streams/readable.js:1334:12)

That does happen when the port that is supplied is actually secure (https) but the login is sending to http. I’ve not seen this myself. I wonder - can you show me the url you configured in your zac?

Does it look like mine here? is it using http or https?
image

Duh! That was it! However I think the backend shouldn’t simply die. I guess I am not the only one making that mistake.

I may have made the exact same mistake before… :slight_smile: i’ll file an issue against ziti-console!

issue filed:

Cool! You beat me at it. I added a comment on the issue, since I may be able to fix this.

Pull the latest, I added a validation to make sure the user enters a valid edge controller URL and handle the issue if an invalid one was already added in the past. Thanks!

1 Like