File not getting updated when using “docker cp”

I am trying to use docker cp to copy .class files from my host into the container. I am using the following command:

docker cp foo.class container:/path/foo.class

I am doing this when the server running inside the container is shutdown.

  • Add a potentially large amount of metadata to a docker image
  • When dockerizing a rails app with EC2 container service with ELB do I still need nginx?
  • How to ssh to a docker container on ec2 ubuntu host from outside machine
  • ENTRYPOINT with environment variables is not acepting new params
  • Deleting folders in docker conatiner using python
  • docker daemon crashes randomly after add ENTRYPOINT - Docker
  • However, I am seeing that the foo.class isn’t getting updated with my latest file and if I try to rm the file I get a

    rm: cannot remove foo.class: Stale file handle
    

    Here is my docker version (Docker for Mac):

    docker version
    Client:
    Version:      1.13.0
    API version:  1.25
    Go version:   go1.7.3
    Git commit:   49bf474
    Built:        Wed Jan 18 16:20:26 2017
    OS/Arch:      darwin/amd64
    
    Server:
     Version:      1.13.0
     API version:  1.25 (minimum version 1.12)
     Go version:   go1.7.3
     Git commit:   49bf474
     Built:        Wed Jan 18 16:20:26 2017
     OS/Arch:      linux/amd64
     Experimental: true
    

    Anyone seen this happen?

    TIA

  • Azure App Service + Docker Autodeploy?
  • Dokku Environment Variables
  • What does sbt-native-packager's docker:publishLocal do?
  • wokflow: Missing cloudify_agent.queue runtime information
  • Docker Performance Testing
  • debootstrap inside a docker container
  • Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.