Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
3a914c25
Commit
3a914c25
authored
Mar 07, 2016
by
Huamin Chen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix #22529: disable nfsv4 and use nfsv3
parent
e93c0d72
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
10 deletions
+21
-10
Dockerfile
test/images/volumes-tester/nfs/Dockerfile
+5
-4
Makefile
test/images/volumes-tester/nfs/Makefile
+1
-1
run_nfs.sh
test/images/volumes-tester/nfs/run_nfs.sh
+15
-5
No files found.
test/images/volumes-tester/nfs/Dockerfile
View file @
3a914c25
...
@@ -17,9 +17,10 @@ MAINTAINER Jan Safranek, jsafrane@redhat.com
...
@@ -17,9 +17,10 @@ MAINTAINER Jan Safranek, jsafrane@redhat.com
RUN
yum
-y
install
/usr/bin/ps nfs-utils
&&
yum clean all
RUN
yum
-y
install
/usr/bin/ps nfs-utils
&&
yum clean all
RUN
mkdir
-p
/exports
RUN
mkdir
-p
/exports
ADD
run_nfs.sh /usr/local/bin/
ADD
run_nfs.sh /usr/local/bin/
ADD
index.html /
exports
/index.html
ADD
index.html /
tmp
/index.html
RUN
chmod
644 /
exports
/index.html
RUN
chmod
644 /
tmp
/index.html
EXPOSE
2049/tcp
# expose mountd 20048/tcp and nfsd 2049/tcp
EXPOSE
2049/tcp 20048/tcp
ENTRYPOINT
["/usr/local/bin/run_nfs.sh", "/exports"]
ENTRYPOINT
["/usr/local/bin/run_nfs.sh", "/exports"
, "/"
]
test/images/volumes-tester/nfs/Makefile
View file @
3a914c25
...
@@ -12,7 +12,7 @@
...
@@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# See the License for the specific language governing permissions and
# limitations under the License.
# limitations under the License.
TAG
=
0.
5
TAG
=
0.
6
PREFIX
=
gcr.io/google_containers
PREFIX
=
gcr.io/google_containers
all
:
push
all
:
push
...
...
test/images/volumes-tester/nfs/run_nfs.sh
View file @
3a914c25
...
@@ -21,19 +21,29 @@ function start()
...
@@ -21,19 +21,29 @@ function start()
for
i
in
"
$@
"
;
do
for
i
in
"
$@
"
;
do
# fsid=0: needed for NFSv4
# fsid=0: needed for NFSv4
echo
"
$i
*(rw,fsid=0,insecure,no_root_squash)"
>>
/etc/exports
echo
"
$i
*(rw,fsid=0,insecure,no_root_squash)"
>>
/etc/exports
# move index.html to here
/bin/cp /tmp/index.html
$i
/
chmod
644
$i
/index.html
echo
"Serving
$i
"
echo
"Serving
$i
"
done
done
# start rpcbind if it is not started yet
/usr/sbin/rpcinfo 127.0.0.1
>
/dev/null
;
s
=
$?
if
[
$s
-ne
0
]
;
then
echo
"Starting rpcbind"
/usr/sbin/rpcbind
-w
fi
mount
-t
nfsd nfds /proc/fs/nfsd
mount
-t
nfsd nfds /proc/fs/nfsd
# -N
2 -N 3: disable NFSv2+3
# -N
4.x: disable NFSv4
# -V
4.x: enable NFSv4
# -V
3: enable NFSv3
/usr/sbin/rpc.mountd
-N
2
-
N
3
-V
4
-V
4.1
/usr/sbin/rpc.mountd
-N
2
-
V
3
-N
4
-N
4.1
/usr/sbin/exportfs
-r
/usr/sbin/exportfs
-r
# -G 10 to reduce grace time to 10 seconds (the lowest allowed)
# -G 10 to reduce grace time to 10 seconds (the lowest allowed)
/usr/sbin/rpc.nfsd
-G
10
-N
2
-
N
3
-V
4
-V
4.1 2
/usr/sbin/rpc.nfsd
-G
10
-N
2
-
V
3
-N
4
-N
4.1 2
/usr/sbin/rpc.statd
--no-notify
echo
"NFS started"
echo
"NFS started"
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment