Docker / congifparser error in requirements.txt

In my code I’m using configparser:

from configparser import ConfigParser

And I’m using pip freeze to generate my requirements.txt

  • Can't bootstrap Docker version since 1.11.x for direct-lvm setup (Kubernetes)
  • Docker to run X applications while connected through SSH
  • Docker compose on cross-platform environment
  • How to get from Android Emulator to Docker Machine's container?
  • Building the MongoDB Docker image
  • Docker run -d <private image> gives fatal. On other hosts it's ok?
  • pip freeze > requirements.txt

    And for configparser it’s writing


    But that fails when I do a pip install -r requirements.txt from within the docker container via a docker build:

    docker build -t denzel .
    Downloading/unpacking configparser==3.3.0.post2 (from -r /home/denzel/requirements.txt (line 2))
    Could not find a version that satisfies the requirement configparser==3.3.0.post2 (from -r /home/denzel/requirements.txt (line 2)) (from versions: 3.2.0r1, 3.2.0r2, 3.2.0r3, 3.3.0r1, 3.3.0r2, 3.5.0b1, 3.5.0b2)
    Cleaning up...
    No distributions matching the version for configparser==3.3.0.post2 (from -r /home/denzel/requirements.txt (line 2))

    But this works locally via pip install:

     pip install -r requirements.txt
    Requirement already satisfied (use --upgrade to upgrade): aniso8601==1.1.0 in ./env/lib/python2.7/site-packages (from -r requirements.txt (line 1))
    Requirement already satisfied (use --upgrade to upgrade): configparser==3.3.0.post2 in ./env/lib/python2.7/site-packages (from -r requirements.txt (line 2))

    NOTE: I fixed this by removing the version and just using configparser, no version. Still wanted to post my question to get the reason why it’s failing.

  • Use git in jenkins pipeline with docker agent
  • How to fix cadvisor error `devicemapper filesystem stats will not be reported`?
  • not working
  • Install docker 1.11 on Fedora 21
  • openshift origin with local docker registry
  • Does Docker install and run dependencies only when I'm using it?
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.