Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
caosdb-mysqlbackend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
caosdb-mysqlbackend
Commits
be54ef41
Commit
be54ef41
authored
3 years ago
by
Daniel Hornung
Browse files
Options
Downloads
Patches
Plain Diff
STY DOC: Reordered .gitlab-ci.yml, added a bit of documentation.
parent
cc826d33
No related branches found
No related tags found
2 merge requests
!7
Release v5.0.0
,
!4
CI pipeline for mysql unit tests
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+35
-26
35 additions, 26 deletions
.gitlab-ci.yml
with
35 additions
and
26 deletions
.gitlab-ci.yml
+
35
−
26
View file @
be54ef41
...
@@ -32,31 +32,7 @@ stages:
...
@@ -32,31 +32,7 @@ stages:
-
test
-
test
-
deploy
-
deploy
# Trigger building of server image and integration tests
######## Setup ########
trigger_build
:
tags
:
[
docker
]
stage
:
deploy
script
:
-
/usr/bin/curl -X POST
-F token=$CI_JOB_TOKEN
-F "variables[F_BRANCH]=$CI_COMMIT_REF_NAME"
-F "variables[MYSQLBACKEND]=$CI_COMMIT_REF_NAME"
-F "variables[TriggerdBy]=MYSQLBACKEND"
-F "variables[TriggerdByHash]=$CI_COMMIT_SHORT_SHA"
-F ref=$DEPLOY_REF https://gitlab.indiscale.com/api/v4/projects/14/trigger/pipeline
unittests
:
tags
:
[
docker
]
stage
:
test
script
:
-
cp config.defaults .config
-
echo 'DATABASE_USER_HOST_LIST="%,"' >> .config
-
echo "MYSQL_USER_PASSWORD=$MYSQL_ROOT_PASSWORD" >> .config
-
echo "MYSQL_HOST=mariadb" >> .config
-
sleep
10
-
make install
-
./utils/make_db restore_db tests/example.dump.sql
-
./tests/test_utils.sh
# Build a docker image in which tests for this repository can run
# Build a docker image in which tests for this repository can run
build-testenv
:
build-testenv
:
...
@@ -75,6 +51,40 @@ build-testenv:
...
@@ -75,6 +51,40 @@ build-testenv:
-t $CI_REGISTRY_IMAGE .
-t $CI_REGISTRY_IMAGE .
-
docker push $CI_REGISTRY_IMAGE
-
docker push $CI_REGISTRY_IMAGE
######## Test ########
# Run the unit tests
unittests
:
tags
:
[
docker
]
stage
:
test
script
:
-
cp config.defaults .config
-
echo 'DATABASE_USER_HOST_LIST="%,"' >> .config
-
echo "MYSQL_USER_PASSWORD=$MYSQL_ROOT_PASSWORD" >> .config
-
echo "MYSQL_HOST=mariadb" >> .config
-
sleep
10
-
make install
-
./utils/make_db restore_db tests/example.dump.sql
-
./tests/test_utils.sh
######## Deploy ########
# Trigger building of server image and integration tests
trigger_build
:
tags
:
[
docker
]
stage
:
deploy
script
:
-
/usr/bin/curl -X POST
-F token=$CI_JOB_TOKEN
-F "variables[F_BRANCH]=$CI_COMMIT_REF_NAME"
-F "variables[MYSQLBACKEND]=$CI_COMMIT_REF_NAME"
-F "variables[TriggerdBy]=MYSQLBACKEND"
-F "variables[TriggerdByHash]=$CI_COMMIT_SHORT_SHA"
-F ref=$DEPLOY_REF https://gitlab.indiscale.com/api/v4/projects/14/trigger/pipeline
# Build the sphinx documentation and make it ready for deployment by Gitlab Pages
# Build the sphinx documentation and make it ready for deployment by Gitlab Pages
# Special job for serving a static website. See https://docs.gitlab.com/ee/ci/yaml/README.html#pages
# Special job for serving a static website. See https://docs.gitlab.com/ee/ci/yaml/README.html#pages
pages_prepare
:
&pages_prepare
pages_prepare
:
&pages_prepare
...
@@ -95,4 +105,3 @@ pages:
...
@@ -95,4 +105,3 @@ pages:
only
:
only
:
refs
:
refs
:
-
main
-
main
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment