Edge MicroGateway - Initial configuration Error

Not applicable

Hi,

I want to configure Edge Micro Gateway(2.0.4) to our On-premise Edge ( 4.15.07)

Micro is installed on Red Hat Enterprise Linux Server release 6.6 Virtual machine ,and Edge components are also deployed on similar RHEL 6.6 VMs.

Followed the instructions mentioned here :

http://docs.apigee.com/microgateway/latest/edge-microgateway-tutorial
Part 1: Configure Edge Microgateway

and it was proceeding as mentioned in the document , till I hit the below error;


[root@apigeedev cli]# edgemicro private configure -o customer -e performancetest -r http://10.x.x.x:9001 -m http://10.x.x.x:8080 -u dev@xxx.com
current nodejs version is v4.6.0
password:
delete cache config
init config
file doesn't exist, setting up
checking for previously deployed proxies
configuring edgemicro internal proxy
deploying edgemicro internal proxy
deploying edgemicro-auth app
copy auth app into tmp dir
copy config into tmp dir
run cd /opt/edgemicro/apigee-edge-micro-2.0.4/tmp-30397civx8dfhY0Vd;npm install;cd /opt/edgemicro/apigee-edge-micro-2.0.4/cli
Give me a minute or two... this can take a while...
[Error: Error uploading resource /opt/edgemicro/apigee-edge-micro-2.0.4/tmp-30397civx8dfhY0Vd/config/locations.js: 500
{
"contexts" : [ ]
}]

Are there any version incompatibilities in the above? Please suggest

0 6 897
6 REPLIES 6

Former Community Member
Not applicable

@Ranjit

Can you please try with version 2.1.1? You can get the latest version using

npm install -g edgemicro 

Thanks for the comment Sridhar. Couple of updates from the last 2-3 hours;

1. Restarted the edge Management Server and retried the script.This time it moved a couple of steps forward and threw this error;

[Error: Invalid virtual host reference secure. Context Revision:2;APIProxy:edgemicro-auth]

2. Virtual hosts were not mandatory in 4.15.07, and the hook up script is looking up for a secure Virtual host

3.Created the Secure virtual host with port 443 and reran the script.

4.Script moved forward and threw this error;

[Error: Invalid openssl exit code: 1
% openssl req -new -sha256 -subj /CN=localhost -key /tmp/01df20c2f6b3b4dcd7b75521c8e52acbc78019c0
Unable to load config info from /usr/local/ssl/openssl.cnf]

Working on fixing the above one currently. Looks like end to end SSL Secure port needs to be configured before the Edge Micro can be hooked.

Former Community Member
Not applicable

The "edgemicro configure" is deploying a proxy called "edgemicro-auth". This proxy is meant for publicKeys, verifyAPIKeys and provides a list of products to EM. Since this is confidential information, running this over https is highly recommended. Therefore, the edgemicro-auth proxy has "secure" virtual host.

If you don't want to try with "secure", delete the edgemicro-auth proxy, rerun the "edgemicro configure" command and this time provide a "-v" option. Set "-v default". This will deploy the proxy only to default virtual host.

Deleted and reran with -v default .(Default is an http virtual host at port 9001)

# edgemicro private configure -o org1 -e performancetest -r http://XX.X.X.XXX:9001 -m http://XX.X.X.XXX:8080 -v default -u dev@org1.com

Same error here as well; Invalid openssl exit code: 1

Not applicable

Created a virtual host after Creating the keystore and uploading the Self Signed Cert to the keystore. HTPS looks good now (one way TLS) and HTTPS Virtual host verification steps return positive result.

However the Microgateway config script returns the same error..

[root@vmapigeedev06 cli]# edgemicro private configure -o orgXX -e performancetest -r http://RouterNode1_IP:9001 -m http://mp_IP:8080 -u dev@xxx.com
current nodejs version is v4.6.0
password:
delete cache config
deleted /root/.edgemicro/xxx-performancetest-config.yaml
init config
file doesn't exist, setting up
checking for previously deployed proxies
Proxy edgemicro-internal is already deployed
deploying edgemicro-auth app
copy auth app into tmp dir
copy config into tmp dir
run cd /opt/edgemicro/apigee-edge-micro-2.0.4/tmp-1253ybkK7jQYK2Pg;npm install;cd /opt/edgemicro/apigee-edge-micro-2.0.4/cli
Give me a minute or two... this can take a while...
App edgemicro-auth added to your org. Now adding resources.
App edgemicro-auth deployed.
checking org for existing vault
[Error: Invalid openssl exit code: 1
% openssl req -new -sha256 -subj /CN=localhost -key /tmp/e408f487b9aa71fa78d9022a54aa8b51780d9e58
Unable to load config info from /usr/local/ssl/openssl.cnf
]

1.Is it safe to assume that a one way TLS is sufficient for the Edge Micro configuration?

2. We have a typical 5 node set up and Edge Micro is connecting to Router1 on Node2.( Please note that the SSL self signed cert was generated from node2 itself for one way TLS configuration)

PS : Sridhar - Thanks for sharing the option to plug it without https; I would first try to configure it using the recommended https way.

Not applicable

Update : This was resolved by

export OPENSSL_CONF=/etc/pki/tls/openssl.cnf. Thanks!