Skip to content
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

Explain setting file permission on Windows when using Docker to set up a node. #6

Open
Thomasedv opened this issue Oct 7, 2021 · 0 comments
Labels
docs Improvements or additions to documentation

Comments

@Thomasedv
Copy link

Thomasedv commented Oct 7, 2021

Hello,

A requirement to run a node (and verify the key pair) is that the following permissions are set. The following command is provided on the Connect to Network page, under the Docker section. (The commands are also used on the key pair generation page.)

chmod 700 ~/keys
chmod 600 ~/keys/my-wallet

Windows users can't normally run these commands, and that may pose a problem if the user decides to share a windows folder containing the keys to docker using the --bind/--volume commands. The user may face an issue where the programs throw an error that the permissions are incorrectly set.

The suggestion is to add a warning block in the docs to Windows users, informing them to use Windows Subsystem for Linux (WSL) to perform the permission changes. Modern Docker makes use of WSL, and it is assumed that it's enabled on the Windows machine using Docker.

Here is a short guide showing how to perform these steps from a windows terminal. In my case, using Powershell, but it's assumed the command line (CMD) works as well.

  1. Open Powershell/CMD in the directory where the keys folder is located.
  2. Type wsl -d docker-desktop to open Windows Subsystem for Linux with the docker-desktop distribution (It should be available since you installed docker). You are now in a linux environment, and can run the above commands, however, some modifications need to be done.
  3. Since the active directory is the folder with the files, you can drop the ~, and you need to make sure that you only use forward / slashes. The process will look something like the following. If no error message appears, the permission change completed successfully.
PS C:\CryptoWallet> wsl docker-desktop
Desktop-name:/tmp/docker-desktop-root/mnt/host/c/CryptoWallet# chmod 700 keys
Desktop-name:/tmp/docker-desktop-root/mnt/host/c/CryptoWallet# chmod 600 keys/my-wallet

This should allow users to continue as normal with the installation and use of the mina node software.

@barriebyron barriebyron added the docs Improvements or additions to documentation label Aug 15, 2023
MartinMinkov pushed a commit that referenced this issue Sep 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants