state - Ansible mount with state:mounted not working for sshfs
问题描述
我想使用 ansible 在 Ubuntu 18.04 上的 fstab 中添加一个 sshfs 条目。
Ansible 更改了我的 fstab 并添加了正确的行来挂载远程 sshfs 文件系统。但state: mounted
不起作用。它不会被安装。你有什么想法为什么?
- name: Adding fstab entry for borg remote mount point
mount:
path: /home/borg/backups-remote
src: borg@myserver.com:/users/borg
fstype: fuse.sshfs
opts: "defaults,allow_other,_netdev,idmap=user,follow_symlinks,identityfile=/home/borg/.ssh/id_rsa,allow_other,default_permissions,uid={{ borg_user.uid }},gid={{ borg_user.group }}"
state: mounted
register: backup_remote
解决方案
推荐阅读
- amazon-web-services - 如何调用 AMAZON.HelpIntent?
- django - WebSocket握手期间的Django通道错误:意外的响应代码:500
- iframe - 由于违反 CSP,网站未在 iframe 中显示
- python - 在这个问题上需要帮助 openpyxl.utils.exceptions.IllegalCharacterError
- java - Android 应用程序在调用方法时崩溃。该方法运行一些 if 语句并更改某些图像视图上的可绘制对象
- reactjs - 为什么异步 act() 调用不需要返回值
- python - 为什么if语句停留在表达式之后
- python - 缩放从类创建的 ttk.Frame
- ios - 如何使用 UView.animate 创建 U 形动画?- 斯威夫特
- r - 根据其他两列的值查看观察结果