https://github.com/calkit/example-ssh
An example project that runs a command in a remote environment via SSH.
https://github.com/calkit/example-ssh
hpc hpc-clusters open-science reproducibility reproducible-research
Last synced: about 2 months ago
JSON representation
An example project that runs a command in a remote environment via SSH.
- Host: GitHub
- URL: https://github.com/calkit/example-ssh
- Owner: calkit
- Created: 2025-01-24T00:53:59.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2025-01-26T14:38:01.000Z (4 months ago)
- Last Synced: 2025-01-26T15:26:52.655Z (4 months ago)
- Topics: hpc, hpc-clusters, open-science, reproducibility, reproducible-research
- Language: Shell
- Homepage: https://calkit.io/calkit/example-ssh
- Size: 5.86 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SSH example
[Project page](https://calkit.io/calkit/example-ssh) |
[GitHub repo](https://github.com/calkit/example-ssh)A [Calkit](https://github.com/calkit/calkit) example project that
executes a command on a remote server using SSH,
automatically copying project files back and forth.Note this will probably fail if run from Windows for a Unix-like host
because Git will probably
check out files with the wrong line endings and send those over.
This is [configurable](https://docs.github.com/en/get-started/getting-started-with-git/configuring-git-to-handle-line-endings),
however.## Setup
### Create an SSH key and add it to the agent
See [these docs](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent).
This is only necessary if you haven't done this before.
Optionally, you can create a new key just for this host.
Don't use a passphrase if you want your commands to run without entering
it each time.
This should be okay if your machine is secure.### Add your SSH key to the server
Assuming you've created one and added it to the agent, call:
```sh
ssh-copy-id $USER@$HOST
```If created a unique key for this remote host,
use the `-i` flag to specify that key file.### Fill in the correct environment details
In `calkit.yaml`, there is an environment called `cluster`.
Replace any relevant values there to match your remote machine.## Running the pipeline
Execute:
```sh
calkit run
```