You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
upCmd.Flags().StringVar(&cmd.DevContainerImage, "devcontainer-image", "", "The container image to use, this will override the devcontainer.json value in the project")
160
173
upCmd.Flags().StringVar(&cmd.DevContainerPath, "devcontainer-path", "", "The path to the devcontainer.json relative to the project")
upCmd.Flags().StringArrayVar(&cmd.ExtraDevContainerPaths, "extra-devcontainer-path", []string{}, "The path to additional devcontainer.json files to override original devcontainer.json")
162
176
upCmd.Flags().StringVar(&cmd.EnvironmentTemplate, "environment-template", "", "Environment template to use")
Copy file name to clipboardExpand all lines: docs/pages/developing-in-workspaces/create-a-workspace.mdx
+16-11Lines changed: 16 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,15 +10,20 @@ You can create a workspace either from the DevPod CLI or through the DevPod desk
10
10
Upon successful creation, DevPod will make the development container available through the ssh host `WORKSPACE_NAME.devpod`. Alternatively, DevPod can automatically open the workspace in a locally installed IDE, such as VS Code or Intellij.
11
11
12
12
:::info
13
-
A workspace is defined through a `devcontainer.json`. If DevPod can't find one, it will automatically try to guess the programming language of your project and provide a fitting template.
13
+
A workspace is defined through a `devcontainer.json`. If DevPod can’t find one, it will automatically try to guess the programming language of your project and provide a fitting template.
14
+
:::
15
+
16
+
:::info
17
+
It is possible to override a `devcontainer.json` with specific user settings such as mounts by creating a file named `devcontainer.user.json` in the same directory as the `devcontainer.json` of the workspace.
18
+
This can be useful when customization of a versioned devcontainer is needed.
14
19
:::
15
20
16
21
### Via DevPod Desktop Application
17
22
18
-
Navigate to the 'Workspaces' view and click on the 'Create' button in the title. Enter the git repository you want to work on or select a local folder.
23
+
Navigate to the ‘Workspaces’ view and click on the ‘Create’ button in the title. Enter the git repository you want to work on or select a local folder.
19
24
20
25
:::info Add Provider
21
-
If you haven't configured a provider yet, DevPod will automatically open the provider modal for you. You can later add providers in the same way by navigating to 'Providers' > 'Add'
26
+
If you haven’t configured a provider yet, DevPod will automatically open the provider modal for you. You can later add providers in the same way by navigating to ‘Providers’ > ‘Add’
22
27
:::
23
28
24
29
You can also configure one of the additional settings:
@@ -34,19 +39,19 @@ Under the hood, the Desktop Application will call the CLI command `devpod up REP
34
39
:::
35
40
36
41
:::info Note
37
-
You can set the location of your devpod home by passing the `--devpod-home={home_path}` flag,
42
+
You can set the location of your devpod home by passing the `--devpod-home={home_path}` flag,
38
43
or by setting the env var `DEVPOD_HOME` to your desired home directory.
39
44
40
45
This can be useful if you are having trouble with a workspace trying to mount to a windows location when it should be mounting to a path inside the WSL VM.
41
46
42
-
For example: setting `devpod-home=/mnt/c/Users/MyUser/` will result in a workspace path of something like `/mnt/c/Users/MyUser/.devpod/contexts/default/workspaces/...`
47
+
For example: setting `devpod-home=/mnt/c/Users/MyUser/` will result in a workspace path of something like `/mnt/c/Users/MyUser/.devpod/contexts/default/workspaces/…`
43
48
:::
44
49
45
50
### Via DevPod CLI
46
51
47
52
Make sure to [install the DevPod CLI locally](../getting-started/install.mdx#optional-install-devpod-cli) and select a provider you would like to host the workspace on (such as local docker) via:
48
53
```
49
-
# Add a provider if you haven't already
54
+
# Add a provider if you haven’t already
50
55
devpod provider add docker
51
56
```
52
57
@@ -99,15 +104,15 @@ devpod up ghcr.io/my-org/my-repo:latest
99
104
DevPod will create the following `.devcontainer.json`:
100
105
```
101
106
{
102
-
"image": "ghcr.io/my-org/my-repo:latest"
107
+
“image”: “ghcr.io/my-org/my-repo:latest”
103
108
}
104
109
```
105
110
106
111
#### Existing local container
107
112
108
113
If you have a local container running, you can create a workspace from it by running:
109
114
```
110
-
devpod up my-workspace --source container:$CONTAINER_ID
115
+
devpod up my-workspace --source container:$CONTAINER_ID
111
116
```
112
117
113
118
This only works with the `docker` provider.
@@ -124,7 +129,7 @@ When recreating a workspace, changes only to the project path or mounted volumes
124
129
125
130
### Via DevPod Desktop Application
126
131
127
-
Navigate to the 'Workspaces' view and press on the 'More Options' button on the workspace you want to recreate. Then press 'Rebuild' and confirm to rebuild the workspace.
132
+
Navigate to the ‘Workspaces’ view and press on the ‘More Options’ button on the workspace you want to recreate. Then press ‘Rebuild’ and confirm to rebuild the workspace.
128
133
129
134
### Via DevPod CLI
130
135
@@ -141,11 +146,11 @@ Some scenarios require pulling in the latest changes from a git repository or re
141
146
142
147
### Via DevPod Desktop Application
143
148
144
-
Navigate to the 'Workspaces' view and press on the 'More Options' button on the workspace you want to reset. Then press 'Reset' and confirm.
149
+
Navigate to the ‘Workspaces’ view and press on the ‘More Options’ button on the workspace you want to reset. Then press ‘Reset’ and confirm.
145
150
146
151
### Via DevPod CLI
147
152
148
153
Run the following command to reset an existing workspace:
0 commit comments