Adding maven.repo.local arg to onos-package
Change-Id: I812707c676c020f56452f45cc4136da0b5e543c9
Showing
1 changed file
with
6 additions
and
1 deletions
| ... | @@ -222,10 +222,15 @@ esac | ... | @@ -222,10 +222,15 @@ esac |
| 222 | shift | 222 | shift |
| 223 | done | 223 | done |
| 224 | 224 | ||
| 225 | +#TODO consider moving this block to build_stage_dir | ||
| 225 | # Run karaf assembly to collect artifacts for off-line installations. | 226 | # Run karaf assembly to collect artifacts for off-line installations. |
| 226 | aux=/tmp/assembly-$$.log | 227 | aux=/tmp/assembly-$$.log |
| 227 | trap "rm -f $aux 2>/dev/null" EXIT | 228 | trap "rm -f $aux 2>/dev/null" EXIT |
| 228 | -cd $ONOS_ROOT/tools/package/karaf-assembly && mvn clean install > $aux 2>&1 | 229 | +#TODO possibly merge with MAVEN_OPTS, also M2_REPO must be set for the reasons |
| 230 | +[ -n "$M2_REPO" ] && args="-Dmaven.repo.local=$M2_REPO" || args="" | ||
| 231 | +cd $ONOS_ROOT/tools/package/karaf-assembly && | ||
| 232 | + mvn $args clean install > $aux 2>&1 || | ||
| 233 | + ( echo "Failed to run karaf-assembly" && exit 1 ) | ||
| 229 | 234 | ||
| 230 | # Before starting make sure the environment is clan - delete onos staging folder | 235 | # Before starting make sure the environment is clan - delete onos staging folder |
| 231 | clean_stage_dir | 236 | clean_stage_dir | ... | ... |
-
Please register or login to post a comment