Skip to content

Commit 10e8072

Browse files
committed
Merge branch 'develop'
2 parents b2007c7 + 4b50101 commit 10e8072

File tree

3 files changed

+248
-142
lines changed

3 files changed

+248
-142
lines changed

CHANGELOG.md

+9
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,15 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
55
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
66

7+
## [1.2.0] - 2018-09-26
8+
9+
### Added
10+
* upon successful server startup, log:
11+
* list of enabled NFS versions
12+
* list of exports
13+
* list of ports that should be exposed
14+
* improved error detection and logging
15+
716
## [1.1.1] - 2018-08-21
817

918
### Fixed

README.md

+15-15
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ This is the only containerized NFS server that offers **all** of the following f
4141
- `rpcsec_gss_krb5` (*only if Kerberos is used*)
4242

4343
Usually you can enable these modules with: `modprobe {nfs,nfsd,rpcsec_gss_krb5}`
44-
1. The container will need to run with `CAP_SYS_ADMIN` (or `--privileged`). This is necessary as the server needs to mount several filesystems inside the container to support its operation, and performing mounts from inside a container is impossible without these capabilities.
44+
1. The container will need to run with `CAP_SYS_ADMIN` (or `--privileged`). This is necessary as the server needs to mount several filesystems *inside* the container to support its operation, and performing mounts from inside a container is impossible without these capabilities.
4545
1. The container will need local access to the files you'd like to serve via NFS. You can use Docker volumes, bind mounts, files baked into a custom image, or virtually any other means of supplying files to a Docker container.
4646

4747
## Usage
@@ -50,11 +50,11 @@ This is the only containerized NFS server that offers **all** of the following f
5050

5151
Starting the `erichough/nfs-server` image will launch an NFS server. You'll need to supply some information upon container startup, which we'll cover below, but briefly speaking your `docker run` command might look something like this:
5252

53-
docker run \
54-
-v /host/path/to/shared/files:/nfs \
55-
-v /host/path/to/exports.txt:/etc/exports:ro \
56-
--cap-add SYS_ADMIN \
57-
-p 2049:2049 \
53+
docker run \
54+
-v /host/path/to/shared/files:/some/container/path \
55+
-v /host/path/to/exports.txt:/etc/exports:ro \
56+
--cap-add SYS_ADMIN \
57+
-p 2049:2049 \
5858
erichough/nfs-server
5959
6060
Let's break that command down into its individual pieces to see what's required for a successful server startup.
@@ -63,15 +63,15 @@ Let's break that command down into its individual pieces to see what's required
6363

6464
As noted in the [requirements](#requirements), the container will need local access to the files you'd like to share over NFS. Some ideas for supplying these files:
6565

66-
* [bind mounts](https://docs.docker.com/storage/bind-mounts/) (`-v /host/path/to/shared/files:/nfs`)
67-
* [volumes](https://docs.docker.com/storage/volumes/) (`-v some_volume:/nfs`)
68-
* files [baked into](https://docs.docker.com/engine/reference/builder/#copy) custom image (e.g. in a `Dockerfile`: `COPY /host/files /nfs`)
66+
* [bind mounts](https://docs.docker.com/storage/bind-mounts/) (`-v /host/path/to/shared/files:/some/container/path`)
67+
* [volumes](https://docs.docker.com/storage/volumes/) (`-v some_volume:/some/container/path`)
68+
* files [baked into](https://docs.docker.com/engine/reference/builder/#copy) custom image (e.g. in a `Dockerfile`: `COPY /host/files /some/container/path`)
6969

7070
You may use any combination of the above, or any other means to supply files to the container.
7171

7272
1. **Provide your desired [NFS exports](https://linux.die.net/man/5/exports) (`/etc/exports`)**
7373

74-
You'll need to tell the server which container directories to export. You have *three options* for this; choose whichever one you prefer:
74+
You'll need to tell the server which **container directories** to share. You have *three options* for this; choose whichever one you prefer:
7575

7676
1. bind mount `/etc/exports` into the container
7777

@@ -84,10 +84,10 @@ Let's break that command down into its individual pieces to see what's required
8484

8585
The container will look for environment variables that start with `NFS_EXPORT_` and end with an integer. e.g. `NFS_EXPORT_0`, `NFS_EXPORT_1`, etc.
8686

87-
docker run \
88-
-e NFS_EXPORT_0='/nfs/foo *(ro,no_subtree_check)' \
89-
-e NFS_EXPORT_1='/nfs/bar 123.123.123.123/32(rw,no_subtree_check)' \
90-
... \
87+
docker run \
88+
-e NFS_EXPORT_0='/container/path/foo *(ro,no_subtree_check)' \
89+
-e NFS_EXPORT_1='/container/path/bar 123.123.123.123/32(rw,no_subtree_check)' \
90+
... \
9191
erichough/nfs-server
9292

9393
1. bake `/etc/exports` into a custom image
@@ -153,7 +153,7 @@ Please [open an issue](https://github.com/ehough/docker-nfs-server/issues) if yo
153153
154154
## Remaining tasks
155155
156-
- switch to Alpine Linux once [this bug](https://bugs.alpinelinux.org/issues/8470) in `nfs-utils` is fixed
156+
- switch to Alpine Linux once `nfs-utils` version 2.3.1-r4 (or higher) is released in a stable repo (maybe Alpine 3.9?). See [this bug](https://bugs.alpinelinux.org/issues/8470) for details
157157
- figure out why `rpc.nfsd` takes 5 minutes to startup/timeout unless `rpcbind` is running
158158
- add more examples, including Docker Compose
159159

0 commit comments

Comments
 (0)