feat: add build via docker

This commit is contained in:
Georg K
2023-01-06 02:30:39 +03:00
parent 03c59fec32
commit 731b58304c
6 changed files with 119 additions and 17 deletions

View File

@@ -3,23 +3,11 @@ stages:
release-deb:
stage: release-deb
image: ubuntu:18.04
image: docker:latest
variables:
DEBIAN_FRONTEND: noninteractive
RADIUS_REPO: "https://github.com/FreeRADIUS/freeradius-server.git"
RADIUS_TAG: "v3.2.x"
RLM_RAW_REPO: "https://github.com/jar3b/rlm_raw.git"
RLM_RAW_TAG: "master"
DOCKER_BUILDKIT: 1
script:
- apt-get update
- apt-get install -y devscripts equivs git quilt gcc
- mkdir -p /usr/local/src/repositories && cd /usr/local/src/repositories
- git clone --depth 1 --single-branch --branch ${RADIUS_TAG} ${RADIUS_REPO}
- git clone --depth 1 --single-branch --branch ${RLM_RAW_TAG} ${RLM_RAW_REPO}
- mv rlm_raw/rlm_raw freeradius-server/src/modules
- cd freeradius-server
- git checkout ${RADIUS_TAG} && debian/rules debian/control && echo 'y' | mk-build-deps -irt'apt-get -yV' debian/control
- make -j2 deb
- ls -la ..
- docker build . -t freerad_builder:3.2.x -f Dockerfile_build
- docker run -e DEB_USER=${DEB_USER} -e DEB_PASS="${DEB_PASS}" freerad_builder:3.2.x /bin/bash
only:
- main