This directory contains environments useful for Metron developers. These environments are not intended for proof-of-concept, testing, or production use. These are extremely resource constrained and cannot support anything beyond the most basic work loads.
The development boxes are designed to be spun up and destroyed on a regular basis as part of the development cycle. In order to avoid the overhead of re-downloading many of the heavy platform dependencies, Vagrant can use the vagrant-cachier plugin to store package caches between builds. If the plugin has been installed to your vagrant it will be used, and packages will be cached in ~/.vagrant/cache.
The development environment can be set up to authenticate against Knox’s demo LDAP.
A couple notes
To setup this up, start full dev.
In Ambari, add the Knox service (Actions -> +Add Service). Accept all defaults and let it install. The configs that will be set how we need by default are:
In the Knox configuration, go to “Advanced users-ldif”. We have a custom ldif file “knox-demo-ldap.ldif” in “metron-deployment/development” that contains a customized variant of the users and groups defined here. Replace the default ldif configuration with the contents of “knox-demo-ldap.ldif”
Now, when you go to Swagger or the UIs, you should be able to give a user and password. “admin” will have the roles ROLE_ADMIN and ROLE_USER, which can be verified via the “/whoami/roles” endpoint in Swagger. Similarly, there is a user “sam” that only has ROLE_USER. A third user, “tom” has neither role.