daytonaio / devcontainer-generator

devcontainer.ai - AI generated standardized dev environments
https://devcontainer.ai/
Apache License 2.0
15 stars 12 forks source link

Add Command to Start in Daytona with Injected Devcontainer #16

Open nkkko opened 1 month ago

nkkko commented 1 month ago

Is your feature request related to a problem? Please describe. Currently, users can generate a devcontainer.json but have to manually set it up in their local environment. Integrating an automated start command for Daytona, which downloads and injects the generated devcontainer.json, will streamline the setup process for users.

Describe the solution you'd like

Describe alternatives you've considered

Additional context The command should:

  1. Handle the installation of Daytona if it's not already installed.
  2. Create a new Daytona workspace.
  3. Fetch the generated devcontainer.json using the new route with a URL hash.
  4. Pipe the fetched devcontainer.json into the workspace initialization process.

Example command:

(curl -L https://download.daytona.io/daytona/install.sh | sudo bash) && daytona create https://github.com/YOUR_REPOSITORY --code && curl https://devcontainer.ai/#https://github.com/YOUR_REPOSITORY > .devcontainer/devcontainer.json && daytona start --workspace .devcontainer/devcontainer.json