File tree Expand file tree Collapse file tree 2 files changed +91
-0
lines changed Expand file tree Collapse file tree 2 files changed +91
-0
lines changed Original file line number Diff line number Diff line change
1
+ include :
2
+ - ' https://raw.githubusercontent.com/JuliaGPU/gitlab-ci/master/templates/v3/common.yml'
3
+
4
+ .projecttest :
5
+ extends : .test
6
+ variables :
7
+ OMPI_ALLOW_RUN_AS_ROOT : ' 1'
8
+ OMPI_ALLOW_RUN_AS_ROOT_CONFIRM : ' 1'
9
+ OMPI_MCA_btl_vader_single_copy_mechanism : ' none' # https://github.com/open-mpi/ompi/issues/4948
10
+ before_script :
11
+ - apt-get update
12
+ - apt-get install --yes --no-install-recommends ssh
13
+ - curl https://download.open-mpi.org/release/open-mpi/v${OPENMPI_VER}/openmpi-${OPENMPI_VER_FULL}.tar.gz --output openmpi.tar.gz
14
+ - tar xf openmpi.tar.gz
15
+ - patch -p1 -d openmpi-${OPENMPI_VER_FULL} < conf/ompi_rootenv.patch
16
+ - pushd openmpi-${OPENMPI_VER_FULL}
17
+ - ./configure --with-cuda --prefix=${HOME}/mpi
18
+ - make -j
19
+ - make install
20
+ - popd
21
+ script :
22
+ - export JULIA_MPI_PATH="${HOME}/mpi"
23
+ - ${JULIA_MPI_PATH}/bin/ompi_info
24
+ - julia -e 'using InteractiveUtils;
25
+ versioninfo()'
26
+ - julia --project -e 'using Pkg;
27
+ Pkg.build();
28
+ Pkg.test(coverage=true)'
29
+ .gputest :
30
+ extends : .projecttest
31
+ variables :
32
+ CI_IMAGE_TAG : ' cuda'
33
+ OPENMPI_VER : ' 4.0'
34
+ OPENMPI_VER_FULL : ' 4.0.1'
35
+ tags :
36
+ - cuda
37
+
38
+ gpu:test:dev :
39
+ extends : .gputest
40
+ variables :
41
+ CI_VERSION_TAG : ' dev'
42
+ allow_failure : true
43
+
44
+ gpu:test:v1.3 :
45
+ extends : .gputest
46
+ variables :
47
+ CI_VERSION_TAG : ' v1.3'
48
+
49
+ gpu:test:v1.2 :
50
+ extends : .gputest
51
+ variables :
52
+ CI_VERSION_TAG : ' v1.2'
53
+
54
+ gpu:test:v1.1 :
55
+ extends : .gputest
56
+ variables :
57
+ CI_VERSION_TAG : ' v1.1'
58
+
59
+ gpu:test:v1.0 :
60
+ extends : .gputest
61
+ variables :
62
+ CI_VERSION_TAG : ' v1.0'
Original file line number Diff line number Diff line change
1
+ Allow override environment variables to work. This is required for running as root inside a docker container (e.g. Gitlab CI)
2
+
3
+ Upstream: https://github.com/open-mpi/ompi/pull/6895
4
+
5
+ --- a/orte/tools/orterun/orterun.c
6
+ +++ b/orte/tools/orterun/orterun.c
7
+ @@ -143,6 +143,14 @@ int orterun(int argc, char *argv[])
8
+ * exit with a giant warning flag
9
+ */
10
+ if (0 == geteuid() && !orte_cmd_options.run_as_root) {
11
+ + char *r1, *r2;
12
+ + if (NULL != (r1 = getenv("OMPI_ALLOW_RUN_AS_ROOT")) &&
13
+ + NULL != (r2 = getenv("OMPI_ALLOW_RUN_AS_ROOT_CONFIRM"))) {
14
+ + if (0 == strcmp(r1, "1") && 0 == strcmp(r2, "1")) {
15
+ + goto moveon;
16
+ + }
17
+ + }
18
+ +
19
+ fprintf(stderr, "--------------------------------------------------------------------------\n");
20
+ if (NULL != orte_cmd_options.help) {
21
+ fprintf(stderr, "%s cannot provide the help message when run as root.\n", orte_basename);
22
+ @@ -160,6 +168,7 @@ int orterun(int argc, char *argv[])
23
+ exit(1);
24
+ }
25
+
26
+ + moveon:
27
+ /* setup to listen for commands sent specifically to me, even though I would probably
28
+ * be the one sending them! Unfortunately, since I am a participating daemon,
29
+ * there are times I need to send a command to "all daemons", and that means *I* have
You can’t perform that action at this time.
0 commit comments