mirror of
https://github.com/rancher/os.git
synced 2025-07-16 16:11:03 +00:00
Merge pull request #347 from imikushin/sshd-client-alive
add ClientAliveInterval 180 to sshd_config
This commit is contained in:
commit
6a8fc22fa9
@ -4,6 +4,7 @@ COPY scripts/dockerimages/scripts/update-ssh-keys /usr/bin/
|
||||
COPY scripts/dockerimages/scripts/rancheros-install /usr/sbin/
|
||||
RUN sed -i 's/rancher:!/rancher:*/g' /etc/shadow && \
|
||||
sed -i 's/docker:!/docker:*/g' /etc/shadow && \
|
||||
sed -i 's/#ClientAliveInterval 0/ClientAliveInterval 180/g' /etc/ssh/sshd_config && \
|
||||
echo '## allow password less for rancher user' >> /etc/sudoers && \
|
||||
echo 'rancher ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers && \
|
||||
echo '## allow password less for docker user' >> /etc/sudoers && \
|
||||
|
@ -13,6 +13,7 @@ RUN addgroup --gid 1100 rancher && \
|
||||
addgroup --gid 1101 docker && \
|
||||
useradd -u 1100 -g rancher -G docker,sudo -m -s /bin/bash rancher && \
|
||||
useradd -u 1101 -g docker -G docker,sudo -m -s /bin/bash docker && \
|
||||
echo ClientAliveInterval 180 >> /etc/ssh/sshd_config && \
|
||||
echo '## allow password less for rancher user' >> /etc/sudoers && \
|
||||
echo 'rancher ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers && \
|
||||
echo 'docker ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
|
||||
|
@ -13,6 +13,7 @@ RUN addgroup --gid 1100 rancher && \
|
||||
addgroup --gid 1101 docker && \
|
||||
useradd -u 1100 -g rancher -G docker,sudo -m -s /bin/bash rancher && \
|
||||
useradd -u 1101 -g docker -G docker,sudo -m -s /bin/bash docker && \
|
||||
echo ClientAliveInterval 180 >> /etc/ssh/sshd_config && \
|
||||
echo '## allow password less for rancher user' >> /etc/sudoers && \
|
||||
echo 'rancher ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers && \
|
||||
echo 'docker ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
|
||||
|
Loading…
Reference in New Issue
Block a user