-
Notifications
You must be signed in to change notification settings - Fork 288
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to use host storage in kubernetes #1703
Comments
Hello, In the 18.03-rc1 edge version (due this week), you will be able to use hostPath type volume to mount volumes shared from the host. Just use a hostPath volume. VM-side, the shared drive are in the |
That does not seem to work, gives me an error saying something about
failing test for directory.
…On Mon, Feb 19, 2018, 08:01 Pierre Gayvallet ***@***.***> wrote:
Hello,
In the 18.03-rc1 edge version (due this week), you will be able to use
hostPath type volume to mount volumes shared from the host. Just use a
hostPath volume. VM-side, the shared drive are in the /host_mnt folder.
I.E: "/host_mnt/c/path/to/my/folder for a folder in the C drive.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1703 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHS44Bzp4vxWftfI6zoCgCbKituAPvzYks5tWX6vgaJpZM4SGBRc>
.
|
OK, it works when I do not specify a type, but if I speficy type: Directory
I get the error "MountVolume.SetUp failed for volume "host" : hostPath type
check failed: /host_mnt/e/mysql_data is not a directory" on anything other
than the root.
…On Mon, Feb 19, 2018 at 8:13 AM, Jeffrey Parker ***@***.***> wrote:
That does not seem to work, gives me an error saying something about
failing test for directory.
On Mon, Feb 19, 2018, 08:01 Pierre Gayvallet ***@***.***>
wrote:
> Hello,
>
> In the 18.03-rc1 edge version (due this week), you will be able to use
> hostPath type volume to mount volumes shared from the host. Just use a
> hostPath volume. VM-side, the shared drive are in the /host_mnt folder.
> I.E: "/host_mnt/c/path/to/my/folder for a folder in the C drive.
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#1703 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AHS44Bzp4vxWftfI6zoCgCbKituAPvzYks5tWX6vgaJpZM4SGBRc>
> .
>
|
+1 |
+1 |
Do you need to have shared drives set up to enable k8s persistent volumes? It asks me to share the c:\ drive whenever I try to create a PVC. Seeing the same behavior as in #77 and I am not having success with setting up shared drives in Docker for Windows. Tried suggestions here: http://peterjohnlightfoot.com/docker-for-windows-on-hyper-v-fix-the-host-volume-sharing-issue/ and here: https://blogs.msdn.microsoft.com/stevelasker/2016/06/14/configuring-docker-for-windows-volumes/ Neither work. |
Invalid mode issue can be solved for me by replacing
with
Misleading error message, but there's an issue for that already here: |
@pgayvallet Thank you for your comment, it totally works, how... do you know this? :) I'm trying to figure out where the documentation is for this, but the only thing I can find is a reference in Docker for Windows Stable Release notes under Docker Community Edition 17.12.0-ce-win47 2018-01-12:
Thank you! (I'm only commenting here because the issue is still open.) |
Issues go stale after 90d of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
Closed issues are locked after 30 days of inactivity. If you have found a problem that seems similar to this, please open a new issue. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
Expected behavior
Able to mount shared drive in containers running in kubernetes
Actual behavior
Could not find any way to configure this
Information
I am using Docker for Windows Edge with the built in Kubernetes configuration and trying to mount a persistent volume of some kind from the host. I am running Windows 10 Enterprise. I thought I would be able to use the local volumes that were added as alpha in Kubernetes, but they are behind feature gates and I do not see any way to enable them so I can use that.
Steps to reproduce the behavior
The text was updated successfully, but these errors were encountered: