Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
stamp-devops-poc
stamp-devops-poc
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 0
    • Merge Requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • STAMP
  • stamp-devops-pocstamp-devops-poc
  • Wiki
  • Home

Last edited by Nicola Bertazzo Apr 26, 2017
Page history

Home

SUMMARY

  • Created the project stamp-devops-poc in OW2 gitLab repository (https://gitlab.ow2.org/stamp/stamp-devops-poc/tree/master) (Daniele Gagliardi Issue stamp/h2020#94)

  • Created a project to tests GitLab CI/CD (Nicola Bertazzo Issue stamp/h2020#95). Installed and configured a docker GitLab Runner (Martin Hamant Issue stamp/h2020#96)

  • Created the file .gitlab-ci.yml to configure the continuous integration delivery process (Nicola Bertazzo Issue stamp/h2020#95).

  • Tested the continuous integration process that contains these steps:

    • build: executes mvn clean compile command into a container based on maven:3.3.9-jdk-8 image
    • test: executes mvn test command into a container based on maven:3.3.9-jdk-8 image
    • package: executes mvn package into a container based on maven:3.3.9-jdk-8 image
    • int-test: executes mvn verify into a container based on maven:3.3.9-jdk-8 image
  • Tested the CI process localy using this command:

gitlab-runner exec docker package

  • Tested CI process remotely.

Troubles solved:

  • cache .m2/repository to avoid to download for every steps all the maven dependency (https://gitlab.com/gitlab-org/gitlab-ce/issues/15167). Added this parameter to MAVEN_OPTS variables

MAVEN_OPTS: -Dmaven.repo.local=/cache/maven.repository

Troubles not solved:

  • Run docker build in dind: Cannot connect to the Docker daemon problem (https://docs.gitlab.com/ce/ci/docker/using_docker_build.html)
  • Store variables from maven execution (p.es. version, etc)

Next steps:

  • build and deploy a docker image into a docker registry:
    • Define a step to build docker image (https://docs.gitlab.com/ce/ci/docker/using_docker_build.html)
    • Define a step to test docker image
    • Configure a GitLab Container Registry (https://about.gitlab.com/2016/05/23/gitlab-container-registry/) @mh
    • Define a step to deploy the image in the docker registry
    • Use the docker image sotred in the docker registry to create a container
Clone repository
  • Home