diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/fossil-test@.service | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/src/fossil-test@.service b/src/fossil-test@.service index 96b9f98..1bdd39f 100644 --- a/src/fossil-test@.service +++ b/src/fossil-test@.service | |||
@@ -3,13 +3,22 @@ Description = Endofossil Test: Clone over SSH using fresh identity | |||
3 | 3 | ||
4 | [Service] | 4 | [Service] |
5 | Type = oneshot | 5 | Type = oneshot |
6 | TemporaryFileSystem = /root | 6 | PrivateUsers = yes |
7 | Environment = HOME=/root | 7 | DynamicUser = yes |
8 | WorkingDirectory = /root | 8 | |
9 | User = fossil-test-user-%i | ||
10 | RuntimeDirectory = fossil-test-%i | ||
11 | BindPaths = /run/fossil-test-%i:/.ssh | ||
12 | Environment = HOME=/run/fossil-test-%i | ||
13 | WorkingDirectory = /run/fossil-test-%i | ||
14 | |||
9 | ExecStart = sh -exc '\ | 15 | ExecStart = sh -exc '\ |
10 | mkdir .ssh .ssh/known_hosts.d; \ | 16 | ! touch /test.file; \ |
17 | ln -s . .ssh; \ | ||
18 | mkdir .ssh/known_hosts.d; \ | ||
11 | ssh-keygen -t ed25519 -f .ssh/id_ed25519 -N ""; \ | 19 | ssh-keygen -t ed25519 -f .ssh/id_ed25519 -N ""; \ |
12 | ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new %i@localhost :; \ | 20 | ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new -- %i@localhost :; \ |
13 | ssh -o BatchMode=yes -o StrictHostKeyChecking=yes %i@localhost fossil uptime; \ | 21 | ssh -o BatchMode=yes -o StrictHostKeyChecking=yes -- %i@localhost uptime; \ |
22 | cd .ssh; \ | ||
14 | fossil clone ssh://%i@localhost/src/fossil/db db~$(date -Ins).fossil; \ | 23 | fossil clone ssh://%i@localhost/src/fossil/db db~$(date -Ins).fossil; \ |
15 | ' | 24 | ' |