summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrubo77 <github@r.z11.de>2018-09-06 20:03:19 +0200
committerrubo77 <github@r.z11.de>2018-09-06 20:03:19 +0200
commitf4b6ff5aa44e46364cd9c354a9aeb315be9a7571 (patch)
tree3494c3559dfd73420f690899a3b965f31939a87f
parente195237e1d6592446c67daa5b995e37cae7674f6 (diff)
parent4cb693e2b8bc01e68598987ac4ead650f6e8dd0b (diff)
Merge remote-tracking branch 'gitlab.toppoint/master'
-rw-r--r--.gitlab-ci.yml38
-rw-r--r--.gitlab-ci/docker/Dockerfile5
m---------.gitlab-ci/ffki_scripts0
-rw-r--r--.gitmodules3
4 files changed, 46 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000..fe068f6
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,38 @@
+variables:
+ GIT_SUBMODULE_STRATEGY: recursive
+ GIT_SSL_CAPATH: /etc/ssl/certs/
+ CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/build
+ GATEWAYS: "vpn6 vpn0"
+ GATEWAY_DEPLOY_USER: mesh_vpn_ci_ffki
+ GATEWAY_HOST_vpn0: vpn0.freifunk.in-kiel.de
+ GATEWAY_HOST_vpn6: vpn6.freifunk.in-kiel.de
+
+stages:
+ - container
+ - validate
+ - deploy
+
+docker:
+ stage: container
+ image: docker:latest
+ services:
+ - docker:dind
+ script:
+ - docker info
+ - docker login -u $CI_REGISTRY_USER -p $CI_JOB_TOKEN $CI_REGISTRY
+ - docker pull $CONTAINER_IMAGE:latest || true
+ - docker build --cache-from $CONTAINER_IMAGE:latest -t $CONTAINER_IMAGE:$CI_COMMIT_SHA -t $CONTAINER_IMAGE:latest .gitlab-ci/docker
+ - docker push $CONTAINER_IMAGE:$CI_COMMIT_SHA
+ - docker push $CONTAINER_IMAGE:latest
+
+validate:
+ stage: validate
+ image: $CI_REGISTRY_IMAGE/build
+ script:
+ - ./.gitlab-ci/ffki_scripts/mesh_vpn/check-fastd-keys.sh
+
+deploy:
+ stage: deploy
+ image: $CI_REGISTRY_IMAGE/build
+ script:
+ - ./.gitlab-ci/ffki_scripts/mesh_vpn/deploy-fastd-keys.sh
diff --git a/.gitlab-ci/docker/Dockerfile b/.gitlab-ci/docker/Dockerfile
new file mode 100644
index 0000000..af1d82a
--- /dev/null
+++ b/.gitlab-ci/docker/Dockerfile
@@ -0,0 +1,5 @@
+FROM debian:stretch
+
+RUN apt-get update && apt-get install -y \
+ git \
+ openssh-client
diff --git a/.gitlab-ci/ffki_scripts b/.gitlab-ci/ffki_scripts
new file mode 160000
+Subproject 4d432abdf8a880b936efd865d2d8ed99de46798
diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 0000000..315fdb6
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,3 @@
+[submodule ".gitlab-ci/ffki_scripts"]
+ path = .gitlab-ci/ffki_scripts
+ url = https://github.com/TobleMiner/ffki-scripts.git