File tree Expand file tree Collapse file tree 1 file changed +12
-6
lines changed
pkg/cidata/cidata.TEMPLATE.d/boot Expand file tree Collapse file tree 1 file changed +12
-6
lines changed Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
2
set -eux
3
3
4
+ update_fuse_conf (){
5
+ # Modify /etc/fuse.conf to allow "-o allow_root"
6
+ if [ " ${LIMA_CIDATA_MOUNTS} " -gt 0 ]; then
7
+ if ! grep -q " ^user_allow_other" /etc/fuse.conf ; then
8
+ echo " user_allow_other" >> /etc/fuse.conf
9
+ fi
10
+ fi
11
+ }
12
+
4
13
# Install minimum dependencies
5
14
if command -v apt-get 2>&1 > /dev/null; then
6
15
DEBIAN_FRONTEND=noninteractive
7
16
export DEBIAN_FRONTEND
8
17
apt-get update
9
18
if [ " ${LIMA_CIDATA_MOUNTS} " -gt 0 ]; then
10
19
apt-get install -y sshfs
20
+ update_fuse_conf
11
21
fi
12
22
if [ " ${LIMA_CIDATA_CONTAINERD_SYSTEM} " = 1 ] || [ " ${LIMA_CIDATA_CONTAINERD_USER} " = 1 ]; then
13
23
apt-get install -y iptables
@@ -18,6 +28,7 @@ if command -v apt-get 2>&1 >/dev/null; then
18
28
elif command -v dnf 2>&1 > /dev/null; then
19
29
if [ " ${LIMA_CIDATA_MOUNTS} " -gt 0 ]; then
20
30
dnf install -y fuse-sshfs
31
+ update_fuse_conf
21
32
fi
22
33
if [ " ${LIMA_CIDATA_CONTAINERD_SYSTEM} " = 1 ] || [ " ${LIMA_CIDATA_CONTAINERD_USER} " = 1 ]; then
23
34
dnf install -y iptables
@@ -35,13 +46,8 @@ elif command -v apk 2>&1 >/dev/null; then
35
46
apk update
36
47
apk add sshfs
37
48
fi
49
+ update_fuse_conf
38
50
modprobe fuse
39
51
fi
40
52
fi
41
- # Modify /etc/fuse.conf to allow "-o allow_root"
42
53
43
- if [ " ${LIMA_CIDATA_MOUNTS} " -gt 0 ]; then
44
- if ! grep -q " ^user_allow_other" /etc/fuse.conf ; then
45
- echo " user_allow_other" >> /etc/fuse.conf
46
- fi
47
- fi
You can’t perform that action at this time.
0 commit comments