Skip to content

Commit

Permalink
update README.md to highlight build_versions.json and add .gitlab-ci.…
Browse files Browse the repository at this point in the history
…yaml example
  • Loading branch information
rwaffen committed Apr 11, 2024
1 parent 4e920c4 commit d610f86
Show file tree
Hide file tree
Showing 2 changed files with 106 additions and 0 deletions.
96 changes: 96 additions & 0 deletions .gitlab-ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
---
# Example of a CI/CD pipeline for a Puppet module
stages:
- QA🚦
- Test🚥

variables:
RAKE: rake -f /Rakefile

default:
image:
name: ghcr.io/voxpupuli/vobox:7.29.1-main
entrypoint: [""]

### QA🚦
.qa:
stage: QA🚦

qa-check:
extends: .qa
script:
- $RAKE check

qa-lint:
extends: .qa
script:
- $RAKE lint

qa-metadata_lint:
extends: .qa
script:
- $RAKE metadata_lint

qa-puppet-strings:
extends: .qa
script:
- $RAKE strings:validate:reference

qa-rubocop:
extends: .qa
script:
- $RAKE rubocop

qa-syntax:
extends: .qa
script:
- $RAKE syntax

qa-gateway:
stage: QA🚦
image: alpine:latest
script:
- echo "QA Gateway"
variables:
GIT_STRATEGY: none
needs:
- qa-check
- qa-lint
- qa-metadata_lint
- qa-puppet-strings
- qa-rubocop
- qa-syntax

### Test🚥
.test:
stage: Test🚥
needs:
- qa-gateway

test-unit:
extends: .test
script:
- $RAKE spec
artifacts:
expire_in: "30 days"
when: always
paths:
- "rspec.xml"
reports:
junit: "rspec.xml"

test-acceptance:
extends: .test
script:
- $RAKE beaker

test-gateway:
stage: Test🚥
image: alpine:latest
script:
- echo "Test Gateway"
variables:
GIT_STRATEGY: none
needs:
- test-unit
- test-acceptance
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@

This container should be used to test voxpupuli puppet modules. It has the voxpupuli-test, -acceptance, -release gems and all dependencies installed.

### Versions

Too see which gems and versions are included in the container, see:

[build_versions.json](build_versions.json)

## Example usage

```shell
Expand All @@ -17,6 +23,10 @@ docker run -it --rm -v $(pwd):/repo voxpupuli/voxbox spec # rake spec
docker run -it --rm -v $(pwd):/repo --entrypoint bash voxpupuli/voxbox # get shell
```

## Example Gitlab CI configuration

see [.gitlab-ci.yml](.gitlab-ci.yml)

## Version Schema

The version schema has the following layout:
Expand Down

0 comments on commit d610f86

Please sign in to comment.