Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
V
VIPSCommon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository 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
VIPS
VIPSCommon
Commits
3358277c
Commit
3358277c
authored
1 year ago
by
Lene Wasskog
Browse files
Options
Downloads
Patches
Plain Diff
build: Try to include gitlab ci/cd from vips-common-config, remove ci_settings.xml
parent
935d0fc2
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
.gitignore
+1
-0
1 addition, 0 deletions
.gitignore
.gitlab-ci.yml
+5
-88
5 additions, 88 deletions
.gitlab-ci.yml
ci_settings.xml
+0
-16
0 additions, 16 deletions
ci_settings.xml
pom.xml
+1
-11
1 addition, 11 deletions
pom.xml
with
7 additions
and
115 deletions
.gitignore
+
1
−
0
View file @
3358277c
...
@@ -4,3 +4,4 @@ jbossmodule/
...
@@ -4,3 +4,4 @@ jbossmodule/
/nbproject/
/nbproject/
*~
*~
.idea/
.idea/
/VIPSCommon.iml
This diff is collapsed.
Click to expand it.
.gitlab-ci.yml
+
5
−
88
View file @
3358277c
image
:
openjdk:11-jdk
include
:
-
project
:
'
VIPS/vips-common-config'
file
:
'
/gitlab-ci-vips-libraries.yml'
ref
:
main
stages
:
stages
:
-
build
-
test
-
deploy
-
models-1
-
models-1
-
models-2
-
models-2
-
models-3
-
models-3
...
@@ -13,10 +14,6 @@ stages:
...
@@ -13,10 +14,6 @@ stages:
-
models-8
-
models-8
variables
:
variables
:
MAVEN_CLI_OPTS
:
"
-s
ci_settings.xml
--batch-mode"
MAVEN_OPTS
:
"
-Dmaven.repo.local=.m2/repository
-Dmaven.artifact.threads=10"
MAIN_BRANCH
:
"
main"
RELEASE_BRANCH
:
"
release"
ALTERNARIA_PROJECT_ID
:
"
173"
ALTERNARIA_PROJECT_ID
:
"
173"
APPLESCABM_PROJECT_ID
:
"
20"
APPLESCABM_PROJECT_ID
:
"
20"
BARLEYNETB_PROJECT_ID
:
"
21"
BARLEYNETB_PROJECT_ID
:
"
21"
...
@@ -40,38 +37,6 @@ variables:
...
@@ -40,38 +37,6 @@ variables:
SEPAPIICOL_PROJECT_ID
:
"
39"
SEPAPIICOL_PROJECT_ID
:
"
39"
SEPTORIAHU_PROJECT_ID
:
"
65"
SEPTORIAHU_PROJECT_ID
:
"
65"
SEPTREFHUM_PROJECT_ID
:
"
135"
SEPTREFHUM_PROJECT_ID
:
"
135"
cache
:
paths
:
-
.m2/repository/
build
:
stage
:
build
script
:
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS package
tags
:
-
vips-java
test
:
stage
:
test
script
:
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS test
tags
:
-
vips-java
deploy-snapshot
:
stage
:
deploy
script
:
-
export VERSION=$(./mvnw --batch-mode --no-transfer-progress --non-recursive help:evaluate -Dexpression=project.version | grep -v "\[.*")
-
if ! [[ $VERSION =~ .*SNAPSHOT ]]; then exit 1; fi
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS deploy -DskipTests
-
echo "VERSION=$VERSION" >> build.env
artifacts
:
reports
:
dotenv
:
build.env
tags
:
-
vips-java
rules
:
-
if
:
'
$CI_COMMIT_REF_NAME
==
$MAIN_BRANCH'
# Runs after new SNAPSHOT is deployed to package registry. Triggers job on main branch in model repo,
# Runs after new SNAPSHOT is deployed to package registry. Triggers job on main branch in model repo,
# which builds model with the new version of VIPSCommon. This pipeline fails if model build fails.
# which builds model with the new version of VIPSCommon. This pipeline fails if model build fails.
...
@@ -375,54 +340,6 @@ verify_model_SEPTREFHUM:
...
@@ -375,54 +340,6 @@ verify_model_SEPTREFHUM:
rules
:
rules
:
-
if
:
'
$CI_COMMIT_REF_NAME
==
$MAIN_BRANCH'
-
if
:
'
$CI_COMMIT_REF_NAME
==
$MAIN_BRANCH'
deploy-release
:
stage
:
deploy
script
:
# For debugging git interaction
#- export GIT_TRACING=2
#- export GIT_CURL_VERBOSE=1
-
git config --global user.name "${GITLAB_USER_NAME}"
-
git config --global user.email "${GITLAB_USER_EMAIL}"
# Use access token given by CI/CD variable ACCESS_TOKEN to authenticate
-
export NEW_REPO_URL=https://root:$ACCESS_TOKEN@$CI_SERVER_HOST/$CI_PROJECT_PATH.git
-
git remote set-url --push origin $NEW_REPO_URL
-
git fetch origin --prune --prune-tags
# Checkout release branch, set release version and deploy. Commit, tag and push.
-
git checkout $RELEASE_BRANCH
-
git status
-
git reset --hard origin/$RELEASE_BRANCH
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS validate -DremoveSnapshot
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS deploy -DskipTests
-
export RELEASE_VERSION=$(./mvnw --batch-mode --no-transfer-progress --non-recursive help:evaluate -Dexpression=project.version | grep -v "\[.*")
-
if [[ $RELEASE_VERSION =~ .*SNAPSHOT ]]; then exit 1; fi
-
export RELEASE_TAG="v${RELEASE_VERSION}"
-
git add pom.xml
-
git commit -m "[ci skip] Set release version ${RELEASE_VERSION}"
-
git tag -a $RELEASE_TAG -m "Tag release ${RELEASE_TAG}"
-
git push origin $RELEASE_TAG
-
git push origin $RELEASE_BRANCH
# Checkout main branch, merge release branch. Push commit.
-
git fetch
-
git checkout $MAIN_BRANCH
-
git reset --hard origin/$MAIN_BRANCH
-
git merge -m "[ci skip] Merge ${RELEASE_BRANCH}" --no-ff $RELEASE_BRANCH
-
./mvnw $MAVEN_CLI_OPTS $MAVEN_OPTS validate -DbumpPatch
-
export SNAPSHOT_VERSION=$(./mvnw --batch-mode --no-transfer-progress --non-recursive help:evaluate -Dexpression=project.version | grep -v "\[.*")
-
git add pom.xml
-
git commit -m "[ci skip] Set snapshot version ${SNAPSHOT_VERSION}"
-
git push origin $MAIN_BRANCH
-
echo "VERSION=$RELEASE_VERSION" >> build.env
artifacts
:
reports
:
dotenv
:
build.env
tags
:
-
vips-java
rules
:
-
if
:
'
$CI_COMMIT_REF_NAME
==
$RELEASE_BRANCH'
# Runs after new release is deployed to package registry. Triggers job on main branch in model repo,
# Runs after new release is deployed to package registry. Triggers job on main branch in model repo,
# which builds model with the new version of VIPSCommon, and releases a new snapshot version of the model.
# which builds model with the new version of VIPSCommon, and releases a new snapshot version of the model.
...
...
This diff is collapsed.
Click to expand it.
ci_settings.xml
deleted
100644 → 0
+
0
−
16
View file @
935d0fc2
<settings
xmlns=
"http://maven.apache.org/SETTINGS/1.1.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd"
>
<servers>
<server>
<id>
gitlab-maven
</id>
<configuration>
<httpHeaders>
<property>
<name>
Job-Token
</name>
<value>
${CI_JOB_TOKEN}
</value>
</property>
</httpHeaders>
</configuration>
</server>
</servers>
</settings>
\ No newline at end of file
This diff is collapsed.
Click to expand it.
pom.xml
+
1
−
11
View file @
3358277c
...
@@ -5,10 +5,9 @@
...
@@ -5,10 +5,9 @@
<parent>
<parent>
<groupId>
no.nibio.vips
</groupId>
<groupId>
no.nibio.vips
</groupId>
<artifactId>
vips-parent-pom
</artifactId>
<artifactId>
vips-parent-pom
</artifactId>
<version>
1.0.
2
</version>
<version>
1.0.
7
</version>
</parent>
</parent>
<groupId>
no.nibio.vips
</groupId>
<artifactId>
VIPSCommon
</artifactId>
<artifactId>
VIPSCommon
</artifactId>
<version>
2.0.13-SNAPSHOT
</version>
<version>
2.0.13-SNAPSHOT
</version>
<packaging>
jar
</packaging>
<packaging>
jar
</packaging>
...
@@ -16,11 +15,6 @@
...
@@ -16,11 +15,6 @@
<name>
VIPSCommon
</name>
<name>
VIPSCommon
</name>
<url>
https://gitlab.nibio.no/VIPS/VIPSCommon
</url>
<url>
https://gitlab.nibio.no/VIPS/VIPSCommon
</url>
<properties>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<project.reporting.outputEncoding>
UTF-8
</project.reporting.outputEncoding>
</properties>
<dependencies>
<dependencies>
<dependency>
<dependency>
<groupId>
junit
</groupId>
<groupId>
junit
</groupId>
...
@@ -153,10 +147,6 @@
...
@@ -153,10 +147,6 @@
</dependency>
</dependency>
</dependencies>
</dependencies>
<repositories>
<repositories>
<repository>
<id>
gitlab-maven
</id>
<url>
https://gitlab.nibio.no/api/v4/projects/401/packages/maven
</url>
</repository>
<repository>
<repository>
<id>
bedatadriven
</id>
<id>
bedatadriven
</id>
<name>
bedatadriven public repo
</name>
<name>
bedatadriven public repo
</name>
...
...
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