docs(Dind): Add template-printer for simpler printing of the templates and include
This commit is contained in:
parent
a34f3ba24d
commit
d0c6f86e33
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates
|
||||
|
||||
= Ansible Template
|
||||
|
||||
A Template Collection to simplify the deployment automation with Ansible.
|
||||
@ -29,8 +27,5 @@ Use the Gitlab CI variables so not everyone has access to this Secret. Only Main
|
||||
|EXTRA_ARGS | Additional Arguments that will be used from Ansible | ""
|
||||
|===
|
||||
|
||||
.Ansible Collection
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}/IaC/ansible.gitlab-ci.yml[]
|
||||
----
|
||||
:template: IaC/ansible.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates
|
||||
|
||||
= Docker-Compose Template
|
||||
|
||||
.Provided Templates:
|
||||
@ -100,8 +98,5 @@ For example multiple `--no-deps --no-build` definitions.
|
||||
| -
|
||||
|===
|
||||
|
||||
.Docker Templates
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}/IaC/docker-compose.gitlab-ci.yml[]
|
||||
----
|
||||
:template: IaC/docker-compose.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= ssh-transfer-data-template
|
||||
|
||||
This template provides a service to transfer data from a pipeline to a remote server.
|
||||
@ -13,8 +11,5 @@ For more details: https://gitlab.exxcellent.de/gilden/ci/exxcellent-ssh-tool#use
|
||||
|SSH_HOST | the name of the remote host |-
|
||||
|===
|
||||
|
||||
.ssh-transfer-data-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}IaC/ssh-transfer-data.gitlab-ci.yml[]
|
||||
----
|
||||
:template: IaC/ssh-transfer-data.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates
|
||||
|
||||
:gitlab-ci-file: /common/common-ci-variablen.gitlab-ci.yml
|
||||
|
||||
[[Generel-Variablen]]
|
||||
@ -22,6 +20,5 @@ Some of our Templates and Pipelines rely on the following variables.
|
||||
|BACKEND_DIR| Directory where the backend code can be found. This is useful when the repository contains frontend and backend Code.
|
||||
|===
|
||||
|
||||
----
|
||||
include::{sourcedir}{gitlab-ci-file}[]
|
||||
----
|
||||
:template: {gitlab-ci-file}
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates
|
||||
|
||||
= Build
|
||||
|
||||
.Provided Templates:
|
||||
@ -40,8 +38,5 @@ The template <<_container_publish>> allows you to publish the build image to a r
|
||||
| exxcellent Nexus
|
||||
|===
|
||||
|
||||
.Container Build Templates
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}/container/container-build.gitlab-ci.yml[]
|
||||
----
|
||||
:template: container/container-build.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,4 +1,3 @@
|
||||
:sourcedir: ../../../../templates
|
||||
[#_container_publish]
|
||||
= Container Publish
|
||||
|
||||
@ -15,8 +14,5 @@ Needs a build container on the path `image.tar`. Use one of the Container build
|
||||
| IMAGE_TAG | the Tag the image should be found on | Depends on the current path. Look at the rules of the Job.
|
||||
|===
|
||||
|
||||
.container-publish
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}/container/container-publish.gitlab-ci.yml[]
|
||||
----
|
||||
:template: container/container-publish.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= Container CVE Scanner
|
||||
|
||||
Uses Trivy to scan for CVE Problems within your Image.
|
||||
@ -28,8 +26,5 @@ Please consider using `allow_failure: true` instead of 0. The CI will show you a
|
||||
|
||||
|===
|
||||
|
||||
.container scan template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}container/container-scan.gitlab-ci.yml[]
|
||||
----
|
||||
:template: container/container-scan.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,12 +1,7 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= Docker in Docker
|
||||
|
||||
This template helps to start jobs, that need a docker environment to run.
|
||||
Simply expand from this Template.
|
||||
|
||||
.container scan template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}container/docker-in-docker.gitlab-ci.yml[]
|
||||
----
|
||||
:template: container/docker-in-docker.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= Dokumentation-Tool-template
|
||||
|
||||
The Dokumentation tool template.
|
||||
@ -33,8 +31,5 @@ The following variables have to be set and are not optional.
|
||||
| -
|
||||
|===
|
||||
|
||||
.dokumentation-tool
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}documentations/documentation.gitlab-ci.yml[]
|
||||
----
|
||||
:template: documentations/documentation.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
= Gradle-build-template
|
||||
|
||||
This template resolves the gradle dependencies of your project and builds the project.
|
||||
@ -13,8 +11,5 @@ The resulting build files will be published as artefacts.
|
||||
|GRADLE_CLI_BUILD_OPTS | Additional Options that will be passed to Gradle while Building | ""
|
||||
|===
|
||||
|
||||
.gradle-build-template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}java/gradle/gradle-build.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/gradle/gradle-build.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
= Gradle Database Diff
|
||||
|
||||
This template generates a diff between the Liquibase schema and the Hibernate model of a database.
|
||||
@ -19,8 +17,5 @@ Please look at the resulting changelog since it can have errors.
|
||||
| PATH_TO_DIFF | Path to the resulting diff is defined in gradle config, this will also be exposed as the artefact of the Job. | "build/db-diff.xml"
|
||||
|===
|
||||
|
||||
.Gradle Liquibase Diff
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}java/gradle/gradle-database-diff.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/gradle/gradle-database-diff.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
ifndef::imagesdir[]
|
||||
:imagesdir: ../../../../images/
|
||||
endif::[]
|
||||
@ -20,8 +18,5 @@ image::GitlabCiTest.png[]
|
||||
|GRADLE_CLI_OPTS | Zusätzliche CLI Opts für Gradle | ""
|
||||
|===
|
||||
|
||||
.gradle-test-template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}java/gradle/gradle-verify.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/gradle/gradle-verify.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
= maven-build-template
|
||||
|
||||
These Templates will build a .jar file with Maven and provides it as an Artifact
|
||||
@ -10,8 +8,5 @@ These Templates will build a .jar file with Maven and provides it as an Artifact
|
||||
|MAVEN_CLI_BUILD_OPTS | Additional Options that will be passed to Maven while Building | ""
|
||||
|===
|
||||
|
||||
.mvn-build-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}java/maven/maven-build.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/maven/maven-build.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
= Maven Database Diff
|
||||
|
||||
This template generates a diff between the Liquibase schema and the Hibernate model of a database.
|
||||
@ -13,8 +11,5 @@ Please look at the resulting changelog since it can have errors.
|
||||
| PATH_TO_DIFF | Path to the resulting diff is defined in gradle config, this will also be exposed as the artefact of the Job. | "target/db-diff.xml"
|
||||
|===
|
||||
|
||||
.gradle-build-template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}java/maven/maven-database-diff.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/maven/maven-database-diff.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
= Gradle Dependencies Template
|
||||
|
||||
This Template resolves the Maven Dependencies of your Projekt.
|
||||
@ -10,8 +8,5 @@ The result will be cached when you include the common CI variables.
|
||||
|Name |Description | Default Value
|
||||
|===
|
||||
|
||||
.mvn-dependencies-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}java/maven/maven-dependencies.gitlab-ci.yml[]
|
||||
----
|
||||
:template: java/maven/maven-dependencies.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../../templates/
|
||||
|
||||
ifndef::imagesdir[]
|
||||
:imagesdir: ../../../../images/
|
||||
endif::[]
|
||||
@ -20,8 +18,5 @@ image::GitlabCiTest.png[]
|
||||
|Name |Description | Default Value
|
||||
|===
|
||||
|
||||
.mvn-verify-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}/java/maven/maven-verify.gitlab-ci.yml[]
|
||||
----
|
||||
:template: /java/maven/maven-verify.gitlab-ci.yml
|
||||
include::../../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= NPM Build Template
|
||||
|
||||
This template will build a NPM project and saved the artifacts for the next build step.
|
||||
@ -12,8 +10,5 @@ This template will build a NPM project and saved the artifacts for the next buil
|
||||
| ""
|
||||
|===
|
||||
|
||||
.npm-build-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}npm/npm-build.gitlab-ci.yml[]
|
||||
----
|
||||
:template: npm/npm-build.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= NPM Dependencies template
|
||||
|
||||
This template loads the NPM dependencies of the project.
|
||||
@ -13,8 +11,5 @@ Please add the NPM cache. Look xref:Generel-Variablen[generell Variables]
|
||||
| ""
|
||||
|===
|
||||
|
||||
.npm-dependencies-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}npm/npm-dependencies.gitlab-ci.yml[]
|
||||
----
|
||||
:template: npm/npm-dependencies.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= NPM Lint template
|
||||
|
||||
This template starts the linter of your NPM project.
|
||||
@ -12,8 +10,5 @@ This template starts the linter of your NPM project.
|
||||
| ""
|
||||
|===
|
||||
|
||||
.npm-lint-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}npm/npm-lint.gitlab-ci.yml[]
|
||||
----
|
||||
:template: npm/npm-lint.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= NPM Test Template
|
||||
|
||||
This template will run your NPM unit tests
|
||||
@ -12,8 +10,5 @@ This template will run your NPM unit tests
|
||||
| ""
|
||||
|===
|
||||
|
||||
.npm-test-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}npm/npm-verify.gitlab-ci.yml[]
|
||||
----
|
||||
:template: npm/npm-verify.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= mail-template
|
||||
|
||||
This template provides a service to send mails from a pipeline with the help of a smtp server.
|
||||
@ -15,8 +13,5 @@ For more details: https://gitlab.exxcellent.de/gilden/ci/exxcellent-mail-tool[Gi
|
||||
|
||||
NOTE: The template uses the port 25 config as a default which doesn't need a smtp auth and a smtp user with the restriction that it only works from within the exxcellent gitlab-ci runners. For other configs visit the https://gitlab.exxcellent.de/gilden/ci/exxcellent-mail-tool[mail-tool docs]
|
||||
|
||||
.mail-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}releasing/mail.gitlab-ci.yml[]
|
||||
----
|
||||
:template: releasing/mail.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= Push Tag and Version Template
|
||||
|
||||
This template creates a new tag und updates the version of your project in the repository. Additionally, the template builds a new artifact with the `mvn package` command after setting the version which then can be exported with the gitlab-ci _artifacts_ keyword and used in subsequent stages.
|
||||
@ -13,8 +11,5 @@ For more details: https://gitlab.exxcellent.de/gilden/ci/exxcellent-ssh-tool[Gil
|
||||
|MVN_EXTRA_ARGS | sets extra args which will be added behind the `mvn` command | ""
|
||||
|===
|
||||
|
||||
.push-tag-and-version-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}releasing/push-tag-and-version.gitlab-ci.yml[]
|
||||
----
|
||||
:template: releasing/push-tag-and-version.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
[#_release_gitlab_template]
|
||||
= Gitlab Release Template
|
||||
|
||||
@ -11,8 +9,5 @@ This Template makes it easier to create Gitlab Release from the CI
|
||||
|DESCRIPTION | The Content that has changed in the last release. Can be changed manual afterwards | ""
|
||||
|===
|
||||
|
||||
.Template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}releasing/release-gitlab.gitlab-ci.yml[]
|
||||
----
|
||||
:template: releasing/release-gitlab.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
[#_release_template]
|
||||
= Release Template
|
||||
|
||||
@ -24,8 +22,5 @@ For more information see the <<_pipeline_release>> documentation.
|
||||
|PARENT_PIPELINE_ID | The if of the parent pipeline. Needed to be able to use artifacts in the child pipeline | $CI_PIPELINE_ID
|
||||
|===
|
||||
|
||||
.release-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}releasing/release.gitlab-ci.yml[]
|
||||
----
|
||||
:template: releasing/release.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,6 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
|
||||
= Set Version
|
||||
|
||||
This template provides the job for increasing the tag version.
|
||||
@ -22,8 +19,5 @@ a|
|
||||
** use more traditional version number. e.g: 1.2.3.6 | "false"
|
||||
|===
|
||||
|
||||
.set-version-template
|
||||
[source, yaml]
|
||||
----
|
||||
include::{sourcedir}/releasing/set-version.gitlab-ci.yml[]
|
||||
----
|
||||
:template: /releasing/set-version.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,5 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
|
||||
= Repo CVE Scan
|
||||
|
||||
This template uses Trivy to scan for CVEs, Configuration Problems and Secrets within your Repository.
|
||||
@ -27,8 +25,5 @@ Please consider using `allow_failure: true` instead of 0. The CI will show you a
|
||||
|
||||
|===
|
||||
|
||||
.Repo CVE scan template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}static-analysis/repo-cve-scan-trivy.gitlab-ci.yml[]
|
||||
----
|
||||
:template: static-analysis/repo-cve-scan-trivy.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,4 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
= Sonar 7
|
||||
|
||||
The following templates provide integrations for Sonar
|
||||
@ -20,8 +19,5 @@ Ein technischer User ist aktuell nicht möglich.
|
||||
Das Token wird ausschließlich dafür benötigt, wenn der Sonar Buildbreaker über die Pipeline aktiviert wird (_sonar.buildbreaker.skip=true_).
|
||||
Wenn der Build nicht gebrochen werden soll, kann es weggelassen werden.
|
||||
|
||||
.sonar-template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}static-analysis/sonar-7.gitlab-ci.yml[]
|
||||
----
|
||||
:template: static-analysis/sonar-7.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
@ -1,4 +1,3 @@
|
||||
:sourcedir: ../../../../templates/
|
||||
= Sonar 8
|
||||
|
||||
The following templates provide integrations for Sonar
|
||||
@ -18,8 +17,5 @@ Has to be `true` if the quality-gate should fail your pipelines. Please consider
|
||||
|
||||
|===
|
||||
|
||||
.sonar-template
|
||||
[source,yaml]
|
||||
----
|
||||
include::{sourcedir}static-analysis/sonar-8.gitlab-ci.yml[]
|
||||
----
|
||||
:template: static-analysis/sonar-8.gitlab-ci.yml
|
||||
include::../../../template-printer.adoc[]
|
||||
17
documentation/template-printer.adoc
Normal file
17
documentation/template-printer.adoc
Normal file
@ -0,0 +1,17 @@
|
||||
.Include
|
||||
[source,yaml,subs=attributes]
|
||||
----
|
||||
include:
|
||||
- project: 'gilden/ci/gitlab-ci-templates'
|
||||
ref: 'master'
|
||||
file:
|
||||
- '/templates/{template}'
|
||||
----
|
||||
|
||||
.Original Template
|
||||
[source,yaml]
|
||||
----
|
||||
include::../templates/{template}[]
|
||||
----
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user