2023-07-13 23:52:26 +00:00
|
|
|
---
|
|
|
|
|
2023-07-14 00:07:31 +00:00
|
|
|
.build:
|
2023-07-13 23:52:26 +00:00
|
|
|
stage: build
|
2024-01-09 09:41:30 +00:00
|
|
|
image: golang:1-alpine
|
2023-07-14 00:07:31 +00:00
|
|
|
before_script:
|
|
|
|
- export GOPATH="$CI_PROJECT_DIR/.go"
|
|
|
|
- mkdir -p .go
|
2023-07-13 23:52:26 +00:00
|
|
|
variables:
|
|
|
|
CGO_ENABLED: 0
|
|
|
|
|
|
|
|
build-qa-ui:
|
|
|
|
stage: build
|
2024-01-09 09:41:30 +00:00
|
|
|
image: node:21-alpine
|
2023-07-14 00:07:31 +00:00
|
|
|
before_script:
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
|
|
|
- cd qa/ui
|
|
|
|
- npm install --network-timeout=100000
|
|
|
|
- npm run build
|
|
|
|
artifacts:
|
|
|
|
paths:
|
|
|
|
- qa/ui/build/
|
|
|
|
when: on_success
|
|
|
|
|
2023-07-14 00:07:31 +00:00
|
|
|
build-checker:
|
|
|
|
extends:
|
|
|
|
- .build
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
2023-07-14 11:08:58 +00:00
|
|
|
- go build -v -buildvcs=false -o deploy/checker srs.epita.fr/fic-server/checker
|
|
|
|
|
|
|
|
build-generator:
|
|
|
|
extends:
|
|
|
|
- .build
|
|
|
|
script:
|
|
|
|
- go build -v -buildvcs=false -o deploy/generator srs.epita.fr/fic-server/generator
|
2023-07-14 00:07:31 +00:00
|
|
|
|
|
|
|
build-receiver:
|
|
|
|
extends:
|
|
|
|
- .build
|
|
|
|
script:
|
2023-07-14 11:08:58 +00:00
|
|
|
- go build -v -buildvcs=false -o deploy/receiver srs.epita.fr/fic-server/receiver
|
2023-07-13 23:52:26 +00:00
|
|
|
|
|
|
|
build-admin:
|
2023-07-14 00:07:31 +00:00
|
|
|
extends:
|
|
|
|
- .build
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
|
|
|
- go build -v -buildvcs=false -tags gitgo -o deploy/admin-gitgo srs.epita.fr/fic-server/admin
|
|
|
|
- go build -v -buildvcs=false -o deploy/admin srs.epita.fr/fic-server/admin
|
|
|
|
|
|
|
|
build-evdist:
|
2023-07-14 00:07:31 +00:00
|
|
|
extends:
|
|
|
|
- .build
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
|
|
|
- go build -v -buildvcs=false -o deploy/evdist srs.epita.fr/fic-server/evdist
|
|
|
|
|
|
|
|
build-frontend-ui:
|
|
|
|
stage: build
|
2024-01-09 09:39:08 +00:00
|
|
|
image: node:21-alpine
|
2023-07-14 00:07:31 +00:00
|
|
|
before_script:
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
2023-07-14 00:07:31 +00:00
|
|
|
- cd frontend/fic
|
2023-07-13 23:52:26 +00:00
|
|
|
- npm install --network-timeout=100000
|
|
|
|
- npm run build
|
|
|
|
|
|
|
|
build-dashboard:
|
2023-07-14 00:07:31 +00:00
|
|
|
extends:
|
|
|
|
- .build
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
|
|
|
- go build -v -buildvcs=false -o deploy/dashboard srs.epita.fr/fic-server/dashboard
|
|
|
|
|
|
|
|
build-repochecker:
|
2023-07-14 00:07:31 +00:00
|
|
|
extends:
|
|
|
|
- .build
|
2024-03-22 18:26:34 +00:00
|
|
|
variables:
|
|
|
|
CGO_ENABLED: 1
|
2023-07-13 23:52:26 +00:00
|
|
|
script:
|
|
|
|
- apk --no-cache add build-base
|
|
|
|
- go build -buildvcs=false --tags checkupdate -v -o deploy/repochecker srs.epita.fr/fic-server/repochecker
|
|
|
|
- go build -buildvcs=false -buildmode=plugin -v -o deploy/repochecker-epita-rules.so srs.epita.fr/fic-server/repochecker/epita
|
|
|
|
- go build -buildvcs=false -buildmode=plugin -v -o deploy/repochecker-file-inspector-rules.so srs.epita.fr/fic-server/repochecker/file-inspector
|
|
|
|
- go build -buildvcs=false -buildmode=plugin -v -o deploy/repochecker-grammalecte-rules.so srs.epita.fr/fic-server/repochecker/grammalecte
|
|
|
|
- go build -buildvcs=false -buildmode=plugin -v -o deploy/repochecker-pcap-inspector-rules.so srs.epita.fr/fic-server/repochecker/pcap-inspector
|
|
|
|
- go build -buildvcs=false -buildmode=plugin -v -o deploy/repochecker-videos-rules.so srs.epita.fr/fic-server/repochecker/videos
|
|
|
|
- grep "const version" repochecker/update.go | sed -r 's/^.*=\s*(\S.*)$/\1/' > deploy/repochecker.version
|
|
|
|
|
|
|
|
build-qa:
|
2023-07-14 00:07:31 +00:00
|
|
|
extends:
|
|
|
|
- .build
|
2023-07-13 23:52:26 +00:00
|
|
|
needs: ["build-qa-ui"]
|
|
|
|
dependencies:
|
|
|
|
- build-qa-ui
|
|
|
|
script:
|
|
|
|
- go build -v -buildvcs=false -o deploy/qa srs.epita.fr/fic-server/qa
|