1
0
mirror of https://github.com/SAP/jenkins-library.git synced 2024-12-14 11:03:09 +02:00
Commit Graph

4579 Commits

Author SHA1 Message Date
triThirty
c105b2129b
helmExecute: Grab values from environment variables (#4374)
* Grab values from environment variables

* use os.ExpandEnv in RunHelmUpgrade function

* use os.ExpandEnv in RunHelmUpgrade function

* use os.ExpandEnv in RunHelmUpgrade function

* Extract new logic to separate func && update tests

---------

Co-authored-by: Mao <bruce.mao@sap.com>
Co-authored-by: Vyacheslav Starostin <32613074+vstarostin@users.noreply.github.com>
2023-07-12 13:14:03 +06:00
Daria Kuznetsova
96f5508c8a
fix(codeqlExecuteScan): moved flag checkIfCompliance (#4443)
* moved checkForCompliance flag, updated description of sarif check params

* added generated codeqlExecuteScan

* moved appending reports before checking for compliance

---------

Co-authored-by: sumeet patil <sumeet.patil@sap.com>
2023-07-11 22:02:54 +05:30
Ashly Mathew
34202c708f
fix(npm): Introduce installation for cyclone-node-npm in another folder and fallback to cyclonedx/bom to help users generate BOM (#4390)
* Test

* Try omit

* Introduce global installation and fallback

* Extract to a separate function

* Fix unit tests

* Add root permissions for docker image for Azure

* Install in another folder

* fix unit tests

* Cleanup

* introduce back --no-save,change directory name, fix tests

* add tmp folder to npmignore

* change docker image for guage

* Revert "change docker image for guage"

This reverts commit 45ac7ca9bc.
2023-07-11 16:18:20 +02:00
Ashly Mathew
d631b98a41
chore(test): update docker image used for Gauge integration tests (#4458)
* Change gauge tests docker image to node buster
2023-07-11 15:47:57 +02:00
Anil Keshav
bca2a17cae
fix(ci): add conditional coverage upload to CodeClimate (#4455)
* separating the unit test and test upload

* enhacing conditions

* making the condition more strict to run on pr from a local branch

* enhacing condition when unit test are successfull

* removing condition for previous step checks

* pinning gauge to 1.4.3 for regression test

* reverting integration test
2023-07-11 10:39:35 +02:00
renovate[bot]
07ca063ee0
chore(deps): update dependency org.jacoco:jacoco-maven-plugin to v0.8.10 (#4446)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-10 10:32:25 +02:00
Alexander Link
500c42860f
Stash via Utils.stash (#4380)
We should use Utils.stash instead of native steps.stash calls (Jenkins)
since important logging is missing.
The default Jenkins stash step does not log any metadata like
stash name, patterns, etc.
2023-07-07 14:35:14 +02:00
Alexander Link
1e9d8dfe98
Unstash via Utils.unstash (#4381)
We should only unstash using the Utils class.
The Jenkins unstash step does not log which stash was unstashed.
2023-07-07 14:00:44 +02:00
Pavel Busko
610e212306
feat(cnbBuild) Add support for pre and post-buildpacks (#4448)
* Add pre and post buildpacks

Co-authored-by: Johannes Dillmann <j.dillmann@sap.com>
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
Co-authored-by: Pavel Busko <pavel.busko@sap.com>

* fix integration tests

Co-authored-by: Pavel Busko <pavel.busko@sap.com>
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>

* simplify if clauses

Co-authored-by: Pavel Busko <pavel.busko@sap.com>

---------

Co-authored-by: Johannes Dillmann <j.dillmann@sap.com>
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2023-07-06 11:34:05 +02:00
renovate[bot]
b9bb5265ca
chore(deps): update actions/cache action to v3 (#4439)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-05 12:08:14 +02:00
renovate[bot]
9b1aebfd13
chore(deps): update actions/setup-java action to v3 (#4436)
* chore(deps): update actions/setup-java action to v3

* Apply suggestions from code review

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
2023-07-05 11:35:34 +02:00
renovate[bot]
380144b457
chore(deps): update actions/setup-go action to v4 (#4435)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-05 10:14:28 +02:00
renovate[bot]
3e0da62a0b
chore(deps): update actions/checkout action to v3 (#4440)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-04 17:34:16 +02:00
dependabot[bot]
fa11eb47aa
build(deps): bump github.com/opencontainers/runc from 1.1.2 to 1.1.5 (#4307)
Bumps [github.com/opencontainers/runc](https://github.com/opencontainers/runc) from 1.1.2 to 1.1.5.
- [Release notes](https://github.com/opencontainers/runc/releases)
- [Changelog](https://github.com/opencontainers/runc/blob/v1.1.5/CHANGELOG.md)
- [Commits](https://github.com/opencontainers/runc/compare/v1.1.2...v1.1.5)

---
updated-dependencies:
- dependency-name: github.com/opencontainers/runc
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>
2023-07-04 16:10:54 +02:00
renovate[bot]
920c2480e7
chore(deps): update actions/stale action to v8 (#4438)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-04 15:53:40 +02:00
dependabot[bot]
c7ab4240e9
build(deps): bump github.com/docker/distribution (#4359)
Bumps [github.com/docker/distribution](https://github.com/docker/distribution) from 2.8.1+incompatible to 2.8.2+incompatible.
- [Release notes](https://github.com/docker/distribution/releases)
- [Commits](https://github.com/docker/distribution/compare/v2.8.1...v2.8.2)

---
updated-dependencies:
- dependency-name: github.com/docker/distribution
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>
2023-07-04 13:00:11 +00:00
renovate[bot]
8fe1d5553e
chore(deps): update actions/setup-python action to v4 (#4437)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-04 14:35:44 +02:00
Pavel Busko
13f1e94ade
fix(cnbBuild): read dockerConfigJSON from CPE and merge it with user-provided (#4444)
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2023-07-04 14:19:02 +02:00
Pavel Busko
1befaa80a2
fix(cnbBuild): correctly construct docker config using credentials (#4441)
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2023-07-03 08:55:06 +00:00
Pavel Busko
d8dacda121
feat(cnbBuild): support setting registry username and password via parameters (#4426)
* feat(cnbBuild): support setting registry username and password via parameters

* fix gitops integration test assertion

Co-authored-by: Pavel Busko <pavel.busko@sap.com>

* Update integration/integration_gitops_test.go

---------

Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2023-06-30 12:02:35 +00:00
renovate[bot]
a614923e18
chore: Configure Renovate (#4351)
* Add renovate.json

* Update and rename renovate.json to .github/renovate.json

* Update renovate.json

* Update renovate.json

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
2023-06-30 13:32:32 +02:00
Jk1484
30d82e920d
fix(kaniko): Update documentation (#4405)
* replacing mandatory if to mandatory.

* Revert "replacing mandatory if to mandatory."

This reverts commit f98ab5f0ff.

* Update documentation

* go generate

* Update documentation

* go generate

---------

Co-authored-by: Ashly Mathew <ashly.mathew@sap.com>
Co-authored-by: Vyacheslav Starostin <vyacheslav.starostin@sap.com>
2023-06-29 14:11:34 +06:00
Jordi van Liempt
bc2cdd18b8
fix(url-logger): Enable access log generation for mavenBuild (#4421)
Co-authored-by: I557621 <jordi.van.liempt@sap.com>
2023-06-28 09:27:08 +02:00
Christopher Fenner
9c23cb3820
Update verify-go.yml (#4425) 2023-06-27 17:29:59 +02:00
Jk1484
4d182e9516
adding tag for running of unit tests (#4416) 2023-06-26 20:19:36 +05:00
Marcus Holl
244beccb59
refactor(dockerExecuteOnKubernetes ): dedicated method for invalidating stashes (#4284)
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
2023-06-26 09:56:18 +02:00
Anil Keshav
a9bab48557
feat (url-logger) Implement logic for a selection classifier (#4411)
* forcing the urls finder to relaxed

* adding a classifier map

* passing the stepName to the kaniko command executor bundle

* pass stepName to maven utils for mavenBuild

* improve enabling of Maven access log generation

* Revert "improve enabling of Maven access log generation"

This reverts commit 80b77223cd.

* Revert "pass stepName to maven utils for mavenBuild"

This reverts commit a4f99ae160.

* use reflection to update command stepName for mavenBuild

* Revert "use reflection to update command stepName for mavenBuild"

This reverts commit ef85c78669.

---------

Co-authored-by: I557621 <jordi.van.liempt@sap.com>
Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>
2023-06-26 08:47:11 +02:00
Andrei Kireev
ae4550d0dd
fix(detectExecuteScan) Fixed problem with duplication of maven command (#4412)
* Fixed problem with duplication of maven command

* go fmt
2023-06-23 14:24:03 +02:00
Dmitrii Pavlukhin
f81b473723
fix(detectExecuteScan): Fix license incorrect fail with FailOn parameter (#4415)
Co-authored-by: Andrei Kireev <andrei.kireev@sap.com>
2023-06-21 11:48:00 +05:30
Daria Kuznetsova
6eb4c2e72d
fix(codeqlExecuteScan): added waiting for the SARIF file upload (#4409)
* added waiting for the sarif file uploaded & tests

* increased polling time, added timeout for waiting response from server & tests

* fixed handling error while waiting sarif uploaded

* added params for checking sarif uploaded & refactor

* added test logs

* fixed logs and test

* added returning missed error

* changed params descriptions and server response error processing processing

* fixed retrying logic

* increased polling timeout params & refactored
2023-06-20 15:50:28 +03:00
Marcus Holl
8b36ae70e7
Adjust npmExecuteLint (output-format, print output to console) (#4407)
* Adjust npmExecuteLint (output-format, print output to console)

Co-authored-by: Srinikitha Kondreddy <srinikitha.kondreddy@sap.com>
2023-06-19 12:04:37 +02:00
Marcus Holl
799853e791
[refactor] avoid code duplication when invoking eslint (#4401) 2023-06-15 12:27:38 +02:00
sumeet patil
9b60fcf506
fix(codeqlExecuteScan): fixed logic for getting code-scanning alerts (#4393) 2023-06-14 16:59:01 +05:30
Anil Keshav
39d52a2123
feat (protecodeExecuteScan) enhancing protecode step with registry credentials (#4378)
* enhancing protecode with registry credentials

* Use protecodeUtils instead of separate package

* Add target path for docker config to be created

* Fix tests

* Fix build flags

---------

Co-authored-by: Vyacheslav Starostin <vyacheslav.starostin@sap.com>
2023-06-14 09:11:33 +02:00
Marcus Holl
97495fd18b
fix: resolve lint files (#4392)
Fix glob pattern for resolving eslint files
Do not swallow exception when resolving lint files
2023-06-07 14:58:44 +02:00
sumeet patil
416cb1d327
fix(codeqlExecuteScan): added report file to output resources (#4388) 2023-06-02 18:31:52 +05:30
Marcus Holl
de7027df40
stashing tests (#4379)
Co-authored-by: Alexander Link <33052602+alxsap@users.noreply.github.com>

Co-authored-by: Alexander Link <33052602+alxsap@users.noreply.github.com>
2023-06-01 15:49:07 +02:00
Marcus Holl
83519eb771
fix misleading/wrong comment (#4295) 2023-06-01 15:22:57 +02:00
michaelkubiaczyk
072378bb83
Cxone release - Fixes for 0-result scans, better preset handling (#4387)
* Initial in progress

* compiling but not yet functional

* Missed file

* updated checkmarxone step

* Working up to fetching a project then breaks

* Missed file

* Breaks when retrieving projects+proxy set

* Create project & run scan working, now polling

* Fixed polling

* added back the zipfile remove command

* Fixed polling again

* Generates and downloads PDF report

* Updated and working, prep for refactor

* Added compliance steps

* Cleanup, reporting, added groovy connector

* fixed groovy file

* checkmarxone to checkmarxOne

* checkmarxone to checkmarxOne

* split credentials (id+secret, apikey), renamed pullrequestname to branch, groovy fix

* Fixed filenames & yaml

* missed the metadata_generated.go

* added json to sarif conversion

* fix:type in new checkmarxone package

* fix:type in new checkmarxone package

* removed test logs, added temp error log for creds

* extra debugging to fix crash

* improved auth logging, fixed query parse issue

* fixed bug with group fetch when using oauth user

* CWE can be -1 if not defined, can't be uint

* Query also had CweID

* Disabled predicates-fetch in sarif generation

* Removing leftover info log message

* Better error handling

* fixed default preset configuration

* removing .bat files - sorry

* Cleanup per initial review

* refactoring per Gist, fixed project find, add apps

* small fix - sorry for commit noise while testing

* Fixing issues with incremental scans.

* removing maxretries

* Updated per PR feedback, further changes todo toda

* JSON Report changes and reporting cleanup

* removing .bat (again?)

* adding docs, groovy unit test, linter fixes

* Started adding tests maybe 15% covered

* fix(checkmarxOne): test cases for pkg and reporting

* fix(checkmarxOne):fix formatting

* feat(checkmarxone): update interface with missing method

* feat(checkmarxone):change runStep signature to be able to inject dependency

* feat(checkmarxone): add tests for step (wip)

* Adding a bit more coverage

* feat(checkmarxOne): fix code review

* feat(checkmarxOne): fix code review

* feat(checkmarxOne): fix code review

* feat(checkmarxOne): fix integration test PR

* adding scan-summary bug workaround, reportgen fail

* enforceThresholds fix when no results passed in

* fixed gap when preset empty in yaml & project conf

* fixed another gap in preset selection

* fix 0-result panic

* fail when no preset is set anywhere

* removed comment

---------

Co-authored-by: thtri <trinhthanhhai@gmail.com>
Co-authored-by: Thanh-Hai Trinh <thanh.hai.trinh@sap.com>
2023-06-01 11:03:01 +02:00
Daria Kuznetsova
cd71282f00
fix(codeqlExecuteScan): pagination call for getting codescanning results (#4370)
pagination call for getting code scanning results

---------

Co-authored-by: sumeet patil <sumeet.patil@sap.com>
2023-05-31 14:07:09 +05:30
Leonard Heilos
c15448b4e0
feat(whitesourceExecuteScan): allow to specify InstallCommand (#4376)
* feat(whitesourceExecuteScan) allow to specify InstallCommand

* reorder imports

---------

Co-authored-by: sumeet patil <sumeet.patil@sap.com>
Co-authored-by: Andrei Kireev <andrei.kireev@sap.com>
2023-05-30 16:00:02 +02:00
Jk1484
a2109c59b5
fix(gradle): Pin schema version of cyclonedx (#4367)
Co-authored-by: Ashly Mathew <ashly.mathew@sap.com>
Co-authored-by: Vyacheslav Starostin <32613074+vstarostin@users.noreply.github.com>
2023-05-30 16:21:16 +06:00
Jk1484
7f2e58b211
fix(golangBuild): pinversion of cyclonedx (#4368)
* output version pin for cyclonedx

* test fix

---------

Co-authored-by: Vyacheslav Starostin <32613074+vstarostin@users.noreply.github.com>
2023-05-30 16:06:34 +06:00
thtri
5ab432b804
fix(whitesource):add stash for checkmarxOne (#4383) 2023-05-30 11:06:14 +02:00
Vyacheslav Starostin
b305cd102d
kubernetesDeploy: Add kube-context parameter for helm test command (#4332)
* kubernetesDeploy: Add kube-context parameter for helm test command

* Resolve merge conflict
2023-05-25 17:03:33 +06:00
sumeet patil
1c018dbff7
feat(codeqlExecuteScan) : auto fill api url (#4369) 2023-05-22 19:59:43 +05:30
Ashly Mathew
b4e678333b
fix(Python) :Pin version of cyclonedx package for python builds (#4356) 2023-05-22 14:03:40 +02:00
Jk1484
27c3c3c4c7
feat(vault): support for multiple general purpose credential paths (#4360)
* created wrapper

* tests added

* update documentation

* tests data race fix

---------

Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>
2023-05-22 10:49:28 +02:00
larsbrueckner
1e4b88a6f8
detectExecuteScan: fix toolrun data (#4366) 2023-05-17 17:21:03 +05:30
Srinikitha Kondreddy
a76b20f09f
Upgrade sonar scanner cli image version to 4.8 (#4362)
* Uprade sonar scanner cli version to 4.8

* Update download url
2023-05-17 09:24:27 +02:00