daytona icon indicating copy to clipboard operation
daytona copied to clipboard

QuickStart Installation Docs

Open conradwt opened this issue 11 months ago • 3 comments

Describe the bug

When I try to use the command, curl -sf -L https://download.daytona.io/daytona/get-server.sh | sudo bash` to install to /uss/ocal/bin, it installs it to /Users//bin.

To Reproduce Steps to reproduce the behavior:

  1. curl -sf -L https://download.daytona.io/daytona/get-server.sh | sudo bash
  2. which -a daytona

Expected behavior

➜ curl -sf -L https://download.daytona.io/daytona/get-server.sh | sudo bash
Password:
Downloading server from https://download.daytona.io/daytona/latest/daytona-darwin-arm64
Installing server to /usr/local/bin

Actual behavior

➜ curl -sf -L https://download.daytona.io/daytona/get-server.sh | sudo bash
Password:
Downloading server from https://download.daytona.io/daytona/latest/daytona-darwin-arm64
Installing server to /Users/<username>/bin

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: macOS 14.3.1
  • Browser: Chrome
  • Daytona Version: v0.2.0

Additional context

The other issue is that it's still installing the binary executable as root.

conradwt avatar Mar 09 '24 07:03 conradwt

HI @conradwt!

Yes we updated recently script and README on this per issue in https://github.com/daytonaio/daytona/issues/103

What it does now, is first check few of those known user paths in $PATH and tries to install it there.

Also on your other issue, there is a change in the README, as it is preferable now to run it without sudo. https://github.com/daytonaio/daytona?tab=readme-ov-file#quick-start

Let me know if this works for you, or is there anything else we overlooked.

Thx!

zzorica avatar Mar 09 '24 07:03 zzorica

@zzorica I typically install all 3rd party binaries in /usr/local/bin that require sudo for installation. $HOME/bin is reserved for my personal scripts.

conradwt avatar Mar 09 '24 10:03 conradwt

@conradwt I understand the issue you're having.

Maybe the best of both worlds would be to allow a destination override with an env variable.

E.g. we can check if DESTIONATION is defined, if so, skip the paths check.

Does that make sense?

Edit: example usage:

DESTINATION=/path/to/dir curl -sf -L https://download.daytona.io/daytona/get-server.sh | sudo bash

Tpuljak avatar Mar 09 '24 12:03 Tpuljak

Hi @conradwt! Sorry for the wait...

When you can, could you test a new script version and see how that one plays for you?

curl -sf -L https://raw.githubusercontent.com/daytonaio/daytona/95640a2e5d61e8914a506bfce23da847f982ab5b/hack/get-server.sh | bash

zzorica avatar Mar 11 '24 20:03 zzorica

@zzorica I would be happy to test this new script later today and I'll report back.

conradwt avatar Mar 11 '24 21:03 conradwt

@conradwt we merged this change. So you can test it normally now:

curl -sf -L https://download.daytona.io/daytona/get-server.sh | bash

Also we updated README on the quick start.

Let us know if this suits you so we can close the issue. Thx!

zzorica avatar Mar 12 '24 21:03 zzorica

@zzorica Yes, I like that the default location is /usr/local/bin here. Thus, I'm going to close this issue as resolved.

conradwt avatar Mar 12 '24 22:03 conradwt