-
Notifications
You must be signed in to change notification settings - Fork 889
feat: one-line install script #1924
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Gonna work with @kylecarbs to get Edit: done |
install.sh
Outdated
# MacOS releases are packaged as .zip | ||
case $OS in | ||
darwin) STANDALONE_ARCHIVE_FORMAT=zip ;; | ||
*) STANDALONE_ARCHIVE_FORMAT=tar.gz ;; | ||
esac |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not super happy with this implementation, had to make some adjustments since our OSX releases are published as .zips
env: | ||
SHELLCHECK_OPTS: --external-sources |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This resolved some warnings around unspecified inputs. See https://www.mankier.com/1/shellcheck#-x and koalaman/shellcheck#902
The error was only for `/etc/os-release` in the script
$ make lint/shellcheck
In install.sh line 424:
. /etc/os-release
^-------------^ SC1091: Not following: /etc/os-release was not specified as input (see shellcheck -x).
In install.sh line 450:
. /etc/os-release
^-------------^ SC1091: Not following: /etc/os-release was not specified as input (see shellcheck -x).
```sh | ||
coder server --dev | ||
``` | ||
|
||
## docker-compose |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@khorne3 I feel like this section is a bit too long. Thoughts on stopping after docker-compose up
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think after docker-compose up
say, "Follow the on-screen instructions" so people aren't left hanging and then omit the remainder
ae88c6c
to
a16a04a
Compare
install.sh
Outdated
--prefix <dir> | ||
Sets the prefix used by standalone release archives. Defaults to ~/.local | ||
The release is unarchived into ~/.local/lib/coder-X.X.X | ||
and the binary symlinked into ~/.local/bin/coder | ||
To install system wide pass ---prefix=/usr/local |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kylecarbs actually, what do you think of defaulting to /usr/local/bin
? code-server defaults to the home-directory one, but it's often not in PATH. helm's install script does this, so I wouldn't consider it too invasive.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done in 6879752
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* feat: one-line install script * remove homebrew support * remove arch linux * use proper filename for packages * fix variable format * fix systemd instructions * fixes to standalone script * fix missing var bugs * fix standalone install * fix for MacOS * format * fix armv7 assets and zips * remove windows * update install docs * support external sources with shellcheck * shfmt * add external sources to GitHub action & unfold * change wording * first template docs * default to /usr/local instead * add option for binary name
Fixes #1852 The install script was originally used for code-server so many similar elements were used. I took inspiration from the code-server and
kubectx
docs for the installation guide as well.Test it:
Dry run
curl -L https://coder.com/install.sh | sh -s -- --dry-run
Install