-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
37 lines (30 loc) · 1.31 KB
/
Dockerfile
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
34
35
36
37
FROM ubuntu:18.04
SHELL ["/bin/bash", "-c"]
WORKDIR /root
RUN apt update 2> /dev/null
RUN apt install -y vim wget git 2> /dev/null
RUN apt install -y tmux 2> /dev/null
RUN apt install -y openssh-server 2> /dev/null
RUN git clone git://github.com/nodenv/nodenv.git /root/.nodenv
RUN git clone https://github.com/nodenv/node-build.git /root/.nodenv/plugins/node-build
RUN mkdir -p /root/.vim/colors/
RUN wget https://raw.githubusercontent.com/karuru6225/vim-hybrid/master/colors/hybrid.vim -O /root/.vim/colors/hybrid.vim
RUN git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
COPY dotfiles/.vimrc /root
RUN vim +PluginInstall +qall 2> /dev/null
COPY dotfiles/.tmux.conf /root
COPY dotfiles/.colorrc /root
COPY dotfiles/.bashrc_additional /root
COPY dotfiles/.gitconfig /root
RUN echo ". .bashrc_additional" >> /root/.bashrc
RUN . /root/.bashrc
RUN sed -i 's/#PermitRootLogin yes/PermitRootLogin yes/' /etc/ssh/sshd_config
RUN sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/' /etc/ssh/sshd_config
RUN mkdir /root/.ssh
RUN mkdir /var/run/sshd
COPY playground.pub /tmp/playground.pub
COPY ssh_config /root/.ssh/config
RUN chmod 600 /root/.ssh/config
RUN ln -s /tmp/credentials/github /root/.ssh/github
RUN cat /tmp/playground.pub >> /root/.ssh/authorized_keys
CMD ["/usr/sbin/sshd", "-D"]