Commit 0e8ed01d authored by Remi Perenon's avatar Remi Perenon
Browse files

Merge branch 'release-1.4.x'

parents 14ca490c dd493f11
Pipeline #7228 passed with stages
in 22 minutes and 39 seconds
stages: stages:
- docker_login - docker_pre_clean
- ci - ci
- deploy - deploy
- docker_logout - docker_post_clean
docker_login: docker_pre_clean:
stage: docker_login stage: docker_pre_clean
script: script:
- docker login -u gitlab-ci-token -p ${CI_JOB_TOKEN} ${CI_REGISTRY} - ${CI_PROJECT_DIR}/BuildServer/Docker/clean.sh
allow_failure: true
tags: tags:
- docker - docker
- sci - sci
- ubuntu - ubuntu
docker_post_clean:
stage: docker_post_clean
script:
- ${CI_PROJECT_DIR}/BuildServer/Docker/clean.sh
allow_failure: true
when: always
tags:
- docker
- sci
- ubuntu
############################ ############################
# ubuntu trusty pipeline # ubuntu trusty pipeline
############################ ############################
ci:ubuntu_trusty: ci:ubuntu_trusty:
stage: ci stage: ci
script: script:
- docker build --force-rm --build-arg MDANSE_GIT_COMMIT=${CI_COMMIT_SHA} -t ci_mdanse_trusty -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-trusty/Dockerfile_build . - docker build --force-rm=true -t ci_mdanse_trusty -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-trusty/Dockerfile_setup .
- docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_trusty_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-trusty/Dockerfile_build .
- docker run -iv${PWD}:/artifacts/ ci_mdanse_trusty_build
allow_failure: false allow_failure: false
artifacts:
paths:
- ${CI_PROJECT_DIR}/build
- ${CI_PROJECT_DIR}/temp
expire_in: 1 hrs
tags: tags:
- docker - docker
- sci - sci
...@@ -29,9 +48,9 @@ ci:ubuntu_trusty: ...@@ -29,9 +48,9 @@ ci:ubuntu_trusty:
deploy:ubuntu_trusty: deploy:ubuntu_trusty:
stage: deploy stage: deploy
script: script:
- docker build --force-rm -t deploy_mdanse_trusty -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-trusty/Dockerfile_deploy . - docker build --force-rm=true -t ci_mdanse_trusty -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-trusty/Dockerfile_setup .
- chmod 755 ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh - docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_trusty_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-trusty/Dockerfile_deploy .
- ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh trusty - docker run -iv${PWD}:/artifacts/ ci_mdanse_trusty_build
dependencies: dependencies:
- ci:ubuntu_trusty - ci:ubuntu_trusty
allow_failure: false allow_failure: false
...@@ -46,20 +65,27 @@ deploy:ubuntu_trusty: ...@@ -46,20 +65,27 @@ deploy:ubuntu_trusty:
when: on_success when: on_success
artifacts: artifacts:
paths: paths:
- ./*.deb - ${CI_PROJECT_DIR}/*.deb
tags: tags:
- docker - docker
- sci - sci
- ubuntu - ubuntu
############################ ############################
# ubuntu xenial pipeline # ubuntu xenial pipeline
############################ ############################
ci:ubuntu_xenial: ci:ubuntu_xenial:
stage: ci stage: ci
script: script:
- docker build --force-rm --build-arg MDANSE_GIT_COMMIT=${CI_COMMIT_SHA} -t ci_mdanse_xenial -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-xenial/Dockerfile_build . - docker build --force-rm=true -t ci_mdanse_xenial -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-xenial/Dockerfile_setup .
- docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_xenial_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-xenial/Dockerfile_build .
- docker run -iv${PWD}:/artifacts/ ci_mdanse_xenial_build
allow_failure: false allow_failure: false
artifacts:
paths:
- ${CI_PROJECT_DIR}/build
- ${CI_PROJECT_DIR}/temp
expire_in: 1 hrs
tags: tags:
- docker - docker
- sci - sci
...@@ -68,9 +94,9 @@ ci:ubuntu_xenial: ...@@ -68,9 +94,9 @@ ci:ubuntu_xenial:
deploy:ubuntu_xenial: deploy:ubuntu_xenial:
stage: deploy stage: deploy
script: script:
- docker build --force-rm -t deploy_mdanse_xenial -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-xenial/Dockerfile_deploy . - docker build --force-rm=true -t ci_mdanse_xenial -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-xenial/Dockerfile_setup .
- chmod 755 ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh - docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_xenial_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-xenial/Dockerfile_deploy .
- ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh xenial - docker run -iv${PWD}:/artifacts/ ci_mdanse_xenial_build
dependencies: dependencies:
- ci:ubuntu_xenial - ci:ubuntu_xenial
allow_failure: false allow_failure: false
...@@ -85,7 +111,7 @@ deploy:ubuntu_xenial: ...@@ -85,7 +111,7 @@ deploy:ubuntu_xenial:
when: on_success when: on_success
artifacts: artifacts:
paths: paths:
- ./*.deb - ${CI_PROJECT_DIR}/*.deb
tags: tags:
- docker - docker
- sci - sci
...@@ -97,8 +123,15 @@ deploy:ubuntu_xenial: ...@@ -97,8 +123,15 @@ deploy:ubuntu_xenial:
ci:ubuntu_bionic: ci:ubuntu_bionic:
stage: ci stage: ci
script: script:
- docker build --force-rm --build-arg MDANSE_GIT_COMMIT=${CI_COMMIT_SHA} -t ci_mdanse_bionic -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-bionic/Dockerfile_build . - docker build --force-rm=true -t ci_mdanse_bionic -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-bionic/Dockerfile_setup .
- docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_bionic_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-bionic/Dockerfile_build .
- docker run -iv${PWD}:/artifacts/ ci_mdanse_bionic_build
allow_failure: false allow_failure: false
artifacts:
paths:
- ${CI_PROJECT_DIR}/build
- ${CI_PROJECT_DIR}/temp
expire_in: 1 hrs
tags: tags:
- docker - docker
- sci - sci
...@@ -107,9 +140,9 @@ ci:ubuntu_bionic: ...@@ -107,9 +140,9 @@ ci:ubuntu_bionic:
deploy:ubuntu_bionic: deploy:ubuntu_bionic:
stage: deploy stage: deploy
script: script:
- docker build --force-rm -t deploy_mdanse_bionic -f ${CI_PROJECT_DIR}/BuildServer/Docker/Builder/Ubuntu-bionic/Dockerfile_deploy . - docker build --force-rm=true -t ci_mdanse_bionic -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-bionic/Dockerfile_setup .
- chmod 755 ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh - docker build --force-rm=true --build-arg CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA} --build-arg CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME} --no-cache -t ci_mdanse_bionic_build -f ${CI_PROJECT_DIR}/BuildServer/Docker/Ubuntu-bionic/Dockerfile_deploy .
- ${CI_PROJECT_DIR}/BuildServer/Docker/upload_artefacts.sh bionic - docker run -iv${PWD}:/artifacts/ ci_mdanse_bionic_build
dependencies: dependencies:
- ci:ubuntu_bionic - ci:ubuntu_bionic
allow_failure: false allow_failure: false
...@@ -221,14 +254,3 @@ deploy:windows: ...@@ -221,14 +254,3 @@ deploy:windows:
tags: tags:
- sci - sci
- windows-10 - windows-10
docker_logout:
stage: docker_logout
when: always
script:
- docker logout
tags:
- docker
- sci
- ubuntu
FROM docker.ill.fr/scientific-software/mdanse:ubuntu-bionic
SHELL ["/bin/bash", "-c"]
ARG MDANSE_GIT_COMMIT
RUN GIT_SSL_NO_VERIFY=true git clone https://code.ill.fr/scientific-software/mdanse.git
WORKDIR mdanse
RUN git checkout ${MDANSE_GIT_COMMIT}
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/build.sh
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/tests.sh
FROM ci_mdanse_bionic
SHELL ["/bin/bash", "-c"]
VOLUME builds
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; source ./BuildServer/Unix/bionic_dependencies_modification.sh ; ./BuildServer/Unix/Debian/deploy.sh
FROM docker.ill.fr/scientific-software/mdanse:ubuntu-trusty
SHELL ["/bin/bash", "-c"]
ARG MDANSE_GIT_COMMIT
RUN GIT_SSL_NO_VERIFY=true git clone https://code.ill.fr/scientific-software/mdanse.git
WORKDIR mdanse
RUN git checkout ${MDANSE_GIT_COMMIT}
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/build.sh
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/tests.sh
FROM ci_mdanse_trusty
SHELL ["/bin/bash", "-c"]
VOLUME builds
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/Debian/deploy.sh
FROM docker.ill.fr/scientific-software/mdanse:ubuntu-xenial
SHELL ["/bin/bash", "-c"]
ARG MDANSE_GIT_COMMIT
RUN GIT_SSL_NO_VERIFY=true git clone https://code.ill.fr/scientific-software/mdanse.git
WORKDIR mdanse
RUN git checkout ${MDANSE_GIT_COMMIT}
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/build.sh
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/tests.sh
FROM ci_mdanse_xenial
SHELL ["/bin/bash", "-c"]
VOLUME builds
RUN source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh ; ./BuildServer/Unix/Debian/deploy.sh
#!/bin/bash
docker build --force-rm -t docker.ill.fr/scientific-software/mdanse:$1 -f $2/Dockerfile .
FROM ci_mdanse_bionic
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; ./BuildServer/Unix/build.sh; ./BuildServer/Unix/tests.sh; cp -a ${CI_PROJECT_DIR}/build /artifacts/; cp -a ${CI_PROJECT_DIR}/temp /artifacts/
\ No newline at end of file
FROM ci_mdanse_bionic
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; source ./BuildServer/Unix/bionic_dependencies_modification.sh; ./BuildServer/Unix/Debian/deploy.sh; cp -a *.deb /artifacts/
\ No newline at end of file
FROM ubuntu:bionic FROM ubuntu:bionic
ENV https_proxy http://proxy.ill.fr:8888
ENV http_proxy http://proxy.ill.fr:8888
RUN export DEBIAN_FRONTEND=noninteractive RUN export DEBIAN_FRONTEND=noninteractive
RUN apt-get update RUN apt-get update
...@@ -25,6 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose ...@@ -25,6 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose
RUN apt-get install -y --no-install-recommends python-sphinx RUN apt-get install -y --no-install-recommends python-sphinx
RUN apt-get install -y --no-install-recommends pyro RUN apt-get install -y --no-install-recommends pyro
RUN apt-get install -y --no-install-recommends lsb-release RUN apt-get install -y --no-install-recommends lsb-release
\ No newline at end of file
FROM ci_mdanse_trusty
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; ./BuildServer/Unix/build.sh; ./BuildServer/Unix/tests.sh; cp -a ${CI_PROJECT_DIR}/build /artifacts/; cp -a ${CI_PROJECT_DIR}/temp /artifacts/
\ No newline at end of file
FROM ci_mdanse_trusty
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; ./BuildServer/Unix/Debian/deploy.sh; cp -a *.deb /artifacts/
\ No newline at end of file
FROM ubuntu:trusty FROM ubuntu:trusty
ENV https_proxy http://proxy.ill.fr:8888
ENV http_proxy http://proxy.ill.fr:8888
RUN export DEBIAN_FRONTEND=noninteractive
RUN apt-get update RUN apt-get update
RUN apt-get install -y tzdata RUN apt-get install -y tzdata
...@@ -23,5 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose ...@@ -23,5 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose
RUN apt-get install -y --no-install-recommends python-sphinx RUN apt-get install -y --no-install-recommends python-sphinx
RUN apt-get install -y --no-install-recommends pyro RUN apt-get install -y --no-install-recommends pyro
RUN apt-get install -y --no-install-recommends lsb-release RUN apt-get install -y --no-install-recommends lsb-release
\ No newline at end of file
FROM ci_mdanse_xenial
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; ./BuildServer/Unix/build.sh; ./BuildServer/Unix/tests.sh; cp -a ${CI_PROJECT_DIR}/build /artifacts/; cp -a ${CI_PROJECT_DIR}/temp /artifacts/
\ No newline at end of file
FROM ci_mdanse_xenial
SHELL ["/bin/bash", "-c"]
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_REF_NAME
ENV CI_COMMIT_SHORT_SHA=${CI_COMMIT_SHORT_SHA}
ENV CI_COMMIT_REF_NAME=${CI_COMMIT_REF_NAME}
COPY ./ /app/
WORKDIR /app
CMD source ./BuildServer/Unix/Debian/definitions.sh; source ./BuildServer/Unix/setup_ci.sh; ./BuildServer/Unix/Debian/deploy.sh; cp -a *.deb /artifacts/
\ No newline at end of file
FROM ubuntu:xenial FROM ubuntu:xenial
ENV https_proxy http://proxy.ill.fr:8888
ENV http_proxy http://proxy.ill.fr:8888
RUN export DEBIAN_FRONTEND=noninteractive
RUN apt-get update RUN apt-get update
RUN apt-get install -y tzdata RUN apt-get install -y tzdata
...@@ -23,5 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose ...@@ -23,5 +28,4 @@ RUN apt-get install -y --no-install-recommends python-nose
RUN apt-get install -y --no-install-recommends python-sphinx RUN apt-get install -y --no-install-recommends python-sphinx
RUN apt-get install -y --no-install-recommends pyro RUN apt-get install -y --no-install-recommends pyro
RUN apt-get install -y --no-install-recommends lsb-release RUN apt-get install -y --no-install-recommends lsb-release
\ No newline at end of file
# Return the docker containers that are exited # Return the docker containers that are exited
exited_containers=`docker ps -q -f "status=exited"` exited_containers=`docker ps -q -f "status=exited"`
# If some have been found, remove them # If some have been found, remove them
if [ -n "$exited_containers" ] if [ -n "$exited_containers" ]
then then
docker rm -f ${exited_containers} docker rm -f ${exited_containers}
fi fi
# Return the docker images corresponding to MDANSE
images=`docker images -a --format "{{.Repository}}:{{.Tag}}" | grep _mdanse_`
# If some have been found, remove them
if [ -n "$images" ]
then
docker rmi -f ${images}
fi
# Return the docker images that are in dangling state # Return the docker images that are in dangling state
images=`docker images -q -f "dangling=true"` images=`docker images -q -f "dangling=true"`
# If some dangling images have been found, remove them # If some dangling images have been found, remove them
if [ -n "$images" ] if [ -n "$images" ]
then then
docker rmi -f ${images} docker rmi -f ${images}
fi fi
SET app_name create-dmg
VERSION create-dmg.cur create-dmg heads/master
NEWDIR build.dir temp %-build -
NEWFILE create-dmg.zip featured %.zip %
COPYTO [build.dir]
INTO create-dmg [create-dmg.cur]/create-dmg
INTO sample [create-dmg.cur]/sample
INTO support [create-dmg.cur]/support
SUBSTVARS [build.dir<alter>]/create-dmg [[]]
ZIP [create-dmg.zip]
INTO [build-files-prefix] [build.dir]
PUT megabox-builds create-dmg.zip
PUT megabox-builds build.log
PUT s3-builds create-dmg.zip
PUT s3-builds build.log
# coding=utf-8
import os
import sys
if sys.platform.startswith('darwin'):
from setuptools import setup
version = os.environ['VERSION_NAME']
project_dir = os.environ['CI_PROJECT_DIR']
APP = [os.path.join(project_dir,'Scripts','mdanse_gui')]
PLIST = {
u'CFBundleName': u'MDANSE',
u'CFBundleShortVersionString': version,
u'CFBundleVersion': version,
u'CFBundleIdentifier': u'eu.ill.MDANSE-'+version,
u'LSApplicationCategoryType': u'public.app-category.science'
}
OPTIONS = {
'argv_emulation': False,# has to be False otherwise triggers problems with wxPython which lose some events that are captured by OS
'iconfile': os.path.join(project_dir,'Src','GUI','Icons','mdanse.icns'),
'excludes': 'PyQt4',
'matplotlib_backends': '-',
'optimize': '1',
'plist': PLIST,
'bdist_base': os.environ['CI_TEMP_BUILD_DIR'],
'dist_dir': os.path.join(os.environ['CI_TEMP_DIR'],'dist'),
'graph': False,
'xref': False,
'packages' : ["MDANSE","MMTK","Scientific","matplotlib"]
}
setup(
name='MDANSE',
app=APP,
options={'py2app': OPTIONS},
setup_requires=['py2app']
)
else:
print 'No build_app implementation for your system.'
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment