From d7265f0c412948ac17761ee34e716a3b559dacb7 Mon Sep 17 00:00:00 2001 From: damik3 Date: Fri, 9 Feb 2024 15:29:20 +0200 Subject: [PATCH] [main-fix] Localhost connections are now supported from the notebooks. --- docker-compose.yml | 4 +++- readme.md | 10 +++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index 721fb2d..782b7f6 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -7,4 +7,6 @@ services: jupyter: build: jupyter ports: - - "8888:8888" \ No newline at end of file + - "8888:8888" + extra_hosts: + - "host.docker.internal:host-gateway" \ No newline at end of file diff --git a/readme.md b/readme.md index 3b14e8e..ee486c7 100644 --- a/readme.md +++ b/readme.md @@ -30,6 +30,8 @@ Change this part build: jupyter ports: - "8888:8888" + extra_hosts: + - "host.docker.internal:host-gateway" ``` to this: @@ -39,8 +41,14 @@ to this: build: jupyter ports: - "8888:8888" + extra_hosts: + - "host.docker.internal:host-gateway" volumes: - /path/to/custom/input/files:/home/jovyan/files ``` -Your files should be located in a known location on your machine (referred to as `/path/to/custom/input/files`). These files will be accessible within your BDE under the path files (for example, `files/my.custom.file`). \ No newline at end of file +Your files should be located in a known location on your machine (referred to as `/path/to/custom/input/files`). These files will be accessible within your BDE under the path files (for example, `files/my.custom.file`). + +## Connecting to a database on localhost + +Use `host.docker.internal` instead of `localhost`.