use*_*739 2 ubuntu manpage docker
我使用以下Dockerfile构建映像并启动容器。但是一旦进入容器,我仍然找不到手册页。有人知道如何解决这个问题吗?谢谢。
$ cat Dockerfile
FROM ubuntu
RUN apt -y update && apt -y upgrade
RUN apt-get -y install build-essential
RUN apt-get -y install vim
RUN apt-get -y install man
RUN apt-get -y install gawk
RUN apt-get -y install mawk
$ man man
No manual entry for man
See 'man 7 undocumented' for help when manual pages are not available.
$ find /usr/share/man /usr/local/share/man -type f
Run Code Online (Sandbox Code Playgroud)
小智 5
您需要/etc/dpkg/dpkg.cfg.d/excludes
在容器内进行更改。您可以使用以下命令在Dockerfile中执行此操作:
RUN sed -i '/path-exclude=\/usr\/share\/man\/*/c\#path-exclude=\/usr\/share\/man\/*' /etc/dpkg/dpkg.cfg.d/excludes
然后对您的Dockerfile进行另一次更新以安装手册页
RUN apt-get update && apt-get install -y \
man \
manpages-posix
归档时间: |
|
查看次数: |
790 次 |
最近记录: |