<commit_before>---
title: "Portable Installation"
weight: 4
aliases:
  - /en/master/getting-started/portable/
---

Docksal can be installed from a USB drive or a local folder.  
This is useful for conferences/trainings/etc. where internet bandwidth is an issue.

## Creating a portable Docksal distribution {#download}

{{% notice note %}}
A working Docksal 1.2.0+ (fin v1.6.0+) environment is required
{{% /notice %}}

### One-line download script

The following download script can be used to pre-download most of the dependencies and Docker images..

```bash
curl -fsSL https://get.docksal.io/portable | bash
```

Here's what the script will download:

- Babun and winpty (necessary for Windows only)
- VirtualBox and boot2docker.iso (necessary for macOS and Windows)
- Docker tools: docker cli, docker-compose, docker-machine (macOS and Windows versions)
- Docksal system and default stack images (these are cross-platform)

The following download options are available:

- `SKIP_DEPS` - skip downloading dependencies (use if you plan to use the native Docker for Mac/Win apps or Linux) 
- `SKIP_IMAGES` - skip pulling and saving Docker images

Example:

```bash
curl -fsSL https://get.docksal.io/portable | SKIP_DEPS=1 bash
```

Once downloaded, place the contents of the folder on a USB drive/etc and distribute.

### Custom stacks

If you plan on using a custom stack configuration, you will have to export the project images manually.

You can export both system and project images by running the following within a Docksal project folder:

```bash
fin image save --system
fin image save --project
```

This will creat two files: `docksal-system-images.tar` and `docksal-<project-name>-images.tar`.  
Instruct users to use the latter file instead of `docksal-default-images.tar` when loading stack images (see below).

### Docker for Mac/Windows

Manually download Docker for Mac/Windows apps into the portable distribution folder:

- [Docker for Mac](https://docs.docker.com/docker-for-mac/install/)
- [Docker for Windows](https://docs.docker.com/docker-for-windows/install/)


## Installing from a portable source {#install}

{{% notice note %}}
Babun is included in the portable distribution, but has to be installed manually before proceeding.
All further commands are expected to be run in Babun on Windows.
{{% /notice %}}

Docksal's one-line installer supports portable mode installation and will detect and use local files when available.

### Mac and Windows (using VirtualBox) {#install-virtualbox}

{{% notice note %}}
This is the recommended setup option.
{{% /notice %}}

{{% notice note %}}
A minimal internet connection is still necessary to pull `fin` and Docksal stack files (~150kB).
{{% /notice %}}

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | bash
fin vm start
fin image load docksal-default-images.tar
```

### Docker for Mac/Windows ("native" mode) {#install-native}

{{% notice note %}}
Consider reviewing the [docs](/getting-started/docker-modes/) on switching between "native" applications and VirtualBox.
{{% /notice %}}

Install the corresponding Docker app for your OS from the provided portable distribution. 
Start the app and wait until Docker says it's running.

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | DOCKER_NATIVE=1 bash
fin image load docksal-default-images.tar
```

### Linux {#install-linux}

{{% notice warning %}}
Only Docksal system and stack images will be installed from the portable source.
All other Docker dependencies and tools will be downloaded from the internet (you will need a decent internet connection).
{{% /notice %}}

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | bash
fin image load docksal-default-images.tar
```
<commit_msg>Update portable.md<commit_after>---
title: "Portable Installation"
weight: 4
aliases:
  - /en/master/getting-started/portable/
---

Docksal can be installed from a USB drive or a local folder.  
This is useful for conferences/trainings/etc. where internet bandwidth is an issue.

## Creating a portable Docksal distribution {#download}

{{% notice note %}}
A working Docksal 1.2.0+ (fin v1.6.0+) environment is required
{{% /notice %}}

### One-line download script

The following download script can be used to pre-download most of the dependencies and Docker images..

```bash
curl -fsSL https://get.docksal.io/portable | bash
```

Here is what the script will download:

- Babun and winpty (necessary for Windows only)
- VirtualBox and boot2docker.iso (necessary for macOS and Windows)
- Docker tools: docker cli, docker-compose, docker-machine (macOS and Windows versions)
- Docksal system and default stack images (these are cross-platform)

The following download options are available:

- `SKIP_DEPS` - skip downloading dependencies (use if you plan to use the native Docker for Mac/Win apps or Linux) 
- `SKIP_IMAGES` - skip pulling and saving Docker images

Example:

```bash
curl -fsSL https://get.docksal.io/portable | SKIP_DEPS=1 bash
```

Once downloaded, place the contents of the folder on a USB drive/etc and distribute.

### Custom stacks

If you plan on using a custom stack configuration, you will have to export the project images manually.

You can export both system and project images by running the following within a Docksal project folder:

```bash
fin image save --system
fin image save --project
```

This will create two files: `docksal-system-images.tar` and `docksal-<project-name>-images.tar`.  
Instruct users to use the latter file instead of `docksal-default-images.tar` when loading stack images (see below).

### Docker for Mac/Windows

Manually download Docker for Mac/Windows apps into the portable distribution folder:

- [Docker for Mac](https://docs.docker.com/docker-for-mac/install/)
- [Docker for Windows](https://docs.docker.com/docker-for-windows/install/)


## Installing from a portable source {#install}

{{% notice note %}}
Babun is included in the portable distribution, but has to be installed manually before proceeding.
All further commands are expected to be run in Babun on Windows.
{{% /notice %}}

Docksal's one-line installer supports portable mode installation and will detect and use local files when available.

### Mac and Windows (using VirtualBox) {#install-virtualbox}

{{% notice note %}}
This is the recommended setup option.
{{% /notice %}}

{{% notice note %}}
A minimal internet connection is still necessary to pull `fin` and Docksal stack files (~150kB).
{{% /notice %}}

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | bash
fin vm start
fin image load docksal-default-images.tar
```

### Docker for Mac/Windows ("native" mode) {#install-native}

{{% notice note %}}
Consider reviewing the [docs](/getting-started/docker-modes/) on switching between "native" applications and VirtualBox.
{{% /notice %}}

Install the corresponding Docker app for your OS from the provided portable distribution. 
Start the app and wait until Docker says it's running.

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | DOCKER_NATIVE=1 bash
fin image load docksal-default-images.tar
```

### Linux {#install-linux}

{{% notice warning %}}
Only Docksal system and stack images will be installed from the portable source.
All other Docker dependencies and tools will be downloaded from the internet (you will need a decent internet connection).
{{% /notice %}}

Within the portable Docksal distribution folder run:

```bash
curl -fsSL https://get.docksal.io | bash
fin image load docksal-default-images.tar
```

{'fraction_non_alphanumeric': 0.09897655136675736, 'fraction_numerical': 0.0033683119575074493, 'mean_word_length': 4.376044568245125, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 14, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 20, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5818060', 'n_tokens_mistral': 2293, 'n_tokens_neox': 2125, 'n_words': 946}