Code Monkey home page Code Monkey logo

nfs4-server's Introduction

NFS4 Server

On Github

Uses :

NFS v4 server server running on Alpine Linux.

Prerequisites

Get docker !

Configuration

The server uses a generic export file (exports) with-in the mount points and the relative disk capping. You have to define a docker compose, the volume within your export file and the share of the mount points defined in the export files, then the image and the port exports as shown in the provided example

Issues

Open an issue

Build the image

There is not yet any registration in the docker hub, however you can follow the example and use the script file create-docker-image.sh.

Quickstart

Here an example of the configuration :

docker-compose.yml

nfs4-server:
  image: nfs4-server:1.0
  container_name: nfs-server

  # Required to load kernel NFS module
  privileged: true

  volumes:
    # You must provide an exports config file
    - ./exports:/etc/exports

    # Shares
    - /mnt:/mnt
    - /mnt/nfs/volume:/mnt/volume
    - /mnt/nfs/backup:/mnt/backup

  ports:
    - "111:111/tcp"
    - "111:111/udp"
    - "2049:2049/tcp"
    - "2049:2049/udp"

exports :

/mnt		*(rw,fsid=0,root_squash,no_subtree_check,insecure)
/mnt/volume		*(rw,fsid=0,root_squash,no_subtree_check,insecure)
/mnt/backup		*(rw,fsid=0,root_squash,no_subtree_check,insecure)

In this way in your DNS4 Server you will have a share of three folders :

  • /nfs
  • /volume
  • /backup

Test

To test the NFS4 Server Example on ubuntu :

  • update the ubuntu packages cache apt-get update
  • install the nfs-common package apt-get install -y nfs-common
  • clean your system libraries cache by unused space :
apt-get -y autoremove && \
    apt-get -y clean && \
    rm -rf /var/lib/apt/lists/*
  • mount the nfs path from the server : (eg. on the same machine : mount -rw -v -t nfs -o proto=tcp,port=2049 localhost:/ /media)

License

MIT

nfs4-server's People

Watchers

James Cloos avatar Fabrizio Torelli avatar

Forkers

skyice2013

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.