[Unit] Description=SSH DSA Keygeneration. After=syslog.target Before=sshd.service ConditionPathExists=!/etc/ssh/ssh_host_dsa_key [Service] Type=oneshot ExecStart=/usr/bin/ssh-keygen -q -t dsa -f /etc/ssh/ssh_host_dsa_key -C '' -N '' RemainAfterExit=yes [Install] WantedBy=multi-user.target