Closed ivan-burazin closed 3 months ago
I can confirm yarn run dev --host
works in both Codespsces and Daytona v0.17. Are you requesting to have the command auto-run in the Dev Container, as opposed to the current state where the user manually has to open a terminal in VSCode and execute yarn run dev --host
themselves?
That was discussed in a previous PR and @Tpuljak suggested not to, so the user has full control over start/stop.
yarn run dev --host
should definitely not be part of the devcontainer commands. That's something that the user should run themselves.
That being said, @osslate, what I think @ivan-burazin is referring to is this https://github.com/daytonaio/docs/blob/main/.devcontainer/welcome-message.txt
Ah okay. In terms of implementing that change, we could either:
start
/dev
scripts in package.json
to yarn run dev -- --host
welcome-message.txt
to yarn start -- --host
or yarn run dev -- --host
Any preference?
Ah okay. In terms of implementing that change, we could either:
- Change the
start
/dev
scripts inpackage.json
toyarn run dev -- --host
- Change the instructions in
welcome-message.txt
toyarn start -- --host
oryarn run dev -- --host
Any preference?
Let's change it in package.json
I suggest ensuring that the following command can be used in both Codespaces and Daytona: yarn run dev --host.
If it is compatible, consider editing the development container configuration to include this command. Here's how you can do it:
Check Compatibility in Codespaces:
Open your Codespaces environment. Run the command yarn run dev --host in the terminal. Verify if the command executes successfully. Check Compatibility in Daytona:
Open your Daytona environment. Run the command yarn run dev --host in the terminal. Verify if the command executes successfully. Edit Development Container Configuration:
If the command works in both environments, update the development container configuration (devcontainer.json)