configure-oglivelgromero-new-oglivemainmaint-cronmount-efivarfsmultivmmultivm-ogboot-installerogClonningEngineoglive-ipv6test-python-scriptsticket-301ticket-50ticket-50-oldticket-577ticket-585ticket-611ticket-612ticket-693ticket-700ubu24tplunification2use-local-agent-oglivevarios-instalacion
Last change
on this file since ee3f2e4 was
ef17dde,
checked in by Natalia Serrano <natalia.serrano@…>, 16 months ago
|
issueid #134 test whitespace
|
-
Property mode set to
100644
|
File size:
1.8 KB
|
Line | |
---|
1 | pipeline { |
---|
2 | agent { |
---|
3 | label "og1" |
---|
4 | } |
---|
5 | parameters { |
---|
6 | choice(name: 'ENVIRONMENT', choices: ['prepro', 'dev', 'prod'], description: 'Environment where to run the tests, by default prepro') |
---|
7 | } |
---|
8 | environment { |
---|
9 | def currentDayOfWeek = new Date().format('EEEE') |
---|
10 | //def branchName = env.BRANCH_NAME |
---|
11 | } |
---|
12 | |
---|
13 | stages { |
---|
14 | stage('Start') { |
---|
15 | steps { |
---|
16 | echo 'Jenkinsfile for opengnsys' |
---|
17 | } |
---|
18 | } |
---|
19 | stage('Borrar Snapshot') { |
---|
20 | steps { |
---|
21 | vSphere buildStep: [$class: 'DeleteSnapshot', consolidate: false, failOnNoExist: false, snapshotName: "og1-jenkins-test-${currentDayOfWeek}", vm: 'og1'], serverName: 'Esxi Jenkins UMA Cloud' |
---|
22 | } |
---|
23 | } |
---|
24 | |
---|
25 | stage('Crear Snapshot') { |
---|
26 | steps { |
---|
27 | vSphere buildStep: [$class: 'TakeSnapshot', description: 'og1-jenkins-test', includeMemory: false, snapshotName: "og1-jenkins-test-${currentDayOfWeek}", vm: 'og1'], serverName: 'Esxi Jenkins UMA Cloud' |
---|
28 | } |
---|
29 | } |
---|
30 | |
---|
31 | stage('Create temporaly directory') { |
---|
32 | when { |
---|
33 | expression { |
---|
34 | boolean fileNotPresent = !fileExists("/var/tmp/opengnsys") |
---|
35 | return fileNotPresent |
---|
36 | } |
---|
37 | } |
---|
38 | |
---|
39 | steps { |
---|
40 | sh "mkdir /var/tmp/opengnsys" |
---|
41 | } |
---|
42 | } |
---|
43 | |
---|
44 | stage('Copy to temporaly directory') { |
---|
45 | steps { |
---|
46 | sh "cp -r ./* /var/tmp/opengnsys" |
---|
47 | sh 'ls -la /var/tmp/' |
---|
48 | sh "ls -la /var/tmp/opengnsys" |
---|
49 | } |
---|
50 | } |
---|
51 | // stage('Execute opengnsys update') { |
---|
52 | // steps { |
---|
53 | // dir("/var/tmp/opengnsys/installer"){ |
---|
54 | // sh 'pwd' |
---|
55 | // sh 'sudo ./opengnsys_update.sh' |
---|
56 | // |
---|
57 | // } |
---|
58 | // } |
---|
59 | // } |
---|
60 | } |
---|
61 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.