close

背景:我在 Windows 使用 WSL 練習 ansible 時發現 ansible 會阻擋過大權限的工作目錄,導致無法正常使用,而這個問題可能也會在其他套件中遇到。

 

經爬文發現網友有提供一個解法:在 WSL 中 /etc/ 下建立一個 wsl.conf 的檔案,並輸入以下內容存檔後重開機,將會在 /mnt/ 中套用 755 權限,而不是 777

[automount]
enabled = true
mountFsTab = false
root = /mnt/
options = "metadata,umask=22,fmask=11"

[network]
generateHosts = true
generateResolvConf = true

參考來源: https://github.com/ansible/ansible/issues/42388#issuecomment-403926971

arrow
arrow
    文章標籤
    wsl ansible
    全站熱搜

    AwEi 發表在 痞客邦 留言(0) 人氣()