# unikraft instances write

Write a single local file to an instance which has the sandbox
plugin loaded.


```
unikraft instances write <target> <local> <remote> [flags]
```

## Examples

Write a local file to an instance:

```bash
unikraft instance write my-instance ./config.json /etc/app.json
```

Write a file, creating parent directories as needed:

```bash
unikraft instance write my-instance ./data.bin /var/lib/app.bin -p
```

Append to a file on an instance:

```bash
unikraft instance write my-instance ./extra.log /var/log/app.log --append
```

## Options

```
  --append                    Append to the remote file instead of overwriting it.
  -p, --parents               Create missing parent directories on the remote path.
  --plugin name               Name of the sandbox plugin to use. (default sandbox)
```

## Options inherited from parent commands

```
  --config file               Path to the configuration file.
  --log-level level           Set the logging level. (default info)
  --log-type type             Set the log type. (default text)
  --profile name              Set the current profile.
  --telemetry                 Toggle usage analytics. (default true)
  --timeout duration          Set a deadline for the command (e.g. 30s, 5m, 1h).
```

## See Also

* [`unikraft instances`](../instances.mdx): Manage Unikraft Cloud instances.

