I have a jenkins server that have a maven job. today we are not deploying artifacts to our repository(Artifactory) since it takes a lot of time(30 minutes). than we are invoking an integration-tests on other jobs (different machines too, slaves) that test it on different databases (oracle, sqlserver) and different os (linux, windows).
What i want to do is to make a nightly deployment of all our maven modules.
My questions are:
1.What is the proper way to do it, should we put our logic on some maven profile or should i use jenkins to invoke this profile i.e
mvn -Pdeployprofile deploy
If we use jenkins should it be on same job or not?.
My thought is that on day jenkins would run : mvn install
on night: mvn deploy
How can i achieve that?
Thanks a lot David.
I would have a separate job, triggered on a schedule, using a separate maven profile. That makes it easier to trigger the job manually, for testing, or if you need to do a push of a hot-fix build, or if you get a faster build cluster,