Skip to content

Commit 6d7c753

Browse files
authored
[ci] skip self-hosted Linux CI jobs (#6919)
* [ci] skip self-hosted Linux CI jobs * comment out Linux_latest too
1 parent f91dcfe commit 6d7c753

File tree

1 file changed

+178
-176
lines changed

1 file changed

+178
-176
lines changed

.vsts-ci.yml

Lines changed: 178 additions & 176 deletions
Original file line numberDiff line numberDiff line change
@@ -49,180 +49,181 @@ resources:
4949
tools: true
5050
tasks: true
5151
jobs:
52-
###############
53-
# Maintenance #
54-
###############
55-
- job: Maintenance
56-
pool: mariner-20240410-0
57-
container: ubuntu-latest
58-
# routine maintenance (like periodically deleting old files),
59-
# to be run on 1 random CI runner in the self-hosted pool each runner
60-
steps:
61-
- script: |
62-
print-diagnostics(){
63-
echo "---- df -h -m ----"
64-
df -h -m
65-
echo "---- docker system df ----"
66-
/tmp/docker system df
67-
echo "---- docker images ----"
68-
/tmp/docker images
69-
}
70-
# check disk usage
71-
print-diagnostics
72-
# remove old containers, container images, volumes
73-
# ref: https://stackoverflow.com/a/32723127/3986677
74-
# ref: https://depot.dev/blog/docker-clear-cache#removing-everything-with-docker-system-prune
75-
echo "---- running 'docker system prune' ----"
76-
/tmp/docker system prune \
77-
--all \
78-
--force \
79-
--volumes \
80-
--filter until=720h
81-
# check disk usage again
82-
print-diagnostics
83-
displayName: Clean
84-
#########
85-
# Linux #
86-
#########
87-
- job: Linux
88-
variables:
89-
COMPILER: gcc
90-
SETUP_CONDA: 'false'
91-
OS_NAME: 'linux'
92-
PRODUCES_ARTIFACTS: 'true'
93-
pool: mariner-20240410-0
94-
container: linux-artifact-builder
95-
strategy:
96-
matrix:
97-
regular:
98-
TASK: regular
99-
PYTHON_VERSION: '3.11'
100-
sdist:
101-
TASK: sdist
102-
PYTHON_VERSION: '3.9'
103-
bdist:
104-
TASK: bdist
105-
PYTHON_VERSION: '3.10'
106-
inference:
107-
TASK: if-else
108-
mpi_source:
109-
TASK: mpi
110-
METHOD: source
111-
PYTHON_VERSION: '3.10'
112-
gpu_source:
113-
TASK: gpu
114-
METHOD: source
115-
swig:
116-
TASK: swig
117-
steps:
118-
- script: |
119-
echo "##vso[task.setvariable variable=BUILD_DIRECTORY]$BUILD_SOURCESDIRECTORY"
120-
echo "##vso[task.prependpath]/usr/lib64/openmpi/bin"
121-
echo "##vso[task.prependpath]$CONDA/bin"
122-
displayName: 'Set variables'
123-
- script: |
124-
git clean -d -f -x
125-
displayName: 'Clean source directory'
126-
- script: |
127-
echo '$(Build.SourceVersion)' > '$(Build.ArtifactStagingDirectory)/commit.txt'
128-
displayName: 'Add commit hash to artifacts archive'
129-
- task: Bash@3
130-
displayName: Setup
131-
inputs:
132-
filePath: $(Build.SourcesDirectory)/.ci/setup.sh
133-
targetType: filePath
134-
- task: Bash@3
135-
displayName: Test
136-
inputs:
137-
filePath: $(Build.SourcesDirectory)/.ci/test.sh
138-
targetType: filePath
139-
- task: PublishBuildArtifacts@1
140-
condition: >
141-
and(
142-
succeeded(),
143-
in(variables['TASK'], 'regular', 'sdist', 'bdist', 'swig'),
144-
not(startsWith(variables['Build.SourceBranch'], 'refs/pull/'))
145-
)
146-
inputs:
147-
pathtoPublish: '$(Build.ArtifactStagingDirectory)'
148-
artifactName: PackageAssets
149-
artifactType: container
150-
################
151-
# Linux_latest #
152-
################
153-
- job: Linux_latest
154-
variables:
155-
COMPILER: clang-17
156-
DEBIAN_FRONTEND: 'noninteractive'
157-
IN_UBUNTU_BASE_CONTAINER: 'true'
158-
OS_NAME: 'linux'
159-
SETUP_CONDA: 'true'
160-
pool: mariner-20240410-0
161-
container: ubuntu-latest
162-
strategy:
163-
matrix:
164-
regular:
165-
TASK: regular
166-
sdist:
167-
TASK: sdist
168-
bdist:
169-
TASK: bdist
170-
PYTHON_VERSION: '3.11'
171-
inference:
172-
TASK: if-else
173-
mpi_source:
174-
TASK: mpi
175-
METHOD: source
176-
mpi_pip:
177-
TASK: mpi
178-
METHOD: pip
179-
PYTHON_VERSION: '3.12'
180-
mpi_wheel:
181-
TASK: mpi
182-
METHOD: wheel
183-
PYTHON_VERSION: '3.10'
184-
gpu_source:
185-
TASK: gpu
186-
METHOD: source
187-
PYTHON_VERSION: '3.12'
188-
gpu_pip:
189-
TASK: gpu
190-
METHOD: pip
191-
PYTHON_VERSION: '3.11'
192-
gpu_wheel:
193-
TASK: gpu
194-
METHOD: wheel
195-
PYTHON_VERSION: '3.10'
196-
cpp_tests:
197-
TASK: cpp-tests
198-
METHOD: with-sanitizers
199-
steps:
200-
- script: |
201-
echo "##vso[task.setvariable variable=BUILD_DIRECTORY]$BUILD_SOURCESDIRECTORY"
202-
CONDA=$HOME/miniforge
203-
echo "##vso[task.setvariable variable=CONDA]$CONDA"
204-
echo "##vso[task.prependpath]$CONDA/bin"
205-
displayName: 'Set variables'
206-
# https://github.com/microsoft/azure-pipelines-agent/issues/2043#issuecomment-687983301
207-
- script: |
208-
/tmp/docker exec -t -u 0 ci-container \
209-
sh -c "apt-get update && apt-get -o Dpkg::Options::="--force-confold" -y install sudo"
210-
displayName: 'Install sudo'
211-
- script: |
212-
sudo apt-get update
213-
sudo apt-get install -y --no-install-recommends git
214-
git clean -d -f -x
215-
displayName: 'Clean source directory'
216-
- task: Bash@3
217-
displayName: Setup
218-
inputs:
219-
filePath: $(Build.SourcesDirectory)/.ci/setup.sh
220-
targetType: 'filePath'
221-
- task: Bash@3
222-
displayName: Test
223-
inputs:
224-
filePath: $(Build.SourcesDirectory)/.ci/test.sh
225-
targetType: 'filePath'
52+
# TODO: add these jobs back when issues from https://github.com/microsoft/LightGBM/issues/6918 are resolved
53+
# ###############
54+
# # Maintenance #
55+
# ###############
56+
# - job: Maintenance
57+
# pool: mariner-20240410-0
58+
# container: ubuntu-latest
59+
# # routine maintenance (like periodically deleting old files),
60+
# # to be run on 1 random CI runner in the self-hosted pool each runner
61+
# steps:
62+
# - script: |
63+
# print-diagnostics(){
64+
# echo "---- df -h -m ----"
65+
# df -h -m
66+
# echo "---- docker system df ----"
67+
# /tmp/docker system df
68+
# echo "---- docker images ----"
69+
# /tmp/docker images
70+
# }
71+
# # check disk usage
72+
# print-diagnostics
73+
# # remove old containers, container images, volumes
74+
# # ref: https://stackoverflow.com/a/32723127/3986677
75+
# # ref: https://depot.dev/blog/docker-clear-cache#removing-everything-with-docker-system-prune
76+
# echo "---- running 'docker system prune' ----"
77+
# /tmp/docker system prune \
78+
# --all \
79+
# --force \
80+
# --volumes \
81+
# --filter until=720h
82+
# # check disk usage again
83+
# print-diagnostics
84+
# displayName: Clean
85+
# #########
86+
# # Linux #
87+
# #########
88+
# - job: Linux
89+
# variables:
90+
# COMPILER: gcc
91+
# SETUP_CONDA: 'false'
92+
# OS_NAME: 'linux'
93+
# PRODUCES_ARTIFACTS: 'true'
94+
# pool: mariner-20240410-0
95+
# container: linux-artifact-builder
96+
# strategy:
97+
# matrix:
98+
# regular:
99+
# TASK: regular
100+
# PYTHON_VERSION: '3.11'
101+
# sdist:
102+
# TASK: sdist
103+
# PYTHON_VERSION: '3.9'
104+
# bdist:
105+
# TASK: bdist
106+
# PYTHON_VERSION: '3.10'
107+
# inference:
108+
# TASK: if-else
109+
# mpi_source:
110+
# TASK: mpi
111+
# METHOD: source
112+
# PYTHON_VERSION: '3.10'
113+
# gpu_source:
114+
# TASK: gpu
115+
# METHOD: source
116+
# swig:
117+
# TASK: swig
118+
# steps:
119+
# - script: |
120+
# echo "##vso[task.setvariable variable=BUILD_DIRECTORY]$BUILD_SOURCESDIRECTORY"
121+
# echo "##vso[task.prependpath]/usr/lib64/openmpi/bin"
122+
# echo "##vso[task.prependpath]$CONDA/bin"
123+
# displayName: 'Set variables'
124+
# - script: |
125+
# git clean -d -f -x
126+
# displayName: 'Clean source directory'
127+
# - script: |
128+
# echo '$(Build.SourceVersion)' > '$(Build.ArtifactStagingDirectory)/commit.txt'
129+
# displayName: 'Add commit hash to artifacts archive'
130+
# - task: Bash@3
131+
# displayName: Setup
132+
# inputs:
133+
# filePath: $(Build.SourcesDirectory)/.ci/setup.sh
134+
# targetType: filePath
135+
# - task: Bash@3
136+
# displayName: Test
137+
# inputs:
138+
# filePath: $(Build.SourcesDirectory)/.ci/test.sh
139+
# targetType: filePath
140+
# - task: PublishBuildArtifacts@1
141+
# condition: >
142+
# and(
143+
# succeeded(),
144+
# in(variables['TASK'], 'regular', 'sdist', 'bdist', 'swig'),
145+
# not(startsWith(variables['Build.SourceBranch'], 'refs/pull/'))
146+
# )
147+
# inputs:
148+
# pathtoPublish: '$(Build.ArtifactStagingDirectory)'
149+
# artifactName: PackageAssets
150+
# artifactType: container
151+
# ################
152+
# # Linux_latest #
153+
# ################
154+
# - job: Linux_latest
155+
# variables:
156+
# COMPILER: clang-17
157+
# DEBIAN_FRONTEND: 'noninteractive'
158+
# IN_UBUNTU_BASE_CONTAINER: 'true'
159+
# OS_NAME: 'linux'
160+
# SETUP_CONDA: 'true'
161+
# pool: mariner-20240410-0
162+
# container: ubuntu-latest
163+
# strategy:
164+
# matrix:
165+
# regular:
166+
# TASK: regular
167+
# sdist:
168+
# TASK: sdist
169+
# bdist:
170+
# TASK: bdist
171+
# PYTHON_VERSION: '3.11'
172+
# inference:
173+
# TASK: if-else
174+
# mpi_source:
175+
# TASK: mpi
176+
# METHOD: source
177+
# mpi_pip:
178+
# TASK: mpi
179+
# METHOD: pip
180+
# PYTHON_VERSION: '3.12'
181+
# mpi_wheel:
182+
# TASK: mpi
183+
# METHOD: wheel
184+
# PYTHON_VERSION: '3.10'
185+
# gpu_source:
186+
# TASK: gpu
187+
# METHOD: source
188+
# PYTHON_VERSION: '3.12'
189+
# gpu_pip:
190+
# TASK: gpu
191+
# METHOD: pip
192+
# PYTHON_VERSION: '3.11'
193+
# gpu_wheel:
194+
# TASK: gpu
195+
# METHOD: wheel
196+
# PYTHON_VERSION: '3.10'
197+
# cpp_tests:
198+
# TASK: cpp-tests
199+
# METHOD: with-sanitizers
200+
# steps:
201+
# - script: |
202+
# echo "##vso[task.setvariable variable=BUILD_DIRECTORY]$BUILD_SOURCESDIRECTORY"
203+
# CONDA=$HOME/miniforge
204+
# echo "##vso[task.setvariable variable=CONDA]$CONDA"
205+
# echo "##vso[task.prependpath]$CONDA/bin"
206+
# displayName: 'Set variables'
207+
# # https://github.com/microsoft/azure-pipelines-agent/issues/2043#issuecomment-687983301
208+
# - script: |
209+
# /tmp/docker exec -t -u 0 ci-container \
210+
# sh -c "apt-get update && apt-get -o Dpkg::Options::="--force-confold" -y install sudo"
211+
# displayName: 'Install sudo'
212+
# - script: |
213+
# sudo apt-get update
214+
# sudo apt-get install -y --no-install-recommends git
215+
# git clean -d -f -x
216+
# displayName: 'Clean source directory'
217+
# - task: Bash@3
218+
# displayName: Setup
219+
# inputs:
220+
# filePath: $(Build.SourcesDirectory)/.ci/setup.sh
221+
# targetType: 'filePath'
222+
# - task: Bash@3
223+
# displayName: Test
224+
# inputs:
225+
# filePath: $(Build.SourcesDirectory)/.ci/test.sh
226+
# targetType: 'filePath'
226227
#########
227228
# macOS #
228229
#########
@@ -364,8 +365,9 @@ jobs:
364365
###########
365366
- job: Package
366367
dependsOn:
367-
- Linux
368-
- Linux_latest
368+
# TODO: add jobs back when https://github.com/microsoft/LightGBM/issues/6918 is resolved
369+
# - Linux
370+
# - Linux_latest
369371
- macOS
370372
- Windows
371373
- R_artifact

0 commit comments

Comments
 (0)