nsmithuk / local-kms

A mock version of AWS' Key Management Service, for local development and testing.
MIT License
198 stars 34 forks source link

Issue with Docker for windows 2.1.0.0 #8

Closed mibollma closed 5 years ago

mibollma commented 5 years ago

When running the local-kms container in windows container mode with experimental features turned on (to mix windows and linux containers) the container can be started but not stopped or killed anymore once its running. Works fine with the previous release 2.0.0.3.

nsmithuk commented 5 years ago

Hi. Thanks for your message.

Local KMS doesn't do anything special in terms of the how it reacts to kill signals. In all versions it just relies on Go's http.ListenAndServe method for persisting the application (and thus the container).

If there's something odd going on within Go, I've just upgraded to 1.12 in the latest push. That may have helped.

Beyond that though I'm afraid I have no experience with windows container mode. I've never heard of not being able to kill a Docker container from the host. Sounds like it may still be a little too experimental! :-)

mibollma commented 5 years ago

Thanks for your reply. I will stick with docker 2.0.0.3 for now.

However I'm also running a local dynamodb and s3 instance which don't show those symptoms. Maybe it's also related to access to the filesystem as the local kms is the only one that reads it's config that way. If you are interested in any logs or experiments I can assist you with just let me know.

nsmithuk commented 5 years ago

Maybe it's also related to access to the filesystem as the local kms is the only one that reads its config that way.

You can supply config via other means. For things like local DynamoDB & S3, I use the aws cli. There shouldn't be any reason you can't config Local KMS the same way.

Or if your config is quite static, it would be quite simple to remove the need for filesystem access by creating your own Dockerfile with your config copied in. That would also mean the container would run without filesystem access, but you'd still get the benefit of seeding.

FROM nsmithuk/local-kms:3
COPY ./init/ /init

Yes, please do send me any details you're able to see.

mibollma commented 5 years ago

The issue disappeared with the latest bugfix release 2.1.0.2.