简体   繁体   中英

How to fix 'Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only' error in windows server 2019 with DockerProvider service

I'm installed docker in windows server 2019 with DockerProvider<\/code> I'm using this code

Install-Module DockerProvider
Install-Package Docker -ProviderName DockerProvider -RequiredVersion preview
[Environment]::SetEnvironmentVariable("LCOW_SUPPORTED", "1", "Machine")

Solution is to map a different volume where the cookie file will be created;

So for your example, not;

- rabbitmq:/var/lib/rabbitmq

but;

- rabbitmq:/var/lib/rabbitmq/mnesia

You also have the option to overwrite the command<\/code> of the docker image to fix the issue it is complaining about. Assuming that your cookie file is \/var\/lib\/rabbitmq\/.erlang.cookie<\/code> , replace the original docker image command, which is probably:

["rabbitmq-server"]

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM