pre-commit run?
This commit is contained in:
parent
9d21669788
commit
2b30676431
1 changed files with 10 additions and 3 deletions
|
@ -6,9 +6,14 @@ stages:
|
||||||
- production
|
- production
|
||||||
|
|
||||||
default:
|
default:
|
||||||
image: python:3.12-slim
|
image: python:3.12-alpine
|
||||||
before_script:
|
|
||||||
- docker login ${CI_REGISTRY} -u gitlab-ci-token -p ${CI_JOB_TOKEN}
|
pre_commit:
|
||||||
|
stage: linting
|
||||||
|
script:
|
||||||
|
- apk add git
|
||||||
|
- pip install --root-user-action ignore pre-commit
|
||||||
|
- pre-commit run -a
|
||||||
|
|
||||||
build_image:
|
build_image:
|
||||||
stage: build
|
stage: build
|
||||||
|
@ -17,6 +22,8 @@ build_image:
|
||||||
- docker
|
- docker
|
||||||
variables:
|
variables:
|
||||||
CONTAINER_NAME: ${CI_REGISTRY_IMAGE}/facturio
|
CONTAINER_NAME: ${CI_REGISTRY_IMAGE}/facturio
|
||||||
|
before_script:
|
||||||
|
- docker login ${CI_REGISTRY} -u gitlab-ci-token -p ${CI_JOB_TOKEN}
|
||||||
script:
|
script:
|
||||||
- docker build -t ${CONTAINER_NAME}:${CI_COMMIT_REF_NAME} .
|
- docker build -t ${CONTAINER_NAME}:${CI_COMMIT_REF_NAME} .
|
||||||
- docker push ${CONTAINER_NAME}:${CI_COMMIT_REF_NAME}
|
- docker push ${CONTAINER_NAME}:${CI_COMMIT_REF_NAME}
|
||||||
|
|
Reference in a new issue