support ssh authorized keys

This commit is contained in:
dave 2018-10-07 15:21:44 -07:00
parent f26f80ee95
commit 83e4244059
2 changed files with 8 additions and 5 deletions

View File

@ -1,13 +1,15 @@
FROM ubuntu:bionic
# Nexus user for application usage
RUN useradd --create-home nexus && \
echo "nexus:nexus" | chpasswd
# Packages
RUN apt-get update && \
apt-get install -y nginx-light fcgiwrap supervisor openssh-server cron rsync python3-pip
# Nexus user for application usage
RUN useradd --create-home nexus && \
echo "nexus:nexus" | chpasswd && \
install -d /home/nexus/.ssh -o nexus -g nexus -m 700 && \
ln -s /data/nexus_authorized_keys /home/nexus/.ssh/authorized_keys
# Misc conf
RUN mkdir /start.d /nexus /var/run/sshd && \
chown nexus /nexus && \

View File

@ -19,7 +19,8 @@ Nexus offers a couple services:
For shell related activities, an sshd daemon runs on the standard port. Username and password, by default, is `nexus`.
Mount `/data/keys` to persist host keys.
Mount `/data/keys` to persist host keys. Ssh public keys in `/data/nexus_authorized_keys` will be authorized for the
`nexus` user.
### Nginx