Please go to http://github.com/odpi/egeria to read about Egeria, where you will also ongoing work around deployment of a
If you are interested in directly contributing this capability to Apache Ranger please feel free - and ideally get in touch so we can work on merging in the code from Egeria :-)
This project objective is to make it easy to run a simple ranger install, locally, in order to test & experiment with new plugins, or minor code enhancements.
This code is currently hosted on github at https://github.com/planetf1/ranger-docker but the hope is to integrate it into the Apache Ranger project
Update
- MariaDB now listens externally on port 33306 to avoid clash with a locally running database
- Download and build ranger itself, from git
- Configure & launch ranger admin server
- Solr active/running
- No ranger plugins setup
- little parameterization -- all hardcoded
- No data container
- ranger-admin - the customized ranger image, also runs solr
- mariadb - based off mariadb on docker hub
docker-compose upMariadb will configure & start, as will ranger including solr. The process will take around 1-2 minutes in addition to any download time.
You can then connect to Ranger as usual for example at http://mymachine:6080/
An example of how to run ranger under docker using MS Azure with very few steps -- assumes an existing Azure Account
- Install Docker & GIT if not already done
Go to http://www.docker.com & install docker for Windows, Mac or Linux following the instructions
Also install git from https://git-scm.com/download/
- Create an Azure container service
Lots of possible command options, but to default to US-West & basic ubuntu server:
docker-machine create --driver azure --azure-subscription-id aaaaaaaa-bbbb-cccc-dddd-eeeeee nigeldocker
- Configure the environment for the new docker machine:
docker-machine env nigeldocker
This will return a command to run as the last line which should be run such as
FOR /f "tokens=*" %i IN ('docker-machine env nigeldocker') DO @%i
- Now get hold of the ranger docker source in git
git clone https://github.com/planetf1/ranger-docker.git
- Build and run the docker images
cd ranger-docker docker-compose up
- Checking the docker container id - needed for subsequent interaction with the container
ibmuser@ibmvm:~$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 1a2ed045306c rangerdocker_ranger-admin "/bin/sh -c /opt/ran…" 2 hours ago Up 2 hours 0.0.0.0:6080->6080/tcp, 0.0.0.0:6083->6083/tcp, 0.0.0.0:6182-6183->6182-6183/tcp rangerdocker_ranger-admin_1 2abd3e403c25 rangerdocker_mariadb "docker-entrypoint.s…" 2 hours ago Up 2 hours 0.0.0.0:3306->3306/tcp rangerdocker_mariadb_1
- >Deploying a ranger plugin (for resource lookup)
An example:
docker exec -it 1a2ed045306c mkdir /opt/ranger-2.0.0-SNAPSHOT-admin/ews/webapp/WEB-INF/classes/ranger-plugins/gaian docker cp ./ranger-gaian-plugin-1.0.0-SNAPSHOT.jar 1a2ed045306c:/opt/ranger-2.0 .0-SNAPSHOT-admin/ews/webapp/WEB-INF/classes/ranger-plugins/gaian
- To look around the docker install for debugging etc:
docker exec -it 1a2ed045306c /bin/bash
- Use the ranger UI
Open up a web browser and go to http://mydockermachineip:6080/
Docker images can also be run locally, remotely, or using other cloud providers
Please add any feedback in the issue tracker on github. Or if it relates to integration into ranger use RANGER-1572- See the main ranger community at http://ranger.apache.org
- Dockerize - This script can be used to synchronize between different docker containers by waiting for a particular network port to become available. See more at https://github.com/jwilder/dockerize -- this is also linked into by the official docker documentation as a best practice