File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ services:
88 - workspace:/workspace
99 - ssh-key:/home/claude/.ssh:ro
1010 ports :
11+ - " 2222:22"
1112 - " 7681:7681"
1213 networks :
1314 - traefik_default
Original file line number Diff line number Diff line change 44# Generate host SSH keys if not already present
55ssh-keygen -A
66
7+ # Copy mounted SSH keys to a writable location (mount is read-only)
8+ if [ -f /home/claude/.ssh/authorized_keys ]; then
9+ cp /home/claude/.ssh/authorized_keys /tmp/authorized_keys
10+ mkdir -p /home/claude/.ssh_writable
11+ mv /tmp/authorized_keys /home/claude/.ssh_writable/authorized_keys
12+ chmod 700 /home/claude/.ssh_writable
13+ chmod 600 /home/claude/.ssh_writable/authorized_keys
14+ chown -R claude:claude /home/claude/.ssh_writable
15+ # Point sshd to the writable copy
16+ echo " AuthorizedKeysFile /home/claude/.ssh_writable/authorized_keys" >> /etc/ssh/sshd_config
17+ fi
18+
719# Start SSH daemon
820/usr/sbin/sshd
921
You can’t perform that action at this time.
0 commit comments