mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 22:41:09 +02:00
docs: add SSH setup instructions to Mac Mini runner guide
Adds Part A covering SSH key setup, SSH config for local and remote access, and useful SSH commands for manual server management. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
e926a39818
commit
2059411d64
1 changed files with 74 additions and 2 deletions
|
|
@ -1,8 +1,80 @@
|
|||
# GitHub Actions Self-Hosted Runner auf dem Mac Mini einrichten
|
||||
# Mac Mini Setup: GitHub Actions Runner & SSH-Zugang
|
||||
|
||||
Diese Anleitung auf dem Mac Mini ausführen.
|
||||
|
||||
## 1. Runner-Token holen
|
||||
---
|
||||
|
||||
## Teil A: SSH-Zugang einrichten
|
||||
|
||||
Damit von Entwicklungsrechnern (und Claude Code) direkt per SSH auf den Mac Mini zugegriffen werden kann.
|
||||
|
||||
### A1. SSH-Dienst aktivieren (falls noch nicht aktiv)
|
||||
|
||||
```bash
|
||||
# Prüfen ob SSH aktiv ist
|
||||
sudo systemsetup -getremotelogin
|
||||
|
||||
# Falls "Off": aktivieren
|
||||
sudo systemsetup -setremotelogin on
|
||||
```
|
||||
|
||||
### A2. SSH-Key hinterlegen
|
||||
|
||||
Folgenden Public Key in `~/.ssh/authorized_keys` auf dem Mac Mini einfügen:
|
||||
|
||||
```bash
|
||||
mkdir -p ~/.ssh && chmod 700 ~/.ssh
|
||||
|
||||
# Claude Code SSH-Key hinzufügen
|
||||
echo "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIAmtp92RmE6lPhHRg24VSYIvq9ne4+qe61SiR4c+lPWu claude-code@manacore" >> ~/.ssh/authorized_keys
|
||||
|
||||
chmod 600 ~/.ssh/authorized_keys
|
||||
```
|
||||
|
||||
### A3. Verbindung testen (vom Entwicklungsrechner)
|
||||
|
||||
```bash
|
||||
ssh till@192.168.178.131 "echo 'SSH works!'"
|
||||
```
|
||||
|
||||
### A4. SSH-Config auf dem Entwicklungsrechner
|
||||
|
||||
Falls noch nicht vorhanden, `~/.ssh/config` erstellen/ergänzen:
|
||||
|
||||
```
|
||||
# Lokales Netzwerk (direkt)
|
||||
Host mana-server
|
||||
HostName 192.168.178.131
|
||||
User till
|
||||
|
||||
# Über Cloudflare Tunnel (von extern)
|
||||
Host mana-server-remote
|
||||
HostName mac-mini.mana.how
|
||||
User till
|
||||
ProxyCommand /opt/homebrew/bin/cloudflared access ssh --hostname %h
|
||||
```
|
||||
|
||||
### A5. Nützliche SSH-Befehle
|
||||
|
||||
```bash
|
||||
# Verbinden
|
||||
ssh mana-server
|
||||
|
||||
# Direkt einen Befehl ausführen
|
||||
ssh mana-server "cd ~/projects/manacore-monorepo && ./scripts/mac-mini/status.sh"
|
||||
|
||||
# Manuelles Deployment
|
||||
ssh mana-server "cd ~/projects/manacore-monorepo && git pull && docker compose -f docker-compose.macmini.yml --env-file .env.macmini up -d --build matrix-web"
|
||||
|
||||
# Logs eines Containers ansehen
|
||||
ssh mana-server "docker logs -f mana-matrix-web --tail 50"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Teil B: GitHub Actions Self-Hosted Runner
|
||||
|
||||
### 1. Runner-Token holen
|
||||
|
||||
1. Gehe zu: https://github.com/Memo-2023/manacore-monorepo/settings/actions/runners/new
|
||||
2. Wähle **macOS** und **ARM64**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue