113 lines
1.6 KiB
YAML
113 lines
1.6 KiB
YAML
stages:
|
|
- build
|
|
- lint
|
|
- test
|
|
- compose-build
|
|
- compose-push
|
|
|
|
.lint:
|
|
stage: lint
|
|
.build:
|
|
stage: build
|
|
.test:
|
|
stage: test
|
|
.compose-build:
|
|
stage: compose-build
|
|
.compose-push:
|
|
stage: compose-push
|
|
|
|
########
|
|
# BUILD
|
|
#################################################################
|
|
|
|
#build_fe:
|
|
# image: node:alpine
|
|
# script:
|
|
# - echo ''
|
|
# extends:
|
|
# - .build
|
|
|
|
build_be:
|
|
image: python:3.8-slim
|
|
before_script:
|
|
- apt-get update
|
|
- apt-get install -y build-essential gcc
|
|
- python -m venv /opt/venv
|
|
- python -m pip install --upgrade pip
|
|
script:
|
|
- cd ./backend
|
|
- python setup.py sdist
|
|
artifacts:
|
|
untracked: true
|
|
extends:
|
|
- .build
|
|
|
|
########
|
|
# LINT
|
|
#################################################################
|
|
|
|
lint_fe:
|
|
image: johnpapa/angular-cli
|
|
script:
|
|
- cd ./frontend
|
|
- npm install
|
|
- npm run -- ng lint
|
|
extends:
|
|
- .lint
|
|
# needs:
|
|
# - build_fe
|
|
|
|
#lint_be:
|
|
# script:
|
|
# - echo ''
|
|
# extends:
|
|
# - .lint
|
|
# needs:
|
|
# - build_be
|
|
|
|
########
|
|
# TEST
|
|
#################################################################
|
|
|
|
test_fe:
|
|
script:
|
|
- echo ''
|
|
extends:
|
|
- .test
|
|
needs:
|
|
- lint_fe
|
|
|
|
test_be:
|
|
script:
|
|
- cd ./backend
|
|
- ls -l
|
|
extends:
|
|
- .test
|
|
needs:
|
|
- build_be
|
|
|
|
########
|
|
# COMPOSE-BUILD
|
|
#################################################################
|
|
|
|
compose-build:
|
|
script:
|
|
- echo ''
|
|
extends:
|
|
- .compose-build
|
|
needs:
|
|
- test_be
|
|
- test_fe
|
|
|
|
########
|
|
# COMPOSE-PUSH
|
|
#################################################################
|
|
|
|
compose-push:
|
|
script:
|
|
- echo ''
|
|
extends:
|
|
- .compose-push
|
|
needs:
|
|
- compose-build
|