diff --git a/.cz.yaml b/.cz.yaml new file mode 100644 index 0000000..62b2ada --- /dev/null +++ b/.cz.yaml @@ -0,0 +1,7 @@ +commitizen: + bump_message: "build(version): bump version $current_version \u2192 $new_version" + changelog_incremental: false + name: cz_conventional_commits + tag_format: $major.$minor.$patch$prerelease + update_changelog_on_bump: true + version: 0.0.1 diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index e93c44d..7b7d5d7 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,48 +1,17 @@ variables: - ImageRepo: $CI_REGISTRY/no-fuss-computing/infrastructure/glpi/9.2.1 - ImageTag: latest - GLPI_CLONE_FOLDER: glpi/glpi - GLPI_APP_NAME: glpi - GLPI_APP_CLONE_URL: https://github.com/glpi-project/glpi.git - GLPI_APP_GIT_TAG: 9.2.1 - -stages: - - prepare - - build - - staging - - deploy - - clean + MY_PROJECT_ID: "12928828" + GIT_SYNC_URL: "https://$GITHUB_USERNAME_ROBOT:$GITHUB_TOKEN_ROBOT@github.com/NoFussComputing/docker-glpi.git" + -prepare:Apps: - stage: prepare - before_script: - - rm -fR $GLPI_APP_NAME/$GLPI_APP_NAME - - git config --global http.sslVerify "false" - script: - - git clone --branch $GLPI_APP_GIT_TAG --depth 1 $GLPI_APP_CLONE_URL $GLPI_APP_NAME/$GLPI_APP_NAME - artifacts: - name: $APP_GIT_TAG - expire_in: 1h - paths: - - $GLPI_APP_NAME/Dockerfile - - $GLPI_APP_NAME/.dockerignore - - $GLPI_APP_NAME/$GLPI_APP_NAME/* + DOCKER_IMAGE_BUILD_TARGET_PLATFORMS: "linux/amd64,linux/arm64,linux/arm/v7" + DOCKER_IMAGE_PUBLISH_NAME: 'docker-glpi' + DOCKER_IMAGE_PUBLISH_REGISTRY: docker.io/nofusscomputing + DOCKER_IMAGE_PUBLISH_URL: https://hub.docker.com/r/nofusscomputing/$DOCKER_IMAGE_PUBLISH_NAME + PAGES_ENVIRONMENT_PATH: projects/docker_glpi/ - -build:App: - stage: build - image: gitlab/dind - services: - - docker:dind - variables: - GIT_STRATEGY: none - before_script: - - docker info - - docker login $CI_REGISTRY -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD - script: - - docker build $CI_PROJECT_DIR/$GLPI_APP_NAME/. --tag $ImageRepo:$GLPI_APP_GIT_TAG - - docker push $ImageRepo:$GLPI_APP_GIT_TAG - after_script: - - docker logout $CI_REGISTRY - tags: - - docker +include: + - project: nofusscomputing/projects/gitlab-ci + ref: development + file: + - template/automagic.gitlab-ci.yaml + #- template: Jobs/Container-Scanning.gitlab-ci.yml # see https://gitlab.com/gitlab-org/gitlab/-/issues/381665 diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..cc4d8a5 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,4 @@ +[submodule "gitlab-ci"] + path = gitlab-ci + url = https://gitlab.com/nofusscomputing/projects/gitlab-ci.git + branch = development diff --git a/.nfc_automation.yaml b/.nfc_automation.yaml new file mode 100644 index 0000000..077d7f4 --- /dev/null +++ b/.nfc_automation.yaml @@ -0,0 +1,8 @@ +--- + +role_git_conf: + gitlab: + submodule_branch: "development" + default_branch: development + mr_labels: ~"type::automation" ~"impact::0" ~"priority::0" + auto_merge: true diff --git a/gitlab-ci b/gitlab-ci new file mode 160000 index 0000000..975de7a --- /dev/null +++ b/gitlab-ci @@ -0,0 +1 @@ +Subproject commit 975de7aca210667d1e93d02a4036ca4ae70808ff