artwist-polyakov/ssh-remote-connection
SSH connection to remote servers. Use when you need to execute commands on a remote server, check logs, restart services, or manage Docker containers.
npx skills add https://github.com/artwist-polyakov/polyakov-claude-skills --skill ssh-remote-connection
Universal skill for connecting to remote servers via SSH.
# Interactive shell
scripts/connect.sh
# Run command directly
scripts/connect.sh "docker compose logs backend --tail 50"
cp config/.env.example config/.env
config/.env with actual valuesKey-based authentication:
SSH_HOST=your-server.example.com
SSH_USER=ubuntu
SSH_AUTH_METHOD=key
SSH_KEY_PATH=/absolute/path/to/private/key
SSH_KEY_PASSWORD=
SERVER_PROJECT_PATH=/path/to/project
Password-based authentication:
SSH_HOST=your-server.example.com
SSH_USER=ubuntu
SSH_AUTH_METHOD=password
SSH_PASSWORD='your account password'
SERVER_PROJECT_PATH=/path/to/project
chmod +x scripts/connect.sh
Set environment variables in your cloud configuration:
SSH_HOST — server hostname or IPSSH_USER — SSH usernameSSH_PORT — SSH port (optional)SSH_AUTH_METHOD — auto, key, or password (optional, defaults to auto)SSH_KEY_PATH — path to private key for key authenticationSSH_KEY_PASSWORD — key passphrase (optional)SSH_PASSWORD — SSH account password for password authenticationSERVER_PROJECT_PATH — project directory on serverFor password authentication, the local runtime must have either sshpass or expect.
If the host key is not trusted yet, connect once manually or add the host to known_hosts
before running non-interactive commands.
git pull on the server. User will handle git sync manually.docker compose (not docker-compose) on the server.# View logs
scripts/connect.sh "docker compose logs backend --tail 100"
# Restart service
scripts/connect.sh "docker compose restart backend"
# Rebuild and restart
scripts/connect.sh "docker compose build backend && docker compose up -d backend"
# Check status
scripts/connect.sh "docker compose ps"
Take artwist-polyakov/ssh-remote-connection from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.