mirror of
https://github.com/frappe/frappe_docker.git
synced 2024-11-08 14:21:05 +00:00
feat: allow devcontainer vscode configuration
This commit is contained in:
parent
0af1302485
commit
aadb0a8139
4
development/.vscode/settings.json
vendored
4
development/.vscode/settings.json
vendored
@ -1,4 +0,0 @@
|
|||||||
{
|
|
||||||
"python.pythonPath": "frappe-bench/env/bin/python",
|
|
||||||
"debug.node.autoAttach": "disabled"
|
|
||||||
}
|
|
@ -28,6 +28,12 @@ Copy example devcontainer config from `devcontainer-example` to `.devcontainer`
|
|||||||
cp -R devcontainer-example .devcontainer
|
cp -R devcontainer-example .devcontainer
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Copy example vscode config for devcontainer from `development/vscode-example` to `development/.vscode`. This will setup basic configuration for debugging.
|
||||||
|
|
||||||
|
```shell
|
||||||
|
cp -R development/vscode-example development/.vscode
|
||||||
|
```
|
||||||
|
|
||||||
## Use VSCode Remote Containers extension
|
## Use VSCode Remote Containers extension
|
||||||
|
|
||||||
For most people getting started with Frappe development, the best solution is to use [VSCode Remote - Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers).
|
For most people getting started with Frappe development, the best solution is to use [VSCode Remote - Containers extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.remote-containers).
|
||||||
@ -208,6 +214,8 @@ You can now login with user `Administrator` and the password you choose when cre
|
|||||||
|
|
||||||
To debug workers, skip starting worker with honcho and start it with VSCode debugger.
|
To debug workers, skip starting worker with honcho and start it with VSCode debugger.
|
||||||
|
|
||||||
|
For advance vscode configuration in the devcontainer, change the config files in `development/.vscode`.
|
||||||
|
|
||||||
## Developing using the interactive console
|
## Developing using the interactive console
|
||||||
|
|
||||||
You can launch a simple interactive shell console in the terminal with:
|
You can launch a simple interactive shell console in the terminal with:
|
||||||
|
@ -12,6 +12,7 @@
|
|||||||
"args": [
|
"args": [
|
||||||
"frappe", "serve", "--port", "8000", "--noreload", "--nothreading"
|
"frappe", "serve", "--port", "8000", "--noreload", "--nothreading"
|
||||||
],
|
],
|
||||||
|
"pythonPath": "${workspaceFolder}/frappe-bench/env/bin/python",
|
||||||
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
||||||
"env": {
|
"env": {
|
||||||
"DEV_SERVER": "1"
|
"DEV_SERVER": "1"
|
||||||
@ -25,6 +26,7 @@
|
|||||||
"args": [
|
"args": [
|
||||||
"frappe", "worker", "--queue", "default"
|
"frappe", "worker", "--queue", "default"
|
||||||
],
|
],
|
||||||
|
"pythonPath": "${workspaceFolder}/frappe-bench/env/bin/python",
|
||||||
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
||||||
"env": {
|
"env": {
|
||||||
"DEV_SERVER": "1"
|
"DEV_SERVER": "1"
|
||||||
@ -38,6 +40,7 @@
|
|||||||
"args": [
|
"args": [
|
||||||
"frappe", "worker", "--queue", "short"
|
"frappe", "worker", "--queue", "short"
|
||||||
],
|
],
|
||||||
|
"pythonPath": "${workspaceFolder}/frappe-bench/env/bin/python",
|
||||||
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
||||||
"env": {
|
"env": {
|
||||||
"DEV_SERVER": "1"
|
"DEV_SERVER": "1"
|
||||||
@ -51,6 +54,7 @@
|
|||||||
"args": [
|
"args": [
|
||||||
"frappe", "worker", "--queue", "long"
|
"frappe", "worker", "--queue", "long"
|
||||||
],
|
],
|
||||||
|
"pythonPath": "${workspaceFolder}/frappe-bench/env/bin/python",
|
||||||
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
"cwd": "${workspaceFolder}/frappe-bench/sites",
|
||||||
"env": {
|
"env": {
|
||||||
"DEV_SERVER": "1"
|
"DEV_SERVER": "1"
|
||||||
@ -61,6 +65,7 @@
|
|||||||
"type": "python",
|
"type": "python",
|
||||||
"request": "launch",
|
"request": "launch",
|
||||||
"program": "/home/frappe/.local/bin/honcho",
|
"program": "/home/frappe/.local/bin/honcho",
|
||||||
|
"pythonPath": "${workspaceFolder}/frappe-bench/env/bin/python",
|
||||||
"cwd": "${workspaceFolder}/frappe-bench",
|
"cwd": "${workspaceFolder}/frappe-bench",
|
||||||
"console": "internalConsole",
|
"console": "internalConsole",
|
||||||
"args": [
|
"args": [
|
3
development/vscode-example/settings.json
Normal file
3
development/vscode-example/settings.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"debug.node.autoAttach": "disabled"
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user