Skip to content

Commit

Permalink
Docker image usage
Browse files Browse the repository at this point in the history
  • Loading branch information
vyadh committed Nov 3, 2024
1 parent fb05d77 commit 8295d22
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions book/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,32 @@ Cross Platform installation:

- [npm](https://www.npmjs.com/) (`npm install -g nushell` Note that nu plugins are not included if you install in this way)

## Docker Container Images

Docker images are available from the GitHub Container Registry. An image for the latest release is built regularly
for Alpine and Debian. You can run the image in interactive mode using:

```nu
docker run -it --rm ghcr.io/nushell/nushell:<version>-<distro>
```

Where `<version>` is the version of Nushell you want to run and `<distro>` is `alpine` or the latest supported Debian release, such as `bookworm`.

To run a specific command, use:

```nu
docker run --rm ghcr.io/nushell/nushell:latest-alpine -c "ls /usr/bin | where size > 10KiB"
```

To run a script from the current directory using Bash, use:

```nu
docker run --rm \
-v $(pwd):/work \
ghcr.io/nushell/nushell:latest-alpine \
"/work/script.nu"
```

## Build from Source

You can also build Nu from source. First, you will need to set up the Rust toolchain and its dependencies.
Expand Down

0 comments on commit 8295d22

Please sign in to comment.