forked from giovtorres/slurm-docker-cluster
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathslurm-create-datadir.service
33 lines (28 loc) · 1.38 KB
/
slurm-create-datadir.service
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
[Unit]
Description=Podman slurm-create-datadir.service
Wants=network.target
After=network-online.target
ConditionPathIsDirectory=!%S/slurm-container-cluster/var_lib_mysql
[Service]
Type=oneshot
RemainAfterExit=yes
Environment=PODMAN_SYSTEMD_UNIT=%n
StateDirectory=slurm-container-cluster
StateDirectoryMode=0700
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/etc_munge
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/etc_slurm
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/extra-containerimages
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/slurm_jobdir
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/var_lib_mysql
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/var_run_mysqld
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/var_log_slurmdbd
ExecStart=/bin/mkdir -p %S/slurm-container-cluster/var_log_slurmctld
ExecStart=podman unshare /bin/chmod 700 %S/slurm-container-cluster/etc_munge
ExecStart=podman unshare /bin/chown 993:992 %S/slurm-container-cluster/etc_munge
ExecStart=podman unshare /bin/chmod 700 %S/slurm-container-cluster/var_log_slurmdbd
ExecStart=podman unshare /bin/chmod 700 %S/slurm-container-cluster/var_log_slurmctld
ExecStart=podman unshare /bin/chown 992:991 %S/slurm-container-cluster/var_log_slurmdbd
ExecStart=podman unshare /bin/chown 992:991 %S/slurm-container-cluster/var_log_slurmctld
KillMode=control-group
[Install]
WantedBy=multi-user.target