|
|
@@ -8,9 +8,7 @@ Hue can run in one line via the `docker` command (but needs to be configured to
|
|
|
|
|
|
Directly boot the image:
|
|
|
|
|
|
-```
|
|
|
-docker run -it -p 8888:8888 gethue/hue:latest
|
|
|
-```
|
|
|
+ docker run -it -p 8888:8888 gethue/hue:latest
|
|
|
|
|
|
Hue should then be up and running on your default Docker IP on the port 8888, so usually [http://127.0.0.1:8888](http://127.0.0.1:8888).
|
|
|
|
|
|
@@ -22,36 +20,27 @@ This will start a Hue server as well as a MySQL database by default. Only the My
|
|
|
|
|
|
Assuming we have a local ``hue.ini`` as shown in the previous section:
|
|
|
|
|
|
-```
|
|
|
-cd tools/docker/hue
|
|
|
-```
|
|
|
+ cd tools/docker/hue
|
|
|
|
|
|
Edit `conf/hue-overrides.ini` and ucomment the MySql section in `[[database]]`.
|
|
|
|
|
|
Then:
|
|
|
|
|
|
-```
|
|
|
-docker-compose up -d
|
|
|
-```
|
|
|
+ docker-compose up -d
|
|
|
|
|
|
And to stop:
|
|
|
|
|
|
-```
|
|
|
-docker-compose down
|
|
|
-```
|
|
|
+ docker-compose down
|
|
|
|
|
|
**Note**
|
|
|
If http://127.0.0.1:8888 does not work, get the IP of the docker container with:
|
|
|
-```
|
|
|
-sudo docker ps
|
|
|
-CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
|
|
|
-4064b02b42c9 gethue/hue "./startup.sh" About a minute ago Up About a minute 0.0.0.0:8888->8888/tcp awesome_wiles
|
|
|
-```
|
|
|
|
|
|
-```
|
|
|
-docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' 4064b02b42c9
|
|
|
-172.17.0.2
|
|
|
-```
|
|
|
+ sudo docker ps
|
|
|
+ CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
|
|
|
+ 4064b02b42c9 gethue/hue "./startup.sh" About a minute ago Up About a minute 0.0.0.0:8888->8888/tcp awesome_wiles
|
|
|
+
|
|
|
+ docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' 4064b02b42c9
|
|
|
+ 172.17.0.2
|
|
|
|
|
|
So in our case [http://172.17.0.2:8888](http://172.17.0.2:8888).
|
|
|
|
|
|
@@ -64,16 +53,13 @@ The default ini is used for configuration at the image build time (e.g. which ap
|
|
|
|
|
|
In order to be useful, configure Hue at runtime to point to external services. The simplified ini [``hue-overrides.ini``](/tools/docker/hue/conf/hue-overrides.ini) can be edited before starting Hue via:
|
|
|
|
|
|
-```
|
|
|
-cd tools/docker/hue
|
|
|
-cp conf/hue-overrides.ini hue.ini
|
|
|
-```
|
|
|
+ cd tools/docker/hue
|
|
|
+ cp conf/hue-overrides.ini hue.ini
|
|
|
|
|
|
Edit the database settings in `hue.ini` for one of these two databases. Do not forget to create a 'hue' database too.
|
|
|
|
|
|
Postgres
|
|
|
|
|
|
-```
|
|
|
[desktop]
|
|
|
[[database]]
|
|
|
engine=postgresql_psycopg2
|
|
|
@@ -82,11 +68,10 @@ Postgres
|
|
|
user=hue
|
|
|
password=hue
|
|
|
name=hue
|
|
|
-```
|
|
|
|
|
|
MySql
|
|
|
|
|
|
-```
|
|
|
+
|
|
|
[desktop]
|
|
|
[[database]]
|
|
|
engine=mysql
|
|
|
@@ -95,7 +80,6 @@ MySql
|
|
|
user=root
|
|
|
password=secret
|
|
|
name=hue
|
|
|
-```
|
|
|
|
|
|
If you want to be able to query a database out of the box, update the connector interpreters accordingly, e.g.:
|
|
|
|
|
|
@@ -116,9 +100,7 @@ If you want to be able to query a database out of the box, update the connector
|
|
|
|
|
|
Then start the Hue server:
|
|
|
|
|
|
-```
|
|
|
-docker run -it -p 8888:8888 -v $PWD/hue.ini:/usr/share/hue/desktop/conf/z-hue.ini gethue/hue
|
|
|
-```
|
|
|
+ docker run -it -p 8888:8888 -v $PWD/hue.ini:/usr/share/hue/desktop/conf/z-hue.ini gethue/hue
|
|
|
|
|
|
*Note*
|
|
|
|
|
|
@@ -134,23 +116,18 @@ Just pull the latest from the Internet or build it yourself from the Hue reposit
|
|
|
|
|
|
### Pull the image from Docker Hub
|
|
|
|
|
|
-```
|
|
|
-sudo docker pull gethue/hue:latest
|
|
|
-```
|
|
|
+ docker pull gethue/hue:latest
|
|
|
|
|
|
### Build the image
|
|
|
|
|
|
Directly from Github source:
|
|
|
|
|
|
-```
|
|
|
-sudo docker build https://github.com/cloudera/hue.git#master -t hue -f tools/docker/hue/Dockerfile
|
|
|
-```
|
|
|
+ docker build https://github.com/cloudera/hue.git#master -t hue -f tools/docker/hue/Dockerfile
|
|
|
+
|
|
|
|
|
|
Or from a cloned local Hue:
|
|
|
|
|
|
-```
|
|
|
-sudo docker build . -t hue -f tools/docker/hue/Dockerfile
|
|
|
-```
|
|
|
+ docker build . -t hue -f tools/docker/hue/Dockerfile
|
|
|
|
|
|
**Note**
|
|
|
|
|
|
@@ -158,6 +135,4 @@ Feel free to replace `-t hue` in all the commands by your own docker repository
|
|
|
|
|
|
**Push the image to the container registry**
|
|
|
|
|
|
-```
|
|
|
-docker push docker.io/gethue/hue:latest
|
|
|
-```
|
|
|
+ push docker.io/gethue/hue:latest
|