mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-17 20:53:02 +00:00
Add docker-pybombs-gnsssdr job and file header. Try to meake it usable for other users
This commit is contained in:
parent
136f3d22c2
commit
57fc370ffa
@ -1,7 +1,59 @@
|
||||
# This script sets up a Continuous Reproducibility system for GNSS-SDR at GitLab
|
||||
#
|
||||
# Useful links:
|
||||
# Website: http://gnss-sdr.org
|
||||
# Upstream repository: https://github.com/gnss-sdr/gnss-sdr.git
|
||||
# Dockerfile at https://github.com/carlesfernandez/docker-gnsssdr
|
||||
# Docker cloud image: carlesfernandez/docker-gnsssdr
|
||||
#
|
||||
# In order to use this system and be able to make changes, you will need:
|
||||
# - A GitHub account https://github.com
|
||||
# - A GitLab account https://gitlab.com
|
||||
# - A Docker Hub account https://hub.docker.com
|
||||
# - A repository at Docker Hub.
|
||||
#
|
||||
# In order to use this system, please fork at GitHub the upstream
|
||||
# repository; import that forked repo at GitLab; then add, commit and push to
|
||||
# your GitLab repo this .gitlab-ci.yml file; and finally go to your project page
|
||||
# at GitLab and set up the following secret variables. In the left panel:
|
||||
# Settings > CI / CD > Secret variables
|
||||
#
|
||||
# CI_REGISTRY_USER <- Leave it blank
|
||||
# CI_REGISTRY_PASWORD <- Leave it blank
|
||||
# DOCKER_HUB_USER
|
||||
# DOCKER_HUB_REPO
|
||||
# DOCKER_HUB_PASSWORD
|
||||
#
|
||||
# For instance, my settings are:
|
||||
# CI_REGISTRY_USER = carlesfernandez
|
||||
# CI_REGISTRY_PASWORD = ********************
|
||||
# DOCKER_HUB_USER = carlesfernandez
|
||||
# DOCKER_HUB_REPO = docker-gnsssdr
|
||||
# DOCKER_HUB_PASSWORD = ********************
|
||||
#
|
||||
# If you want to make changes in the source code, please branch-off from the
|
||||
# 'next' branch of your forked repository and, if needed, add new jobs in this
|
||||
# file at the 'deploy' and 'experiment' stages. You can also change the
|
||||
# DOCKERFILE_URL variable below if your changes in the source code require extra
|
||||
# packages or build steps.
|
||||
#
|
||||
# Feel free to delete the docker-gnsssdr and docker-pybombs-gnsssdr jobs,
|
||||
# they are for developers' team only. Actually, this is their CI/CD system.
|
||||
#
|
||||
# More info about how to contribute to GNSS-SDR at
|
||||
# https://github.com/gnss-sdr/gnss-sdr/blob/master/CONTRIBUTING.md
|
||||
#
|
||||
# (C) Carles Fernandez-Prades, 2018 cfernandez@cttc.cat
|
||||
|
||||
variables:
|
||||
DOCKERFILE_URL: "https://raw.githubusercontent.com/carlesfernandez/docker-gnsssdr/master/Dockerfile"
|
||||
|
||||
|
||||
# Is performed before the scripts in the stages step
|
||||
before_script:
|
||||
- source /etc/profile
|
||||
|
||||
|
||||
# Defines stages which are to be executed
|
||||
stages:
|
||||
- build
|
||||
@ -9,6 +61,7 @@ stages:
|
||||
- deploy
|
||||
- experiment
|
||||
|
||||
|
||||
# Stage "build"
|
||||
debian8.10:
|
||||
image: debian:8.10-slim
|
||||
@ -146,25 +199,43 @@ docker-gnsssdr:
|
||||
allow_failure: true
|
||||
|
||||
|
||||
docker-pybombs-gnsssdr:
|
||||
image: docker:latest
|
||||
stage: deploy
|
||||
services:
|
||||
- docker:dind
|
||||
script:
|
||||
- wget https://raw.githubusercontent.com/carlesfernandez/docker-pybombs-gnsssdr/master/Dockerfile
|
||||
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD"
|
||||
- mkdir docker-build
|
||||
- cd docker-build
|
||||
- cp ../Dockerfile .
|
||||
- docker build -t carlesfernandez/docker-pybombs-gnsssdr .
|
||||
- docker push carlesfernandez/docker-pybombs-gnsssdr
|
||||
only:
|
||||
- next
|
||||
allow_failure: true
|
||||
|
||||
|
||||
docker-access18:
|
||||
image: docker:latest
|
||||
stage: deploy
|
||||
services:
|
||||
- docker:dind
|
||||
script:
|
||||
- wget https://raw.githubusercontent.com/carlesfernandez/docker-gnsssdr/master/Dockerfile
|
||||
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD"
|
||||
- wget $DOCKERFILE_URL
|
||||
- docker login -u "$DOCKER_HUB_USER" -p "$DOCKER_HUB_PASSWORD"
|
||||
- mkdir docker-build
|
||||
- cd docker-build
|
||||
- cp ../Dockerfile .
|
||||
- docker build -t carlesfernandez/docker-gnsssdr .
|
||||
- docker tag carlesfernandez/docker-gnsssdr:latest carlesfernandez/docker-gnsssdr:access18
|
||||
- docker push carlesfernandez/docker-gnsssdr:access18
|
||||
- docker build -t $DOCKER_HUB_USER/$DOCKER_HUB_REPO .
|
||||
- docker tag $DOCKER_HUB_USER/$DOCKER_HUB_REPO:latest $DOCKER_HUB_USER/$DOCKER_HUB_REPO:access18
|
||||
- docker push $DOCKER_HUB_USER/$DOCKER_HUB_REPO:access18
|
||||
|
||||
|
||||
# Stage "experiment"
|
||||
run-access18:
|
||||
image: carlesfernandez/docker-gnsssdr:access18
|
||||
image: $DOCKER_HUB_USER/$DOCKER_HUB_REPO:access18
|
||||
stage: build
|
||||
script:
|
||||
- apt-get update
|
||||
@ -175,11 +246,11 @@ run-access18:
|
||||
- cd data
|
||||
- curl https://zenodo.org/record/1172670/files/L2_signal_samples.tar.xz --output L2_signal_samples.tar.xz
|
||||
- tar xvfJ L2_signal_samples.tar.xz
|
||||
- md5sum L2_signal_samples.dat > data.md5
|
||||
- echo "2090ad3dfb3f461314252a1e6243d714 L2_signal_samples.tar.xz" > data.md5
|
||||
- md5sum -c data.md5
|
||||
- cd ..
|
||||
# Execute the experiment (example)
|
||||
- echo " x = 0:0.01:3; hf = figure (\"visible\", \"off\"); plot (x, erf (x)); hold on; plot (x, x, \"r\"); axis ([0, 3, 0, 1]); text (0.65, 0.6175, ['$ \leftarrow x = \frac{2}{\sqrt{\pi}} \int_{0}^{x}e^{-t^2} dt = 0.6175 $']); xlabel (\"x\"); ylabel (\"erf (x)\"); title (\"erf (x) with text annotation\"); hh=findall(hf,\"-property\",\"FontName\"); set(hh,\"FontName\",\"Times\"); hh2=findall(hf,\"-property\",\"interpreter\"); set(hh2, \"interpreter\", \"tex\"); hh3=findall(hf,\"-property\",\"FontSize\"); set(hh3, \"FontSize\", 22); print (hf, \"results.eps\", \"-depsc\"); " > my_test_file.m
|
||||
- echo " x = 0:0.01:3; hf = figure (\"visible\", \"off\"); plot (x, erf (x), \"linewidth\", 2); hold on; plot (x, x, \"r\", \"linewidth\", 2); axis ([0, 3, 0, 1]); text (0.65, 0.6175, ['\leftarrow x = \pi \int_{0}^{x}e^{-t^2} dt = 0.6175 ']); xlabel (\"x\"); ylabel (\"erf (x)\"); title (\"erf (x) with text annotation\"); hh=findall(hf,\"-property\",\"FontName\"); set(hh,\"FontName\",\"Times\"); hh2=findall(hf,\"-property\",\"interpreter\"); set(hh2, \"interpreter\", \"tex\"); hh3=findall(hf,\"-property\",\"FontSize\"); set(hh3, \"FontSize\", 22); print (hf, \"results.eps\", \"-depsc\"); " > my_test_file.m
|
||||
- octave --no-gui my_test_file.m
|
||||
- epspdf results.eps results.pdf
|
||||
- mkdir access18
|
||||
|
Loading…
Reference in New Issue
Block a user