Skip to content

openhive-network/common-ci-configuration

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

544 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Common CI Configuration

This project contains the common CI templates and scripts for Hive and Hive-related projects.

Directory structure

  • misc - miscellaneous files
  • scripts/bash - Bash scripts
  • scripts/bash/emscripten - source for emsdk image
  • scripts/python - Python scripts
  • templates - GitLab CI templates

Job templates

Pipeline Skip Variables

The following variables can be set to "true" when running a pipeline to skip certain jobs:

Variable Effect
QUICK_TEST Skip all production deployments and dev package deployments
SKIP_PRODUCTION_DEPLOY Skip all production deployments (npm to npmjs.org, Docker to Docker Hub)
SKIP_DEV_DEPLOY Skip dev package deployments (npm to internal GitLab registry)
SKIP_NPM_PUBLISH Skip all npm publishing jobs (both dev and production)
SKIP_DOCKER_PUBLISH Skip Docker Hub publishing jobs

These variables are checked in the template rules, so projects that extend templates without overriding rules automatically get this behavior.

Example jobs

The GitLab CI configuration for this repository contains example jobs based on the templates defined in it. On top of that the Docker images are built by jobs also based on said templates.

The password required by the example_image_cleanup_job is either personal, group or project access token with permission to use GitLab API.

Example JMeter benchmark job shows how to expose the JMeter result dashboard via GitLab pages. For the example job they are available at https://hive.pages.syncad.com/-/common-ci-configuration/-/jobs/<job-id>/artifacts/web_jmeter_report/index.html.

Miscellaneous files

Currently available miscellaneous files are checkstyle2junit.xslt, docker-compose.dind.yml and example-jmeter-test.jmx.

checkstyle2junit.xslt is an XSL transformation file, which can be used to transform checkstyle-style test reports into junit-style ones. You can see how to use it in job lint_bash_scripts.

docker-compose.dind.yml is a Compose file for setting up a simple Docker-in-Docker container. To connect to that container with a Docker CLI one use command like:

docker run -it --rm --network docker -e DOCKER_TLS_CERTDIR=/certs -v docker-certs-client:/certs/client:ro --name docker-cli docker:20.10.21

The iportant bit is connecting to the right network (--network docker) and mounting the TLS certificates (-e DOCKER_TLS_CERTDIR=/certs -v docker-certs-client:/certs/client:ro). Other parameters can be changed to suit your purposes.

example-jmeter-test.jmx is an example Jmeter test file used in the exmaple Jmeter job. It shows some basic test configuration as well as how to configure creation of the XML result file for m2u.

About

common CI templates and scripts for Hive and Hive-related projects

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors