我使用了
FROM rails:onbuild
镜像。
你可以在这里看到错误/无法阅读的编码
当我在
test
后面按下退格键时,它没有起作用,而是在shell中添加了空格。
这是环境变量,您有关于此错误的想法吗?
RUBY_MAJOR=2.2
RUBY_VERSION=2.2.2
RUBY_DOWNLOAD_SHA256=5ffc0f317e429e6b29d4a98ac521c3ce65481bfd22a8cf845fa02a7b113d9b44
GEM_HOME=/usr/local/bundle
BUNDLE_APP_CONFIG=/usr/local/bundle
LANG=en_US.UTF-8
LANGUAGE=en_US:en
LC_ALL=en_US.UTF-8
HOME=/root
LOGNAME=root
SHLVL=1
PWD=/associate-app
OLDPWD=/associate-app
ZSH=/root/.oh-my-zsh
PAGER=less
LESS=-R
LSCOLORS=Gxfxcxdxbxegedabagacad
_=/usr/bin/env
DOCKERFILE(下面是我的Dockerfile)
FROM rails:onbuild
RUN apt-get update && apt-get -y upgrade
RUN apt-get -y -qq --force-yes install \
build-essential \
tree \
locales \
ruby-dev \
vim \
vim-scripts \
git \
git-flow\
curl \
zsh \
sudo
# Install Zsh
RUN git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh \
&& cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc \
&& chsh -s /bin/zsh
RUN sed -i -E "s/^plugins=\((.*)\)$/plugins=(\1 git git-flow ruby tmux)/" ~/.zshrc
# Make ssh dir
RUN mkdir /root/.ssh/
# Copy over private key, and set permissions
ADD id_rsa /root/.ssh/id_rsa
# Create known_hosts
RUN touch /root/.ssh/known_hosts
# Add bitbuckets key
RUN ssh-keyscan bitbucket.org >> /root/.ssh/known_hosts
RUN echo "alias ls='ls --color=auto'" >> /etc/zsh/zshrc && \
echo "alias ll='ls -halF'" >> /etc/zsh/zshrc && \
echo "alias ls='ls --color=auto'" >> /etc/profile && \
echo "alias ll='ls -halF'" >> /etc/zsh/zshrc
# copy GEMFILE
WORKDIR /tmp
COPY Gemfile Gemfile
COPY Gemfile.lock Gemfile.lock
RUN bundle install
RUN mkdir /associate-app
WORKDIR /associate-app
ADD . /associate-app
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
CMD echo 'LC_ALL=en_US.UTF-8' >> ~/.zshrc && \
echo 'LANG=C.UTF-8' >> ~/.zshrc && \
echo 'LC_CTYPE=en_US.UTF-8' >> ~/.zshrc && \
CMD ["zsh"]
stty -a
speed 38400 baud; rows 40; columns 164; line = 0;
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W;
lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd -cmspar cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc -ixany -imaxbel -iutf8
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt echoctl echoke
docker exec -it my_container bash
进入容器时,您能否发布echo $TERM
? - user2915097