├── Dockerfile ├── LICENSE └── README.md /Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:14.04 2 | 3 | RUN apt-get update 4 | RUN apt-get install -y software-properties-common 5 | 6 | RUN add-apt-repository -y ppa:named-data/ppa 7 | RUN apt-get update 8 | RUN apt-get install -y nfd 9 | 10 | CMD nfd 11 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2014 Felix Rabe 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Using NFD with Docker 2 | 3 | ## Step 1: Install Docker 4 | 5 | Follow the [official installation instructions](http://docs.docker.com/installation/). Docker runs natively on (recent) Linux kernels, and via a VM on Windows and Mac OS X. 6 | 7 | ## Step 2: Build the image 8 | 9 | Open a terminal and change to the new directory created above. Now execute the following command to build an image called `named_data/nfd`: 10 | 11 | docker build -t named_data/nfd . 12 | 13 | This is similar to a compilation step to transform source code (the Dockerfile) into executable code (the Docker image). The first time you run that command, it will pull the Ubuntu base image; this will take some time. Later rebuilds happen fast, thanks to Docker's snapshotting. 14 | 15 | ## Step 3: Run the image 16 | 17 | To start a process (create a Docker container), you use the `docker run` command. 18 | 19 | docker run named_data/nfd 20 | 21 | # About Docker 22 | 23 | [Docker](https://www.docker.com/) is a command-line frontend to operating system-level virtualization solutions such as Linux containers (LXC). This allows running application processes in isolation, just like a VM, but without the overhead of a traditional VM – for example, there is no (operating system) boot process involved. 24 | 25 | The [interactive Docker tutorial](https://www.docker.com/tryit/) is a great way to get started with Docker. 26 | 27 | You find the full documentation of the [`docker run` command](https://docs.docker.com/reference/run/) along with the full [command line reference](https://docs.docker.com/reference/commandline/cli/) on the [Docker documentation site](https://docs.docker.com/). 28 | 29 | Docker works best if a container runs only one process at a time, such as NFD. Bash is usually only used for exploration. To trim down the image, consider using Debian (90 MB) or Busybox (2.5 MB) as a base image instead of Ubuntu (225 MB). (There are currently no instructions for these base images, as these distributions are currently not supported / tested by the Named Data project.) 30 | 31 | # TODO 32 | 33 | * Push a trusted build to the [Docker registry](https://registry.hub.docker.com/) so others can directly pull the pre-built image. 34 | --------------------------------------------------------------------------------