A secure SSH/SFTP gateway that provides direct access to Kubernetes pods using GitHub authentication and permissions.
- 🔐 GitHub-based authentication using SSH keys
- 🚀 Direct SSH/SFTP access to Kubernetes pods
- 👥 Role-based access control tied to GitHub permissions
- 🔄 Real-time key synchronization
- 📊 Container state management
- 🔍 Detailed access logging
# Connect to a pod
ssh [pod-name]@ssh.rabbit.ci
-
SSH Gateway
- Handles SSH/SFTP connections
- Authenticates using GitHub SSH keys
- Routes connections to appropriate pods
-
API Server
- Manages pod connections
- Handles container state
- Provides health endpoints
-
Key Management
- Syncs with GitHub collaborators
- Manages access permissions
- Updates authorized_keys
- GitHub-based authentication
- Role-based access control
- No password authentication
- Kubernetes service account integration
Variable | Description |
---|---|
KUBERNETES_CLUSTER_ENDPOINT |
Kubernetes API endpoint |
KUBERNETES_CLUSTER_NAME |
Cluster name |
KUBERNETES_CLUSTER_SERVICEACCOUNT |
Service account name |
KUBERNETES_CLUSTER_USER_TOKEN |
Kubernetes auth token |
ALLOW_SSH_ACCESS_ROLES |
GitHub roles allowed to access |
See Environment Variables for full list.
# Direct shell access
ssh www-myapp-com
# Run specific command
ssh www-myapp-com "ls -la"
# Interactive SFTP session
sftp www-myapp-com
# File transfer
scp local-file www-myapp-com:/remote/path/
Key log locations:
- SSH/SFTP sessions:
/var/log/sshd.log
- Contains connection attempts
- SFTP path resolutions
- User session details
- Process logs:
pm2 logs
- API server activity
- Key synchronization events
- General process health
- Container logs:
kubectl logs <pod-name>
- Container-level events
- System messages
- Authentication details
Quick debug commands:
# View SSH session logs
tail -f /var/log/sshd.log
# View API and process logs
pm2 logs
# View specific service logs
pm2 logs sshd # SSH daemon
pm2 logs api # API server
- Architecture Details
- Security Model
- Kubernetes Integration
- Client Configuration
- Troubleshooting
- API Reference
See CONTRIBUTING.md for development guidelines.
This project is proprietary software. All rights reserved.