]> git.proxmox.com Git - mirror_frr.git/blob - doc/developer/building-frr-on-alpine.rst
zebra: Cleanup lines over 80 columns
[mirror_frr.git] / doc / developer / building-frr-on-alpine.rst
1 Alpine Linux 3.7+
2 =========================================================
3
4 For building Alpine Linux dev packages, we use docker.
5
6 Install docker 17.05 or later
7 -----------------------------
8
9 Depending on your host, there are different ways of installing docker. Refer
10 to the documentation here for instructions on how to install a free version of
11 docker: https://www.docker.com/community-edition
12
13 Work with sources
14 -----------------
15
16 ::
17
18 git clone https://github.com/frrouting/frr.git frr
19 cd frr
20
21 Build apk packages
22 ------------------
23
24 ::
25
26 ./docker/alpine/build.sh
27
28 This will put the apk packages in:
29
30 ::
31
32 ./docker/pkgs/apk/x86_64/
33
34 Usage
35 -----
36
37 To create a base image with the frr packages installed:
38
39 ::
40
41 docker build --rm -f docker/alpine/Dockerfile -t frr:latest .
42
43 Or, if you don't have a git checkout of the sources, you can build a base
44 image directly off the github account:
45
46 ::
47
48 docker build --rm -f docker/alpine/Dockerfile -t frr:latest \
49 https://github.com/frrouting/frr.git
50
51 And to run the image:
52
53 ::
54
55 docker run -it --rm frr:latest /bin/sh
56
57 Currently, we only package the raw daemons and example files, so, you'll
58 need to run the daemons by hand (or, better, orchestrate in the Dockerfile).
59
60 We can also build directly from docker-compose, with a docker-compose.yml file
61 like this one:
62
63 ::
64
65 version: '2.2'
66
67 services:
68 frr:
69 build:
70 context: https://github.com/frrouting/frr.git
71 dockerfile: docker/alpine/Dockerfile