mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
CI: Introduce lint-backend pipeline (#55476)
* Introduce lint-backend pipeline * Use go image and install make * Don't run lint pipeline on .drone.yml changes
This commit is contained in:
committed by
GitHub
parent
b25ea75bac
commit
c18432971b
31
scripts/drone/pipelines/lint_backend.star
Normal file
31
scripts/drone/pipelines/lint_backend.star
Normal file
@@ -0,0 +1,31 @@
|
||||
load(
|
||||
'scripts/drone/steps/lib.star',
|
||||
'identify_runner_step',
|
||||
'wire_install_step',
|
||||
'lint_backend_step',
|
||||
'lint_drone_step',
|
||||
'compile_build_cmd',
|
||||
)
|
||||
|
||||
load(
|
||||
'scripts/drone/utils/utils.star',
|
||||
'pipeline',
|
||||
)
|
||||
|
||||
def lint_backend_pipeline(trigger, ver_mode):
|
||||
wire_step = wire_install_step()
|
||||
wire_step.update({ 'depends_on': [] })
|
||||
init_steps = [
|
||||
identify_runner_step(),
|
||||
compile_build_cmd(),
|
||||
wire_step,
|
||||
]
|
||||
test_steps = [
|
||||
lint_backend_step(edition="oss"),
|
||||
]
|
||||
if ver_mode == 'main':
|
||||
test_steps.extend([lint_drone_step()])
|
||||
|
||||
return pipeline(
|
||||
name='{}-lint-backend'.format(ver_mode), edition="oss", trigger=trigger, services=[], steps=init_steps + test_steps,
|
||||
)
|
||||
Reference in New Issue
Block a user