Code Monkey home page Code Monkey logo

sail's Introduction

sail

Deprecated: The workflow of developing from project-defined environments has been adopted for organizations in Coder Enterprise.


"Open Issues" MIT license AUR version Discord

sail is a universal workflow for reproducible, project-defined development environments.

Basically, it lets you open a repo in a VS Code window with a Docker-based backend.

With the browser extension, you can open a repo right from GitHub or GitLab, or you can do

sail run cdr/sshcode

to open a project right from the command line.

Browser extension demo:

Demo

Features

  • No more "It works on my machine", everyone working on the same project is working in the same environment.
  • Stop duplicating effort, source-control and collaborate on the environment.
  • Instant set-up, open an IDE for a project straight from GitHub or GitLab.

Documentation

Documentation is available at https://sail.dev/docs.

Or, you can read it in it's markdown form at site/content/docs.

Quick Start

Requirements

Currently Sail supports both Linux and MacOS. Windows support is planned for a future release.

Before using Sail, there are several dependencies that must be installed on the host system:

Install

For simple, secure and fast installation, the following command will install the latest version of sail for your OS and architecture into /usr/local/bin. You will need to have /usr/local/bin in your $PATH in order to use it.

curl https://sail.dev/install.sh | bash

For Arch users, there is an official AUR package.

Verify the Installation

To verify Sail is properly installed, run sail --help on your system. If everything is installed correctly, you should see Sail's help text.

Run

You should now be able to run sail run cdr/sail from your terminal to start an environment designed for working on the Sail repo.

Browser Extension

To open GitHub or GitLab projects in a Sail environment with a single click, see the browser extension install instructions.

Learn More

Additional docs covering concepts and configuration can be found at https://sail.dev/docs.

sail's People

Contributors

ammario avatar coadler avatar deansheather avatar dougnukem avatar kylecarbs avatar lucacasonato avatar nhooyr avatar scsmithr avatar teddy-codes avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sail's Issues

sail rm should kill proxy

This flow can leak proxies:

  1. sail run codercom/sail
  2. sail rm codercom/sail
  3. sail run codercom/sail

Two proxies will be running and the first one will be leaked

subcommand to remove containers

sail wasn't updating my code-server. I assume its because I have sails using the binary still. should be clear on how to resolve this

ext install alias

code-server --install-extension is too long.. Let's put an install_ext script in ubuntu-dev that proxies.

Install VS Code extensions from hat

In an ideal world, projects specify what extensions they require via code-server --install-extension, and hats are able to personalize the same way.

In order for this to be practical:

  • we must add support in sail for a command that generates Dockerfile declarations for the host installed VS Code extensions.
  • we must add a plugin to code-server to append newly installed extensions to your hat or project Dockerfile (prompts the user). Otherwise, newly installed extensions will disappear when the container is rebuilt.

Should accept http/https in git clone address

Trying to run sail on a remote server, don't want to set up ssh:

sean@test-code-serverxqhdp:~$ sudo ./sail run https://github.com/codercom/sshcode
Cloning into '/home/sean/Projects/github.com/codercom/sshcode'...
fatal: I don't handle protocol 'git@https'
2019-04-22 19:27:33 FATAL	exit status 128

Edit hat in real time

sail edithat --watch ~/Projects/ammario/dotfiles codercom/code-server could open an inotify on the directory and rebuild code-server with the hat automatically.

edit hat in code-server

I already wrote the proxy and whatnot. Going to work on the javascript part for this, or at least try.

Don't fail on missing dirs/files when trying to bind mount

2019-04-22 20:14:16 INFO	using default image codercom/ubuntu-dev
2019-04-22 20:14:20 INFO	loaded code-server in 3.764207667s
2019-04-22 20:14:20 ERROR	build run failed: failed to run container: failed to create container: Error response from daemon: invalid mount config for type "bind": bind source path does not exist: /home/sean/.config/Code
2019-04-22 20:14:20 ERROR	failed to remove```

hat: cache github hat to deterministic local location

When resolving a github hat, it currently caches it to a local tmp directory. This means we have to store the hat name as /tmp/{rand}/{hat} instead of github:{org}/{hat} in order to preserve hat edits.

It would be nice to cache these git pulls to a local deterministic location so we can keep the github:{org}/{hat} naming scheme to show the true hat source.

setup CI

GitHub actions should work reasonably well.

will not work on multi user systems

On any system where the user uid is not 1000, like macOS or multiple user systems, sail will be very slow due to the usermod -u step to adjust the uid inside the container to the one outside because it has to chown all files in the home folder.

I do not have a good solution for this.

See #51

switch to docker cli

I think we should switch to make it easier to debug and work with as we can rerun failing commands to see what's happening.

Furthermore, there are some things the cli does that the Go lib doesn't, e.g. if the volume mount src doesn't exist, the cli creates it. I just ran into this as I did not have a ~/.config/Code directory.

@ammario

Open subdirectories

I frequently open lib/vscode within code-server.

Maybe

sail run codercom/code-server lib/vscode

Separate projects by host

Instead of storing projects at ~/Projects/cdr/code-server, we should also separate them by host like ~/Projects/github.com/cdr/code-server so multiple projects don't overlap

Should pull codercom/ubuntu-dev image

sean@test-code-serverxqhdp:~$ ./sail run https://github.com/codercom/sshcode
2019-04-22 20:11:49 INFO	No configuration exists at /home/sean/.config/sail/sail.toml, writing default.
2019-04-22 20:11:49 INFO	using default image codercom/ubuntu-dev
2019-04-22 20:11:49 ERROR	build run failed: failed to run container: failed to assemble mounts: failed to inspect image: Error: No such image: codercom/ubuntu-dev
2019-04-22 20:11:49 ERROR	failed to remove

(Using a modified sail to allow for https cloning)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.