Variables pour le contexte de production
This commit is contained in:
parent
5dee07ce46
commit
71a94bb201
|
@ -20,17 +20,17 @@ def call() {
|
|||
string(
|
||||
name: 'targetUrl',
|
||||
description: 'URL cible pour le dépôt de fichier',
|
||||
defaultValue: 'http://nextcloud.cadoles.com'
|
||||
defaultValue: 'https://nextcloud.cadoles.com'
|
||||
)
|
||||
string(
|
||||
name: 'targetFolder',
|
||||
description: 'Répertoire racine cible partagé avec l’utilisateur',
|
||||
defaultValue: 'documents_formations'
|
||||
defaultValue: 'Cadoles Formations'
|
||||
)
|
||||
string(
|
||||
name: 'credentialsId',
|
||||
description: "Identifiant du compte de type login/mot de passe",
|
||||
defaultValue: 'jenkins-on-nextcloud'
|
||||
defaultValue: 'nextcloud-user-for-formation-documents'
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -104,7 +104,7 @@ def call() {
|
|||
def rootFolder = "${params.targetUrl}/remote.php/dav/files/${NEXTCLOUD_USER}/${targetFolder}"
|
||||
def projectName = env.project_name
|
||||
def destFolder = "${projectName}/${docProfile}"
|
||||
def result = tamarin.compileDoc()
|
||||
def result = tamarin.compileDoc(env.buildProfile)
|
||||
println(result)
|
||||
if(docProfile != 'draft') {
|
||||
def publicFolder = "${destFolder}/latest/public"
|
||||
|
|
|
@ -91,7 +91,7 @@ def buildPackage(
|
|||
}
|
||||
|
||||
def compileDoc(
|
||||
String packageProfile = "doc-compiler",
|
||||
String buildProfile,
|
||||
String destDir = "./packages",
|
||||
Boolean forceRebuild = false
|
||||
) {
|
||||
|
@ -107,8 +107,7 @@ def compileDoc(
|
|||
def dockerArgs = """
|
||||
-u 0
|
||||
-v /var/run/docker.sock:/var/run/docker.sock
|
||||
${forceRebuild ? '-e TAMARIN_FORCE_REBUILD=1' : ''}
|
||||
${packageProfile ? '-e TAMARIN_PROFILE='+packageProfile : ''}
|
||||
-e TAMARIN_PROFILE=${buildProfile}
|
||||
-e TAMARIN_DEST_DIR=${destDir}
|
||||
""".stripIndent()
|
||||
|
||||
|
|
Loading…
Reference in New Issue