# SSH Command

UI Bakery allows connecting to a remote Linux computer via SSH and executing commands there. For this purpose, you can use the SSH Command action step.

Usually, you will land in the home directory of your remote user. That's why, in some cases, you might need to change a working directory before executing your command, for example:

```bash
cd /other/directory && ./your-script.sh
```

## Examples

### Reading remote files

You can use the `cat` command in this case:

```bash
cat /home/user/your-file
```

### Creating a file and filling it with data

```bash
echo {{ui.input.value}} > myfile.txt
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.uibakery.io/reference/working-with-actions/ssh-command.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
