T1070 - docker build of vyos-strongswan (#31)

* T1070 - Added packages and readme notes about building strongswan

strongswan is easely built using a docker image, but needs special options to pass tests.
Added notes in the readme about building it and building instructions

* T1070 - Restructured build example for wyos-strongswan
This commit is contained in:
runborg 2018-12-17 23:35:18 +01:00 committed by Daniil Baturin
parent 7889203766
commit dfbe78ffba
2 changed files with 41 additions and 0 deletions

View File

@ -41,6 +41,30 @@ RUN echo 'deb http://ftp.debian.org/debian jessie-backports main' | tee -a /etc/
python3-nose \
python3-coverage
# Packages needed for building vyos-strongswan
RUN apt-get install -y -t jessie-backports \
debhelper &&\
apt-get install -y \
dh-apparmor \
gperf \
iptables-dev \
libcap-dev \
libgcrypt20-dev \
libgmp3-dev \
libldap2-dev \
libpam0g-dev \
libsystemd-dev \
libgmp-dev \
iptables \
xl2tpd \
libcurl4-openssl-dev \
libcurl4-openssl-dev \
libkrb5-dev \
libsqlite3-dev \
libssl-dev \
libxml2-dev \
pkg-config
# Update live-build
RUN echo 'deb http://ftp.debian.org/debian stretch main' | tee -a /etc/apt/sources.list.d/stretch.list &&\
apt-get update &&\

View File

@ -153,6 +153,23 @@ After the docker container is running you can git clone the vyos-build repositor
inside the container and follow up the bellow instructions in order to build the
VyOS ISO image
## Building subpackages inside Docker
### Strongswan
Prior to executing this you need to checkout and update the packages/vyos-strongswan submodule
Building the strongswan package is for now only doable on a Linux system because tests fail when running on windows and OSX systems
`/HOST_PATH/` is the path to your vyos_build directory. if youre in the vyos-build directory it can me replaced with `$(pwd)`
`--sysctl net.ipv6.conf.lo.disable_ipv6=0` is needed to enable ipv6 inside the container. tests will fail if you don't have it.
```bash
$ docker run -it -v /HOST_PATH/:/vyos --sysctl net.ipv6.conf.lo.disable_ipv6=0 vyos-builder \
bash -c '\
cd /vyos/packages/vyos-strongswan &&\
dpkg-buildpackage -uc -us -tc -b'
```
## Building the ISO image
Before you can build an image, you need to configure your build.