Launch and develop any web project in gitpod using ddev.
- Get the https URL of the repository you want to work with.
- (Optional) Provide database and user-generated files dumps in a (probably private) repository named
<repo>-artifacts
. For example. if you have a repository namedhttps://github.com/ddev/d10simple
the private artifacts git repository will be athttps://github.com/ddev/d10simple-artifacts
.- In that repository, check in
db.sql.gz
andfiles.tgz
and push it. This only needs to be updated when you need to update it. - For future use, you may want to implement a
ddev pull
integration, for example for Acquia or Pantheon or Platform.sh or any other of the example providers (see docs). The git technique is used here because you may not have any other initial way to get database and files into gitpod until you set something up.
- In that repository, check in
Go to DDEV gitpod launcher to launch any website project and edit and develop it in gitpod.
- If the project has a composer.json, the launcher will do a
ddev composer install
- If the project has a .ddev/config.yaml, it will be respected, otherwise a default will be auto-generated.
While developing this repo, the following tips may be helpful.
- Visit https://ddev.github.io/ddev-gitpod-launcher/.
- Enter target repo.
- Copy the "Link used by "Open in Gitpod" button:" URL
- Replace
https://github.com/ddev/ddev-gitpod-launcher/
with the branch path Eg.https://github.com/tyler36/ddev-gitpod-launcher/tree/wip-branch
This technique involves spawning debug workspaces.
- Visit https://ddev.github.io/ddev-gitpod-launcher/
- Enter target repo.
- Click "open in repo".
- Make required changes.
- In the terminal, type
gp validate
.
This will spawn a new Gitpod workspace based on the current workspace.
- All pre-builds,
init
, andcommands
are run in the new workspace as if were freshly created.. - Debugging output is shown in the original workspace.
To end the session, press Ctrl+c, or Command+c, in the original window. This will terminate the debug workspace and while maintaining the original workspace.