Nat*_*teW 31 containers sudo centos yum docker
我无法在我的Docker容器中运行任何yum命令而不会收到以下错误:
ovl: Error while doing RPMdb copy-up:
[Errno 13] Permission denied: '/var/lib/rpm/Group'
You need to be root to perform this command.
Run Code Online (Sandbox Code Playgroud)
我很困惑,因为我非常确定docker容器是使用默认用户root运行的.不过,如果我尝试把须藤在前面yum install -y <package>
或yum update -y
命令我得到:
/bin/sh: sudo: command not found
Run Code Online (Sandbox Code Playgroud)
我正在使用以下基本映像,因此我可以在Docker中轻松运行Java Wildfly应用程序:https://hub.docker.com/r/jboss/wildfly/
底层发行版是 CentOS Linux release 7.2.1511 (Core)
Nat*_*teW 52
原来用户被设置为jboss
基本图像.
当使用dockerfile命令切换到用户root时,USER root
一切正常.
归档时间: |
|
查看次数: |
14051 次 |
最近记录: |