params: # SSH key is required for remote access into the container # you may also use ssh-import-id ssh_key: "" # so ssh-import-id works env: HOME: /root run: - replace: filename: /etc/pam.d/sshd from: "session required pam_loginuid.so" to: "" - file: path: /etc/service/sshd/run chmod: "+x" contents: | #!/bin/bash exec 2>&1 exec /usr/sbin/sshd -D -e - file: path: /etc/runit/3.d/99-ssh chmod: "+x" contents: | #!/bin/bash sv stop sshd - exec: hook: sshd cmd: - mkdir -p /var/run/sshd - mkdir -p /root/.ssh - echo "$ssh_key" >> /root/.ssh/authorized_keys - echo "$$ENV_SSH_PUB_KEY" >> /root/.ssh/authorized_keys - chmod 640 /root/.ssh/authorized_keys - rm /etc/update-motd.d/00-header - rm /etc/update-motd.d/10-help-text - rm /etc/legal - file: path: /etc/update-motd.d/00-discourse chmod: +x contents: | #!/bin/sh echo echo Welcome to Discourse Docker echo