Problem to configure edgemicro with private

mrios
Participant IV

I've an AIO instance running Apigee 18.01 and I'm following the instructions to setup edgemicro. However, when I provide the information to configure edgemicro I get this error.

$ edgemicro private configure -o myorg -e test -u me@company.com -r http://10.10.10.10:9001 -m http://10.10.10.10:8080 -v default
current nodejs version is v6.14.0
current edgemicro version is 2.5.16
password:
delete cache config
deleted /home/me/.edgemicro/myorg-test-config.yaml
init config
file doesn't exist, setting up
Proxy edgemicro-internal is already deployed
edgemicro-auth  is already deployed
checking org for existing KVM
KVM already exists in your org
{ Error: cannot GET http://10.10.10.10:9001/edgemicro-auth/publicKey (404)
    at translateError (/usr/lib/node_modules/edgemicro/cli/lib/cert-lib.js:393:11)
    at Request._callback (/usr/lib/node_modules/edgemicro/cli/lib/cert-lib.js:428:11)
    at Request.self.callback (/usr/lib/node_modules/edgemicro/node_modules/request/request.js:186:22)
    at emitTwo (events.js:106:13)
    at Request.emit (events.js:191:7)
    at Request.<anonymous> (/usr/lib/node_modules/edgemicro/node_modules/request/request.js:1163:10)
    at emitOne (events.js:96:13)
    at Request.emit (events.js:188:7)
    at IncomingMessage.<anonymous> (/usr/lib/node_modules/edgemicro/node_modules/request/request.js:1085:12)
    at IncomingMessage.g (events.js:292:16)
  text: '{"fault":{"faultstring":"Unable to identify proxy for host: 10.10.10.10:9001 and url: \\/edgemicro-auth\\/publicKey","detail":{"errorcode":"messaging.adaptors.http.flow.ApplicationNotFound"}}}' }

In the AIO instance I can see 2 proxies deployed by edgemicro: edgemicro-auth and edgemicro-internal. I noticed that if I add the Host header with the value that the default virtual host has the call works.

curl -X GET http://10.10.10.10:9001/edgemicro-auth/publicKey -H "Host:my.virtual.host.com"

Should I add that header to some configuration file or should it work without that?

Any advice about how to continue with the setup?

0 1 190
1 REPLY 1

mrios
Participant IV

My 18.01 instance had an alias for each virtual host.

I changed it to use as an alias the IP:port and it worked.

Now my VH looks like this

{
    "hostAliases": [
        "10.10.10.10:9001"
    ],
    "interfaces": [],
    "listenOptions": [],
    "name": "default",
    "port": "9001",
    "retryOptions": []
}