fabric8io / fabric8-ipaas

This repository contains the iPaaS related apps that can be run as part of the fabric8 platform on any OpenShift v3 and Kubernetes environment
14 stars 33 forks source link

Support running apiman on SSL #274

Closed KurtStam closed 8 years ago

KurtStam commented 8 years ago

The Openshift console runs on HTTPS, so if we want to link to the apiman console then the apiman console needs to run under SSL.

KurtStam commented 8 years ago

Running Apiman on SSL

If you'd like to run apiman over SSL then first double check you have the following system parameters set correctly:

KUBERNETES_DOMAIN = vagrant.f8 KUBERNETES_NAMESPACE = default

Now you can run:

mvn -Pssl clean compile

to generate a selfsigned certificate for hostname 'apiman-default.vagrant.f8', in the target/secret directory, and it adds it as a secret called 'apiman-keystore' in the current 'default' namespace.

Now to deploy apiman with SSL support you execute

mvn -Pssl -Pf8-local-deploy

which mounts the secrets in the /secret directory in the pod and Jetty will start up using the SslConnectionFactory, based to the system parameter 'APIMAN_SSL' being set to 'true'. See also the properties set in the maven 'ssl' profile

true The fabric8-maven-plugin aready creates a route but you want a passthrough route so run oc delete route apiman oc create route passthrough apiman --service apiman Now the apiman should run at https://apiman.vagrant.f8/apiman/apimanui
KurtStam commented 8 years ago

https://github.com/fabric8io/fabric8-ipaas/pull/275