This repository has been archived by the owner on Apr 21, 2021. It is now read-only.
forked from atarkowska/devspace
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.xml
188 lines (162 loc) · 6.59 KB
/
config.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
<?xml version='1.1' encoding='UTF-8'?>
<project>
<actions/>
<description>For more info, see the <a href="https://github.com/openmicroscopy/devspace#job-workflow"/>Job workflow</a>.</description>
<keepDependencies>false</keepDependencies>
<properties/>
<scm class="hudson.scm.NullSCM"/>
<assignedNode>testintegration</assignedNode>
<canRoam>false</canRoam>
<disabled>false</disabled>
<blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding>
<blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding>
<triggers/>
<concurrentBuild>false</concurrentBuild>
<builders>
<hudson.tasks.Shell>
<command>rm -rf $WORKSPACE/.venv3
python -m venv $WORKSPACE/.venv3
source $WORKSPACE/.venv3/bin/activate
pip install https://github.com/ome/zeroc-ice-py-centos7/releases/download/0.2.1/zeroc_ice-3.6.5-cp36-cp36m-linux_x86_64.whl
pip install -U pip future setuptools
pip install markdown
# Avoid installing psutil for now
# https://github.com/pytest-dev/pytest-xdist/issues/585
pip install mox3 pytest pytest-django 'pytest-xdist<2'
pip install tables
pip install jinja2
pip install PyYAML
pip install omero-py omero-web # Latest in order to stop server.</command>
</hudson.tasks.Shell>
<hudson.tasks.Shell>
<command>
OMERO_INSTALL=/tmp/omero-install/linux
source $OMERO_INSTALL/settings.env
OMERO_DB_NAME=$JOB_NAME
SRC=$WORKSPACE/src
OMERO_DIST=$SRC/dist
export OMERODIR=$OMERO_DIST
if [ -e $OMERO_DIST ]; then
source $WORKSPACE/.venv3/bin/activate
omero admin stop || echo not running
deactivate
sleep 5
fi
dropdb -h $OMERO_DB_HOST -U $OMERO_DB_USER $OMERO_DB_NAME || echo Already exists maybe
rm -rf $WORKSPACE/*
</command>
</hudson.tasks.Shell>
<hudson.plugins.copyartifact.CopyArtifact plugin="copyartifact@1.42">
<project>OMERO-build</project>
<filter>src/target/openmicroscopy*zip</filter>
<target></target>
<excludes></excludes>
<selector class="hudson.plugins.copyartifact.StatusBuildSelector"/>
<flatten>true</flatten>
<doNotFingerprintArtifacts>false</doNotFingerprintArtifacts>
</hudson.plugins.copyartifact.CopyArtifact>
<hudson.plugins.copyartifact.CopyArtifact plugin="copyartifact@1.42">
<project>OMERO-python-superbuild-build</project>
<filter>**/*.tar.gz</filter>
<target></target>
<excludes></excludes>
<selector class="hudson.plugins.copyartifact.StatusBuildSelector"/>
<flatten>true</flatten>
<doNotFingerprintArtifacts>false</doNotFingerprintArtifacts>
</hudson.plugins.copyartifact.CopyArtifact>
<hudson.tasks.Shell>
<command>
OMERO_INSTALL=/tmp/omero-install/linux
source $OMERO_INSTALL/settings.env
OMERO_DB_NAME=$JOB_NAME
OMERO_DATA_DIR=$WORKSPACE/data
mkdir -p $OMERO_DATA_DIR
# BUILD FROM SOURCE
SRC=$WORKSPACE/src
ZIP_SRC=$(ls openmicroscopy*zip)
unzip $ZIP_SRC
rm -f $ZIP_SRC
mv $WORKSPACE/${ZIP_SRC%.zip} $SRC
# prepare virtualenv
source $WORKSPACE/.venv3/bin/activate
## Install python dependencies
for x in *.tar.gz; do
pip install -U $x
done
## BUILD
source $SRC/docs/hudson/functions.sh
$SRC/build.py build-default test-compile
## LOAD CONFIG
OMERO_DIST=$SRC/dist
export OMERODIR=$OMERO_DIST
# TODO: LOAD EXTRA CONFIG
#omero load configfile.omero
# DEFAULT CONFIG
omero config set omero.db.name $OMERO_DB_NAME
omero config set omero.db.host $OMERO_DB_HOST
omero config set omero.db.user $OMERO_DB_USER
omero config set omero.db.poolsize 50
omero config set omero.jvmcfg.max_system_memory.blitz 64000
omero config set omero.data.dir $OMERO_DATA_DIR
omero config set omero.ports.prefix 1
omero config set omero.web.server_list '[["testintegration",14064,"testintegration"]]'
## END LOAD CONFIG
## PURGE
# CREATE DB
createdb -h $OMERO_DB_HOST -U $OMERO_DB_USER $OMERO_DB_NAME
omero db script -f dbsetup.sql "" "" $OMERO_ROOT_PASS
psql -h $OMERO_DB_HOST -U $OMERO_DB_USER -d $OMERO_DB_NAME -f dbsetup.sql
rm dbsetup.sql
## END PURGE
# Set up fake mail configuration
export OMERO_PROFILE=$WORKSPACE/config
mkdir -p $OMERO_PROFILE/blitz
cp $OMERO_DIST/etc/blitz/* $OMERO_PROFILE/blitz
for f in $OMERO_PROFILE/blitz/*; do mv $f $OMERO_PROFILE/blitz/`basename $f .example`.xml; done
omero config set omero.mail.config true
omero config set omero.mail.fake true
omero config set omero.mail.port 2525
# START OMERO
BUILD_ID=DONT_KILL_ME omero admin start
omero admin waitup
omero admin diagnostics
# RUN TESTS
export OMERO_SESSION_DIR=/tmp/$JOB_NAME/$BUILD_NUMBER
export ICE_CONFIG=$SRC/dist/etc/ice.config
#export PYTEST_ADDOPTS="-n16"
echo Running the integration tests with -Dtestng.useDefaultListeners=true
$SRC/build.py -f components/tools/OmeroJava/build.xml -Dtestng.useDefaultListeners=true -Dtestreports.dir=target/reports/integration integration
$SRC/build.py -f components/tools/OmeroPy/build.xml integration -Dtestreports.dir=target/reports/integration
$SRC/build.py -f components/tools/OmeroFS/build.xml integration -Dtestreports.dir=target/reports/integration
$SRC/build.py -f components/tools/OmeroWeb/build.xml integration -Dtestreports.dir=target/reports/integration
## Broken
$SRC/build.py -f components/tools/OmeroPy/build.xml integration -DMARK=broken -Dtestreports.dir=target/reports/broken
$SRC/build.py -f components/tools/OmeroJava/build.xml -Dtestng.useDefaultListeners=true -Dtestreports.dir=target/reports/broken broken
deactivate
</command>
</hudson.tasks.Shell>
</builders>
<publishers>
<hudson.tasks.junit.JUnitResultArchiver plugin="junit@1.27">
<testResults>**/OmeroPy/target/reports/integration/*.xml,**/OmeroFS/target/reports/integration/*.xml,**/OmeroWeb/target/reports/integration/*.xml</testResults>
<keepLongStdio>false</keepLongStdio>
<healthScaleFactor>1.0</healthScaleFactor>
<allowEmptyResults>false</allowEmptyResults>
</hudson.tasks.junit.JUnitResultArchiver>
<hudson.plugins.testng.Publisher plugin="testng-plugin@1.15">
<reportFilenamePattern>**/OmeroJava/target/reports/integration/*.xml</reportFilenamePattern>
<escapeTestDescp>true</escapeTestDescp>
<escapeExceptionMsg>true</escapeExceptionMsg>
<failureOnFailedTestConfig>false</failureOnFailedTestConfig>
<showFailedBuilds>false</showFailedBuilds>
<unstableSkips>100</unstableSkips>
<unstableFails>0</unstableFails>
<failedSkips>100</failedSkips>
<failedFails>100</failedFails>
<thresholdMode>2</thresholdMode>
</hudson.plugins.testng.Publisher>
</publishers>
<buildWrappers>
<hudson.plugins.timestamper.TimestamperBuildWrapper plugin="timestamper@1.9"/>
</buildWrappers>
</project>