-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile
51 lines (39 loc) · 1.4 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
FROM ubuntu:latest
RUN apt update && apt install -y \
zsh \
git \
curl \
wget \
python3 \
python3-pip \
python-is-python3 \
golang \
vim \
tmux
# Hostname
RUN echo "BaleiaoHacker" > /etc/hostname
# Instalando o ohmyzsh e configurando o zsh como bash padrão
# https://ohmyz.sh/#install
RUN sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" && \
chsh -s /bin/zsh
# Configuração para o zsh history
RUN echo 'HISTFILE=/workdir/.zsh_history_docker' >> /root/.zshrc && \
echo 'HISTSIZE=1000' >> /root/.zshrc && \
echo 'SAVEHIST=1000' >> /root/.zshrc && \
echo 'setopt inc_append_history' >> /root/.zshrc && \
echo 'setopt share_history' >> /root/.zshrc
RUN sed -i 's/ZSH_THEME="robbyrussell"/ZSH_THEME="refined"/' /root/.zshrc
# Instalando o ohmytmux
RUN git clone https://github.com/gpakosz/.tmux.git ~/.tmux && \
ln -s -f ~/.tmux/.tmux.conf ~/.tmux.conf && \
cp ~/.tmux/.tmux.conf.local ~/
# Copia o script para o scontainer
#COPY auxiliar_scripts/docker_script.sh /usr/local/bin/docker_script.sh
# Define permissões de execução e executa o script
# RUN chmod +x /usr/local/bin/docker_script.sh && \
# /usr/local/bin/docker_script.sh
#Limpeza de cache para diminuir a imagem
#RUN rm -rf /var/lib/apt/lists/*
WORKDIR /workdir
# Para manter o container em execução após saídas
CMD ["tail", "-f", "/dev/null"]