Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#!/usr/bin/env groovy
/* groovylint-disable DuplicateListLiteral, DuplicateMapLiteral, DuplicateNumberLiteral */
// groovylint-disable DuplicateStringLiteral, NestedBlockDepth, VariableName
/* Copyright (C) 2019-2023 Intel Corporation
/* Copyright 2019-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
* All rights reserved.
*
* This file is part of the DAOS Project. It is subject to the license terms
Expand Down Expand Up @@ -229,6 +230,7 @@ pipeline {
dockerfile {
filename 'docker/Dockerfile.el.8'
label 'docker_runner'
additionalBuildArgs dockerBuildArgs()
}
}
steps {
Expand Down Expand Up @@ -268,7 +270,7 @@ pipeline {
dockerfile {
filename 'docker/Dockerfile.el.8'
label 'docker_runner'
additionalBuildArgs dockerBuildArgs(cachebust: false, add_repos: false)
additionalBuildArgs dockerBuildArgs(cachebust: false)
}
}
steps {
Expand Down
14 changes: 14 additions & 0 deletions vars/buildRpm.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* groovylint-disable DuplicateStringLiteral, VariableName */
// vars/buildRpm.groovy
/*
* Copyright 2020-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
*/

/**
* buildRpm step method
Expand Down Expand Up @@ -60,6 +64,16 @@ Map call(Map config = [:]) {
env_vars = ' CHROOT_NAME=' + config['chroot_name']
}

String https_proxy = ''
if (env.DAOS_HTTPS_PROXY) {
https_proxy = "${env.DAOS_HTTPS_PROXY}"
} else if (env.HTTPS_PROXY) {
https_proxy = "${env.HTTPS_PROXY}"
}
if (https_proxy) {
env_vars += ' HTTPS_PROXY=' + https_proxy
}

String error_stage_result = 'FAILURE'
String error_build_result = 'FAILURE'
if (config['unstable']) {
Expand Down
17 changes: 15 additions & 2 deletions vars/dockerBuildArgs.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* groovylint-disable DuplicateStringLiteral, VariableName */
// vars/dockerBuildArgs.groovy
/*
* Copyright 2020-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
*/

Integer num_proc() {
return sh(label: 'Get number of processors online',
Expand Down Expand Up @@ -31,7 +35,6 @@ Integer num_proc() {

String call(Map config = [:]) {
Boolean cachebust = config.get('cachebust', true)
Boolean add_repos = config.get('add_repos', true)
Boolean deps_build = config.get('deps_build', false)
Boolean parallel_build = config.get('parallel_build', false)

Expand All @@ -55,12 +58,22 @@ String call(Map config = [:]) {
}

// pass through env. var.s
['DAOS_LAB_CA_FILE_URL', 'REPO_FILE_URL', 'HTTP_PROXY', 'HTTPS_PROXY'].each { var ->
['DAOS_LAB_CA_FILE_URL', 'REPO_FILE_URL', 'HTTP_PROXY'].each { var ->
if (env."$var") {
ret_str += ' --build-arg ' + var + '="' + env."$var" + '"'
}
}

String https_proxy = ''
if (env.DAOS_HTTPS_PROXY) {
https_proxy = env.DAOS_HTTPS_PROXY
} else if (env.HTTPS_PROXY) {
https_proxy = env.HTTPS_PROXY
}
if (https_proxy) {
ret_str += ' --build-arg HTTPS_PROXY' + '="' + https_proxy + '"'
}

if (config['qb']) {
ret_str += ' --build-arg QUICKBUILD=true --build-arg DAOS_DEPS_BUILD=no'
} else {
Expand Down
19 changes: 17 additions & 2 deletions vars/functionalTest.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* groovylint-disable VariableName */
// vars/functionalTest.groovy
/*
* Copyright 2020-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
*/

/**
* functionalTest step method
Expand Down Expand Up @@ -110,8 +114,17 @@ Map call(Map config = [:]) {
run_test_config['context'] = context
run_test_config['description'] = description

sh label: 'Install Launchable',
script: '''if ! pip3 install --upgrade --upgrade-strategy only-if-needed launchable; then
String https_proxy = ''
if (env.DAOS_HTTPS_PROXY) {
https_proxy = "${env.DAOS_HTTPS_PROXY}"
} else if (env.HTTPS_PROXY) {
https_proxy = "${env.HTTPS_PROXY}"
}
String script = 'if ! pip3 install'
if (https_proxy) {
script += ' --proxy "' + https_proxy + '"'
}
script += ''' --upgrade --upgrade-strategy only-if-needed launchable; then
set +e
echo "Failed to install launchable"
id
Expand All @@ -125,6 +138,8 @@ Map call(Map config = [:]) {
fi
pip3 list --user || true
'''
sh label: 'Install Launchable',
script: script

try {
withCredentials([string(credentialsId: 'launchable-test', variable: 'LAUNCHABLE_TOKEN')]) {
Expand Down
15 changes: 14 additions & 1 deletion vars/functionalTestPostV2.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,21 @@ void call(Map config = [:]) {
script: 'ci/functional/launchable_analysis "' + fileName + '"')
}

String https_proxy = ''
if (env.DAOS_HTTPS_PROXY) {
https_proxy = "${env.DAOS_HTTPS_PROXY}"
} else if (env.HTTPS_PROXY) {
https_proxy = "${env.HTTPS_PROXY}"
}
String script = 'pip3 install'
if (https_proxy) {
script += ' --proxy "' + https_proxy + '"'
}
script += ' --user --upgrade launchable~=1.0'


sh(label: 'Install Launchable',
script: 'pip3 install --user --upgrade launchable~=1.0')
script: script)

try {
withCredentials([string(credentialsId: 'launchable-test', variable: 'LAUNCHABLE_TOKEN')]) {
Expand Down
2 changes: 1 addition & 1 deletion vars/packageBuildingPipeline.groovy
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/groovy
/* groovylint-disable DuplicateMapLiteral, DuplicateStringLiteral, NestedBlockDepth */
/* Copyright (C) 2019-2023 Intel Corporation
/* Copyright 2019-2023 Intel Corporation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion vars/packageBuildingPipelineDAOS.groovy
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/groovy
/* groovylint-disable DuplicateMapLiteral, DuplicateStringLiteral, NestedBlockDepth, VariableName */
/* Copyright (C) 2019-2023 Intel Corporation
/* Copyright 2019-2023 Intel Corporation
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
Expand Down
4 changes: 2 additions & 2 deletions vars/packageBuildingPipelineDAOSTest.groovy
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/groovy
/* groovylint-disable DuplicateMapLiteral, DuplicateStringLiteral, NestedBlockDepth, VariableName */
/* Copyright (C) 2019-2024 Intel Corporation
* Copyright (C) 2025 Hewlett Packard Enterprise Development LP
/* Copyright 2019-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
Expand Down
11 changes: 11 additions & 0 deletions vars/provisionNodes.groovy
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/* groovylint-disable DuplicateNumberLiteral, DuplicateStringLiteral, VariableName */
// vars/provisionNodes.groovy
/*
* Copyright 2020-2024 Intel Corporation
* Copyright 2025 Hewlett Packard Enterprise Development LP
*/

/**
* provisionNodes.groovy
Expand Down Expand Up @@ -155,6 +159,12 @@ Map call(Map config = [:]) {
default:
error "Unsupported distro type: ${distro_type}/distro: ${distro}"
}
String https_proxy = ''
if (env.DAOS_HTTPS_PROXY) {
https_proxy = "${env.DAOS_HTTPS_PROXY}"
} else if (env.HTTPS_PROXY) {
https_proxy = "${env.HTTPS_PROXY}"
}
provision_script += ' ' +
'NODESTRING=' + nodeString + ' ' +
'CONFIG_POWER_ONLY=' + config_power_only + ' ' +
Expand All @@ -164,6 +174,7 @@ Map call(Map config = [:]) {
// https://issues.jenkins.io/browse/JENKINS-55819
'CI_RPM_TEST_VERSION="' + (params.CI_RPM_TEST_VERSION ?: '') + '" ' +
'CI_PR_REPOS="' + (params.CI_PR_REPOS ?: '') + '" ' +
'HTTPS_PROXY="' + https_proxy + '" ' +
'ci/provisioning/post_provision_config.sh'
new_config['post_restore'] = provision_script
try {
Expand Down