Skip to content

Commit

Permalink
Use Ditto-UI from docker Hub in default docker-compose.yml
Browse files Browse the repository at this point in the history
* instead of the locally served UI

Signed-off-by: Thomas Jäckle <thomas.jaeckle@beyonnex.io>
  • Loading branch information
thjaeckle committed Aug 3, 2023
1 parent 58ce86b commit 8e16bb3
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
6 changes: 5 additions & 1 deletion deployment/docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,11 @@ services:
retries: 4
start_period: 120s

ditto-ui:
image: docker.io/eclipse/ditto-ui:${DITTO_VERSION:-latest}
mem_limit: 32m
restart: always

swagger-ui:
image: docker.io/swaggerapi/swagger-ui:v4.14.3
mem_limit: 32m
Expand All @@ -198,7 +203,6 @@ services:
- ./index.html:/etc/nginx/html/index.html:ro
- ../../documentation/src/main/resources/images:/etc/nginx/html/images:ro
- ../../documentation/src/main/resources/wot:/etc/nginx/html/wot:ro
- ../../ui:/etc/nginx/html/ui:ro
ports:
- "${DITTO_EXTERNAL_PORT:-8080}:80"
depends_on:
Expand Down
7 changes: 7 additions & 0 deletions deployment/docker/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,13 @@ http {
proxy_set_header X-Forwarded-User $remote_user;
}

# ui
location /ui/ {
proxy_pass http://ditto-ui:8080/;
proxy_http_version 1.1;
proxy_set_header Host $http_host;
}

# swagger
# access API doc on: /apidoc/2
location /apidoc/ {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
import org.eclipse.ditto.base.model.signals.Signal;
import org.eclipse.ditto.base.model.signals.commands.CommandResponse;
import org.eclipse.ditto.internal.utils.akka.actors.AbstractActorWithStashWithTimers;
import org.eclipse.ditto.internal.utils.akka.logging.DittoDiagnosticLoggingAdapter;
import org.eclipse.ditto.internal.utils.akka.logging.DittoLoggerFactory;
import org.eclipse.ditto.internal.utils.akka.logging.ThreadSafeDittoLoggingAdapter;
import org.eclipse.ditto.internal.utils.config.ScopedConfig;
import org.eclipse.ditto.internal.utils.tracing.DittoTracing;
import org.eclipse.ditto.internal.utils.tracing.span.SpanOperationName;
Expand Down Expand Up @@ -61,7 +61,7 @@ public abstract class AbstractEnforcerActor<I extends EntityId, S extends Signal
*/
protected static final Duration DEFAULT_LOCAL_ASK_TIMEOUT = Duration.ofSeconds(5);

protected final DittoDiagnosticLoggingAdapter log = DittoLoggerFactory.getDiagnosticLoggingAdapter(this);
protected final ThreadSafeDittoLoggingAdapter log = DittoLoggerFactory.getThreadSafeDittoLoggingAdapter(this);

protected final I entityId;
protected final E enforcement;
Expand Down

0 comments on commit 8e16bb3

Please sign in to comment.