* Fix simple UI docker image Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * Change workdir only when necessary Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * artifactrepo also in /app Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * add also /app in volume config Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * fix artifact repo to be in /app and also fix volumes in docker compose Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * Delete hawkbit-simple-ui/src/main/java/org/eclipse/hawkbit/ui/simple/config/AtmosphereConfig.java Signed-off-by: Stanislav Trailov <stanislav.trailov@bosch.com> * remove changes from download&install phase only Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * fix volume for postgres compose files Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * switch back to /app workspace also in db init * finalize absolut paths in db init dockerfiles * artifactrepo to relative path Signed-off-by: strailov <Stanislav.Trailov@bosch.io> * use relative path in dbinit dockerfiles Signed-off-by: strailov <Stanislav.Trailov@bosch.io> --------- Signed-off-by: strailov <Stanislav.Trailov@bosch.io> Signed-off-by: Stanislav Trailov <stanislav.trailov@bosch.com>
hawkBit Docker
Overview
This folder contains example Docker build and Docker Compose files to build and start the hawkBit as monolith or as microservices.
Build
You could build the hawkbit Docker images following the README.md instructions.
Start
You can start hawkbit as a Docker Container (only monolith) or with Docker Compose
A: Docker Container (only as monolith)
Note: You need to have Docker installed on your machine.
Start the hawkBit Update Server (monolith) as a single container (with embedded H2, if you configure a different database, e.g. MySQL or PostgreSQL, you should start it separately):
$ docker run -d -p 8080:8080 hawkbit/hawkbit-update-server:latest
B: Docker Compose
Note: You need to have Docker Compose installed on your machine.
Start the hawkBit Update Server (monolith) together with an MySQL and RabbitMQ instance as containers (Requires Docker Compose to be installed)
$ docker compose -f mysql/docker-compose-monolith-mysql.yml up
With the upper command CTRL+C shuts down all services. Add '-d' at the end to start all into detached mode:
$ docker compose -f mysql/docker-compose-monolith-mysql.yml up -d
Then stop all services with:
$ docker compose -f mysql/docker-compose-monolith-mysql.yml down
You could, also start it in different flavours, with UI or in microservices mode (see Docker Compose files in mysql and postgres folders). For instance to start with PostgreSQL, with RabbitMQ, in microservices mode and with UI you could use:
$ docker compose -f postgres/docker-compose-micro-services-with-ui-postgres.yml up
Access
| Service / Container | URL | Login | A | B |
|---|---|---|---|---|
| hawkBit Update Server | http://localhost:8080/ | admin:admin | ✓ | ✓ |
| MySQL | localhost:3306/hawkbit | root | ✓ | |
| RabbitMQ | http://localhost:15672 | guest:guest | ✓ |
Configuration
You can override application.properties by setting an environment variable SPRING_APPLICATION_JSON to the hawkbit container, e.g.:
hawkbit:
image: "hawkbit/hawkbit-update-server:latest"
environment:
SPRING_APPLICATION_JSON: '{
"spring.datasource.url": "jdbc:mariadb://mysql:3306/hawkbit",
"spring.rabbitmq.host": "rabbitmq",
"spring.rabbitmq.username": "guest",
"spring.rabbitmq.password": "guest",
# should remove default admin/admin user
"hawkbit.security.user.admin.tenant": "#{null}",
"hawkbit.security.user.admin.password": "#{null}",
"hawkbit.security.user.admin.roles": "#{null}",
# should add hawkbit/isAwesome! user
"hawkbit.security.user.hawkbit.tenant": "DEFAULT",
"hawkbit.security.user.hawkbit.password": "{noop}isAwesome!",
"hawkbit.security.user.hawkbit.roles": "TENANT_ADMIN"
}'