Bug 1309727 - Fedora docker image missing sudo
Fedora docker image missing sudo
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: docker (Show other bugs)
23
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Lokesh Mandvekar
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2016-02-18 09:56 EST by Avi Kivity
Modified: 2016-02-18 10:20 EST (History)
11 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-02-18 10:20:01 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Avi Kivity 2016-02-18 09:56:02 EST
(note: filed against docker, but meant to file against the official Fedora docker image.  Don't know what the component is for that.)

Description of problem:


To compile-test software, it is convenient to do

   docker run -v /home/avi/software:/home/avi/software -w /home/avi/software -i -t -v /etc/passwd:/etc/passwd -t /etc/sudoers:/etc/sudoers -u avi fedora:rawhide /bin/bash
   $ sudo dnf install toolchain
   $ make (or whatever)

But I can't do that now because sudo is not installed.  I can either run everything as root (and be left with root-owned files in my home directory), or us myself (but not be able to be root in my container).

I could have my own image, but sudo seems useful enough to be in the official image.


Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1. docker run -i -t  -v /etc/passwd:/etc/passwd -u $(id -un) fedora:rawhide sudo echo yes

Actual results:
exec: "sudo": executable file not found in $PATH


Expected results:
yes

Additional info:
Comment 1 Daniel Walsh 2016-02-18 10:20:01 EST
I don't believe most people use sudo in a docker container.  I don't believe it should be in the base image.  We are trying to make the base image smaller, not adding to it.

You need to create a layered image.

Note You need to log in before you can comment on or make changes to this bug.