Merge pull request #194 from ckan/debugpy-fix
update instructions, cache dir for VS Code debugging
This commit is contained in:
commit
31e39c8806
@ -165,6 +165,10 @@ development instance in your `.env` file:
|
||||
USE_DEBUGPY_FOR_DEV=true
|
||||
```
|
||||
|
||||
Next run the install script to install debugpy:
|
||||
|
||||
docker compose -f docker-compose.dev.yml run -u root ckan-dev ./install_src.sh
|
||||
|
||||
Then start the containers in [development mode](#development-mode) and launch VS Code.
|
||||
|
||||
In VS Code:
|
||||
@ -172,8 +176,9 @@ In VS Code:
|
||||
1. Install the "Dev Container" extension: press CTRL+SHIFT+X, type "dev container", click "install"
|
||||
2. Click the "Open a Remote Window" button in the bottom-left of the VS Code window
|
||||
3. Click "Attach to Running Container..." and select your ckan-dev container, e.g. "ckan-docker-ckan-dev-1"
|
||||
4. Click the "Run and Debug" icon on the left panel then "create a launch.json", select "Python Debugger", "Remote Attach", host "localhost" and port "5678"
|
||||
5. Press F5 or click the "Run" menu and "Start Debugging"
|
||||
4. Click the "Run and Debug" icon on the left panel and choose to install the "Python Debugger"
|
||||
5. Click "create a launch.json", select "Python Debugger", "Remote Attach", host "localhost" and port "5678"
|
||||
6. Press F5 or click the "Run" menu and "Start Debugging"
|
||||
|
||||
You can now set breakpoints and remote debug your CKAN development instance.
|
||||
|
||||
|
||||
@ -5,7 +5,7 @@ volumes:
|
||||
pip_cache:
|
||||
site_packages:
|
||||
local_bin:
|
||||
vscode_server:
|
||||
home_dir:
|
||||
|
||||
services:
|
||||
|
||||
@ -29,7 +29,7 @@ services:
|
||||
- pip_cache:/root/.cache/pip
|
||||
- site_packages:/usr/local/lib/python3.10/site-packages
|
||||
- local_bin:/usr/local/bin
|
||||
- vscode_server:/root/.vscode-server
|
||||
- home_dir:/srv/app/
|
||||
restart: unless-stopped
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000"]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user