Skip to content

Possibly incorrect assumption that most people want virtualenv #115

Closed

Description

@samos123

After inspecting the Dockerfile for 2.7.11:wheezy I noticed that virtualenv gets installed by default: https://github.com/docker-library/python/blob/9383f7d4d2f96068e8957651aa3588fee8b48f71/2.7/wheezy/Dockerfile

I don't need virtualenv as I'm using Docker to run a single service where docker already provides isolation of dependencies. I think most people won't actually need virtualenv but instead will use pip to install packages globally.

My suggestion is to remove the line to install virtualenv and reduce the image to be clean and unbiased.

Activity

  1. added a commit that references this issue on Jun 13, 2016
    aaad3d6
  2. Starefossen commented on Jun 13, 2016

    @Starefossen
    Contributor

    While I generally agree with you, this will break backwards comparability for those relying on virtualenv already being installed in the official Python image. This is a fundamental problem with the way Docker Images are tagged / versioned.

  3. tianon commented on Jun 13, 2016

    @tianon
    Member

    Do the slim and/or alpine variants of the image also install virtualenv, or do they appropriately abstain?

  4. ushuz commented on Jun 30, 2016

    @ushuz
    Contributor

    @tianon slim alpine variants won't install virtualenv.

  5. yosifkit commented on Jun 30, 2016

    @yosifkit
    Member

    So it seems that the "include everything" approach for the default versions of python 2 does include virtualenv since python 3 includes venv and those who want more control over what is included should be using the smaller images like slim and alpine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions