1
0
mirror of https://github.com/SAP/jenkins-library.git synced 2024-12-12 10:55:20 +02:00
Commit Graph

813 Commits

Author SHA1 Message Date
Linda Siebert
8eb0c6aa48
Adjust sonarExecuteScan step (#3527)
* add check for instance parameter

* remove default from yaml

* adapt changes

* Update stashSettings.yml

* Unstash

* Add echo

* Stash changes

* Remove changes

* stash everything

* Change it up

* Change go

* Switch to new solution

* Try new stash

* Remove compliance

* Move Artifacts

* Change stashing

* Match others

* Remove space

* Test if warning goes away

Co-authored-by: Jesse Awan <jesse.awan@sap.com>
2022-02-25 13:09:50 +01:00
Christian Volk
956cab5de3
fix(kaniko): backwards compatibility with kaniko 1.3.0 (#3583)
* fix(kaniko): jnlp issues

* fix

* fix(kanikoExecute): backwards compatibility with kaniko 1.3.0

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-24 17:38:47 +01:00
Philipp Stehle
402b8b28fa
feat(kubernetesDeploy): initial support for multiple images (#3548)
Co-authored-by: Philipp Stehle <philipp.stehle@sap.com>
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2022-02-24 12:01:36 +01:00
Ralf Pannemans
08bfe1554e
feat(cnbBuild) Introducing preserveFiles config to copy back files (#3562)
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2022-02-23 18:54:59 +01:00
Philipp Stehle
4c18f2a128
feat: Add support for deprecating step parameters (#3554)
this was already used in fortifyExecuteScan, but had no effect.

Co-authored-by: Philipp Stehle <philipp.stehle@sap.com>

Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
2022-02-23 15:16:05 +01:00
Christian Volk
d428cfcbd1
feat(kanikoExecute): image digests (#3566)
* feat(init stage): artifact version

* feat(kaniko): expose image digests to cpe

* fix

* handle tmp folder creation differently

* fix

* fix

* fix tests

* set ignore-path to /
2022-02-23 11:41:26 +01:00
RobertOzga87
9fa8390ef2
--ignore-path=/ in order to fix (#3570)
```
ERROR: Process exited immediately after creation. See output below
Executing /busybox/sh script inside container container-exec of pod dynamic-agent-...
```
On jenkins

Co-authored-by: Robert Ozga <robert.ozga@sap.com>
Co-authored-by: Christian Volk <christian.volk@sap.com>
2022-02-23 11:05:59 +01:00
Sven Merk
a1988f6808
feat(whitesourceExecuteScan): GitHub issue creation + SARIF (#3535)
* Add GH issue creation + SARIF

* Code cleanup

* Fix fmt, add debug

* Code enhancements

* Fix

* Added debug info

* Rework UA log scan

* Fix code

* read UA version

* Fix nil reference

* Extraction

* Credentials

* Issue creation

* Error handling

* Fix issue creation

* query escape

* Query escape 2

* Revert

* Test avoid update

* HTTP client

* Add support for custom TLS certs

* Fix code

* Fix code 2

* Fix code 3

* Disable cert check

* Fix auth

* Remove implicit trust

* Skip verification

* Fix

* Fix client

* Fix HTTP auth

* Fix trusted certs

* Trim version

* Code

* Add token

* Added token handling to client

* Fix token

* Cleanup

* Fix token

* Token rework

* Fix code

* Kick out oauth client

* Kick out oauth client

* Transport wrapping

* Token

* Simplification

* Refactor

* Variation

* Check

* Fix

* Debug

* Switch client

* Variation

* Debug

* Switch to cert check

* Add debug

* Parse self

* Cleanup

* Update resources/metadata/whitesourceExecuteScan.yaml

* Add debug

* Expose subjects

* Patch

* Debug

* Debug2

* Debug3

* Fix logging response body

* Cleanup

* Cleanup

* Fix request body logging

* Cleanup import

* Fix import cycle

* Cleanup

* Fix fmt

* Fix NopCloser reference

* Regenerate

* Reintroduce

* Fix test

* Fix tests

* Correction

* Fix error

* Code fix

* Fix tests

* Add tests

* Fix code climate issues

* Code climate

* Code climate again

* Code climate again

* Fix fmt

* Fix fmt 2

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-23 09:30:19 +01:00
Rinita Asani
cd2ae89229
Local scopeg cts execute abap unit test (#3563)
* Adjust local changed objects with commit history

* fix the righ history entry

* fix for local packages commit history

* Adapt unit tests and fix for retry after 500

* Rename gctsExecuteABAPUnitTests to gctsExecuteABAPQualityChecks

* Add unit test file for gCTSExecuteABAPUnitTest

* add a test step

* gcts Test change files

* Add unit test for gCTS test

* adapt gctsTEST

* deletegcts

* command

* maintain old step

* Adapt changes to documentation

* fix for go generate
2022-02-22 09:58:22 +01:00
Oliver Nocon
f711925bc1
chore(cloudFoundryDeploy): deprecate deep config structure (#3486)
* chore(cloudFoundryDeploy): deprecate deep config structure

* Update cloudFoundryDeploy.yaml

* update generation
2022-02-21 15:08:07 +01:00
Siarhei Pazdniakou
4a4526b976
feat(npmExecuteScripts): add gcs upload to the step (#3428)
* Add gcs upload to npmExecuteScripts step

* go generate

* removed patterns related to sapGenerateEnvironmentInfo step

* patterns was updated

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 10:01:14 +01:00
Siarhei Pazdniakou
a059a41c68
feat(whitesourceExecuteScan): add gcs upload to the step (#3427)
* Add gcs upload to whitesourceExecuteScan step

* go generate

* patterns were updated

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 09:51:52 +01:00
Siarhei Pazdniakou
8ac861061d
feat(protecodeExecuteScan): add gcs upload to the step (#3425)
* Add gcs upload to protecodeExecuteScan step

* patterns were updated

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 09:31:43 +01:00
Siarhei Pazdniakou
98e28befe1
feat(fortifyExecuteScan): add gcs upload to the step (#3424)
* Add gcs upload to fortifyExecuteScan step

* go generate

* Patterns were updated

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 09:23:54 +01:00
Oliver Nocon
6247c5dddd
feat(buildsettings): golang and future tools (#3561)
Co-authored-by: Christian Volk <christian.volk@sap.com>
2022-02-21 09:16:48 +01:00
Siarhei Pazdniakou
61a6309f02
feat(checkmarxExecuteScan): add gcs upload to the step (#3386)
* cumulus upload was integrated

* Patterns was updated

* go generate

* patterns were updated

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 09:01:05 +01:00
Siarhei Pazdniakou
9994a4db45
feat(detectExecuteScan): add gcs upload to the step (#3423)
* Add gcs upload to detectExecuteScan step

* go generate

* patterns were updated

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-21 08:07:55 +01:00
Michael
385038e652
(feat) gitopsUpdateDeployment supports globbing 🌟 (#3533)
* (feat) support for kustomize in gitopsUpdateDeployment step

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* add missing documentation

* add another detail in the documentation

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* generate again the update doc

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* (feat) gitopsUpdateDeployment now supports globbing

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* generate and fmt

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* fix tests

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-18 08:43:34 +01:00
Christian Volk
20f5e955f9
Revert "feat(kaniko): pass image digests to cpe (#3542)" (#3556)
This reverts commit 2af9d3aae5.
2022-02-18 08:25:31 +01:00
Christian Volk
25abbe42cc
feat(golangBuild): upload reports to GCS (#3550)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-17 17:56:45 +01:00
Oliver Nocon
a4a0873081
feat(checkmarx): create GitHub issue with findings (#3543)
* feat(checkmarx): create GitHub issue with findings

* add github issue reporting
2022-02-17 15:16:55 +01:00
Christian Volk
2af9d3aae5
feat(kaniko): pass image digests to cpe (#3542)
* feat(kaniko): expose image digests to cpe

* fix
2022-02-17 10:06:54 +01:00
Ralf Pannemans
4b2f61589d
feat(cnbbuild) enable multi image build (#3521)
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
Co-authored-by: Pavel Busko <pavel.busko@sap.com>
Co-authored-by: Sumit Kulhadia <sumit.kulhadia@sap.com>
2022-02-15 14:39:14 +01:00
Michael
1ea965ae69
(feat) support for kustomize in gitopsUpdateDeployment step (#3524)
* (feat) support for kustomize in gitopsUpdateDeployment step

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* add missing documentation

* add another detail in the documentation

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

* generate again the update doc

Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-14 07:45:54 +01:00
Vitalii Sidorov
93e3801945
feat: add step for Helm execution (#3419)
* Implement helm step

* Create kubernetes package

* Refactoring helm.go

* Add package, test commands

* Add test for helm package

* Add tests for helm.go

* Add tests for helm.go

* Add tests for utils.go

* Add tests for helmExecute.go

* small fix

* Add helm lint

* small fix

* small fix

* Fix according to comments

* Fix test

* small fix

* Add helm add function

* Changes according to new comments

* Add helm push

* Add unit tests

* Add tests for helmExecute

* Add small fix

* small fix

* small fix

* Move DeployUtilsBundle from kubernetesDeploy to kubernetes package

* small fix

* small fix

* Add unit-tests

* Fix

* Update resources/metadata/helmExecute.yaml

* Update resources/metadata/helmExecute.yaml

* Add helm chart server parameterization

* small fix

* small fix

Co-authored-by: “Vitalii <“vitalii.sidorov@sap.com”>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-10 10:25:03 +01:00
Christian Volk
5aa9661db6
feat(kanikoExecute): preparation for multi-arch builds (#3515)
* feat(kanikoExecute): preparation for multi-arch builds

* missing files
2022-02-09 10:17:34 +01:00
Marcus Holl
5ad6d0a20a
mtaExtensionCredentials: docu, logging, less strict replacements (#3489)
* Enhance doku for mtaExtensionCredentials for cloudFoundryDeploy

* Error message starting with lower case

* Log entry in case a variable is not used.

* Be less strict when replacing placeholders

* Check the variable name since we use now regex

* fix error message in assert

* simplify check for not replaced placeholders

* report unresolved

* report updated

* test updated=false

* 'do not' instead of 'does not' (test name)

* wip

* content not shared between tests

* rework parameter docu

* fix missing trailing quotation mark in test content

* Adjust quantifier when looking for not replaced placeholders

* fmt
2022-02-09 09:33:12 +01:00
Daniel Bernd
0d8bd7dc52
Add step abapEnvironmentPushATCSystemConfig (#3426)
* Checkin Go File - Push ATC Config

* ATC Push Config - Testfile

* Initial generated go files for ATC System Configuration

* ApiProxyUpload Command (#3295)

* ApiProxyUpload Command

* Code Review Fixes

* CodeReview Changes

* CodeReview Fixes

* YAML fixes

* CodeReview Fix

* Code Review Fixes

* CodeReview Fixes

* Code Climate Fixes

* Code Review Fixes

* Code Review Fixes

Co-authored-by: Roland Stengel <r.stengel@sap.com>
Co-authored-by: Oliver Feldmann <oliver.feldmann@sap.com>

* Fetch Xcrsf-Token

* Update  abapEnvironmentPushATCSystemConfig.yaml

* docs: fix urls (#3400)

* fix stash and adapt unit tests accordingly (#3403)

* Push ATC System Configuration - File read, send request, parse response

* fetchATCXcsrfToken

* fix(whitesourceExecuteScan): added missing credential declaration for the docker config (#3404)

* insert command in piper.go

* feat(cnbBuild): remove docker config after parsing (#3417)

Co-authored-by: Philipp Stehle <philipp.stehle@sap.com>

* more funcs

* more funcs

* Revert "feat: Add debug output to getConfig (#3341)" (#3396)

This reverts commit b760bf48e7.

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* feat (kubernetesDeploy) allow secret creation in cluster with kubectl as deploy tool (#3398)

* defaulting deocker config json location

* function change

* harmonising secret creation via json config apply

* adding the env path to kaniko

* env var

* adding path

* adding path

* adding path

* rolling back changes for path

* adapting condition for secret creation

* conditions based on username and password only

* fix unit test as per new secret creation

* update documentation with regards to secret creation

* fixing yaml lint empty line

* fixing trailing line from kaniko yaml

* error condition when path of the docker config json file is not found

Co-authored-by: anilkeshav27 <you@example.com>

* readPipelineEnv -> Serialize Directly to os.Stdout (#3180)

* Serialize CPE Directly to os.Stdout

* Response Error Handling 1

* Add easy mode for AUnit & ATC (#3389)

* remove mandatory flag from config files

* Enable repo.yml as config

* Adapt to merge

* Refactoring

* Refactoring

* avoid panic

* Add comments

* Add easy mode for atc

* Add tests

* Add test

* Refactor

* Add test for MPS

* Updates

* Rename functions

* Add files to gitignore

* Rename

* Renaming

* Renaming

* Renaming

* Improve error messages

* Update documentation

* Add logging

* Rename

* Extend gitignore

* fix(sonar): fix file patterns for gcs upload (#3406)

Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>

* testing piper forks  (#3420)

* developer doku update on how to test with forked repos
Co-authored-by: rosemarieB <45030247+rosemarieB@users.noreply.github.com>

* Error Messages parsing

* Update yaml parameter

* feat (npmExecuteScripts) create seperate npmrc file for publish to private repo (#3422)

* creating new npm rc file

* publishing to registry staging

* exposing base64 version of env variables

* changing encoding param

* fixing unit test for the new path

* debugging env var

* remove debug message

* update docu

* changing new npmrc file name

* adding new npmrc to ignore

* adding new npmrc to ignore

Co-authored-by: anilkeshav27 <you@example.com>

* minor

* small changes

* small changes

* UNIT Test

* Unit Test 2

* Update .gitignore

Co-authored-by: Daniel Mieg <56156797+DanielMieg@users.noreply.github.com>

* Update abapEnvironmentAddons.md: Unable to update target vectors with unchanged SWC version (#3392)

* Update abapEnvironmentAddons.md

* Update documentation/docs/scenarios/abapEnvironmentAddons.md

Co-authored-by: Daniel Mieg <56156797+DanielMieg@users.noreply.github.com>

* Update abapEnvironmentAddons.md

Co-authored-by: Daniel Mieg <56156797+DanielMieg@users.noreply.github.com>

* Returning earlier & parseOdataResp 1

* new Parameter for overwrite existing

* feat(cnbBuild): preserve maven test results in the workspace (#3429)

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

* Update Introduction (#3433)

* Check Existence of configuration

* Quote strings in addon.yml (#3435)

* including vaultSecretFile to parameter generator docu (#3436)

Co-authored-by: anilkeshav27 <you@example.com>

* fix: wrong command line format for multiple extension files (#3434)

* feat(cnbBuild) containerImageName will be defaulted if possible (#3437)

Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
Co-authored-by: Johannes Dillmann <j.dillmann@sap.com>
Co-authored-by: Sumit Kulhadia <sumit.kulhadia@sap.com>

* Corr. check existence

* check existence 2

* existence handling 2

* refinement existence handling & param rename

* config yaml change - no mandatory for bool param

* PATCH for existing Configuration

* fix: correct typo in log message (#3439)

Closes #3438

* feat(protecode): add versioning model (#3373)

* changes to detectExec before master merge

* changes for detectExecuteScan

* self generated code added

* fix syntax errors and update docu

* added unit tests for fail and Group

* fix failOn bug

* add Groups as string array

* add Groups as string array

* tests and validation for groups, failOn

* Updated docs and added more tests

* documentation md files should not be changed

* Handle merge conflicts from PR 1845

* fix merge errors

* remove duplicate groups, merge error

* adding buildCode and buildTool as params

* switching build options

* building maven modules

* parameter correction

* parameter correction

* gnerate with new build parameter

* adding comments

* removing piper lib master and modifying goUtils to download 1.5.7 release

* first cleaning then installing

* multi module maven built

* multi module maven built removing unwanted code

* multi module maven built moving inside switch

* testing

* modifying the default use case to also call maven build

* modifying the default use case to also call maven build wih --

* corrected maven build command

* corrected maven build command with %v

* skipping test runs

* testing for MTA project with single pom

* adding absolute path to m2 path

* clean up

* adding switch for mta and maven and removing env from containers

* commiting changes for new detect step

* correting log message

* code clean up

* unit tests changes to detectExecute

* basic tests for new change

* restoring piperGoUtils to download correct piper binary

* code clean up

* code clean up

* protecodeExecuteScan :: versioning model draft - 1

* protecodeExecuteScan :: version model draft-2

* protecodeExecuteScan :: changing filename and version concatenation

* protecodeExecuteScan :: update documentation

* protecodeExecuteScan :: double URL encoding has been corrected & console messaging improved

* protecodeExecuteScan :: fixed Go/generate validation fail

* protecodeExecuteScan :: fixing failed unit tests

* protecodeExecuteScan :: Version field added

* protecodeExecuteScan :: Version field add => minor changes

* protecodeExecuteScan :: Version field add => fixing tests

Co-authored-by: D072410 <giridhar.shenoy@sap.com>
Co-authored-by: Keshav <anil.keshav@sap.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>

* GCS Upload fixes (#3387)

* Fixed argument type in persist function

* Fixed gcp upload to be usable in internal piper

* Fixed import of packages

* Updated logs

Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Unit Test 2

* Unit Tests

* Add gcs upload to mavenExecuteIntegration step (#3432)

* Add gcs upload to mavenExecuteIntegration step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Check times refine

* Permwrite 0644

* disable http retry (#3447)

* Update maxWaitTime timeout for WhiteSource (#3284)

* Update scanPolling.go

Changing maxWaitTime from 15 to 30 to overcome WhiteSource results reflection in the backend issue.

* Update configHelper.go

* Reset configHelper changes to fix PR 3284

 Committer: raghunathd8

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
Co-authored-by: raghunathd8 <root@docker-evaluation.openstack.eu-nl-1.cloud.sap>
Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>

* removed trailing spaces

* yaml Update

* minor mock for token & Unit Tests

* rename Parameter Patch

* lil refactor & Unit Test

* fixes PATCH & more Unit Tests

* add log at certain points

* not writing configuration file back

* feat(malwareExecuteScan): refactoring and docker support (#3421)

* feat(malwareExecuteScan): add support for scanning docker images

* refactoring

* print out finding if available

* generate toolrecord for malware scan

* persist scan report

* docs

* fix

* fix

* rollback cmd/init_unix.go

* auhenticated pull

* fix

* fix: report shall be consistent with the api model

* gcs upload

* fix linter

* Fix potential nil reference (#3460)

* Add gcs upload to karmaExecuteTests step (#3431)

* Add gcs upload to karmaExecuteTests step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Add gcs upload to gaugeExecuteTests step (#3410)

* Add gcs upload to gaugeExecuteTests step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Add gcs upload to newmanExecute step (#3408)

* Add gcs upload to newmanExecute step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* feat(GitHub): fetch commit statistics (#3381)

* fetch GH statistics

* move GH and Sonar integration tests to own files

* fix imports

* add integration test case

* add result type

* Apply suggestions from code review

* feat: add command to fetch default files (#3445)

* some ideas..

* Add getDefaults command (WIP) (#3444)

* add getYAML function for configs

* create getDefaults command(based on getConfig)

* add getDefaults command to CLI

* read defaults files, using github tokens as well

* write defaults to stdout as JSON object with YAMLs embedded

* catch case where no input files are given

* actually write output to file if outputFile is specified

* mark defaultsFile flag as required

* add basic tests

* add output (string)  test

* adapt generateDefaults() to return output (used for test of previous commit)

* Changes to getDefaults() JSON output (#3449)

* change JSON output to contain separate fields

* filename -> filepath

* Apply suggestions from code review

* Apply suggestions from code review

* Update pkg/config/config_test.go

Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>

* BATCH request preparation

* Add gcs upload to mtaBuild step (#3405)

* Add gcs upload to mtaBuild

* Patterns was updated

* go generate

* removed patterns related to sapGenerateEnvironmentInfo step

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Add gcs upload to mavenBuild step (#3394)

* Add gcs upload to mavenBuild step

* Patterns were updated

* go generate

* removed patterns related to sapGenerateEnvironmentInfo step

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* feat(gradleExecuteBuild): add stage scope to path parameter, fix project dir exist issue (#3401)

* add stage scope to path parameter, fix project dir exist issue

* fix unit test for gradleExecuteBuild

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Add gcs upload to uiVeri5ExecuteTests step (#3409)

* Add gcs upload to uiVeri5ExecuteTests step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Address further nil references (#3462)

* Address further nil references

* Message text

* Final checks

* fix (npmExecuteScripts) allow npm pack before npm publish (#3455)

* adding config to piperNpmr

* scope in cli

* adding scope to repo url and npmrc

* publish to scoped

* removing scope

* changing scope position

* adding scope to userconfig

* adding registry=

* pack and then tar

* not removing tmp folder

* adding flag

* pack before publish

* adding log

* debug

* debug with change directory

* publishing created tar ball

* debug

* üath

* adding main npmrc

* renaming old npmrc file

* error renaming old npmrc file

* renaming err

* correcting npmrc file path

* renaming file back to original

* current working directory

* renaming the npmrc file

* avoiding change directory

* with current working dir

* adding dot

* renaming npmrc and defer removal

* rename files

* Update pkg/npm/publish.go

* Update pkg/npm/publish.go

Co-authored-by: anilkeshav27 <you@example.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Add testing for helm during acceptance stage (#3402)

* Add kubernetesDeploy to Acceptance

* Add more kubernetesDeploy

* Add helm tests

* Change documentation

* Fix docu

* Change generated

* Add tests

* Add groovy tests

* Fix tests

* Change tests

Co-authored-by: Thorsten Duda <thorsten.duda@sap.com>

* Batch Request for Patches

* Fix(gctsDeploy) : add client in config url, disable retry for create and pull (#3464)

* minor Unit Test correction

* lil cleanup

* lil refactoring

* removed nuneeded linebreaks

* refactoring Command on Entity in Batch

* some Unit Tests for Build Batch Request

* more Unittests - Build Batch Request

* fix(fortifyExecuteScan): User assignment based on PR ownership (#3472)

* Debug PR user details

* Check association

* Change to login

* Fix PR creator assignment

* Improve docs

* Fix test

* Update gradle version (#3476)

* Update gradle version

* Update generated file

* small correction Text & Test

* chore(kubernetesDeploy): add telemetry for deployTool (#3469)

* chore(kubernetesDeploy): add telemetry for deployTool

* Update cmd/kubernetesDeploy.go

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* rename Parameter patchIfExisting

* fix (mtaBuild) keep mtar artifact name in synch with maven gav (#3454)

* keep mtar name in synch with maven gav

* retaining slashes

* keeping dots in artifact name

Co-authored-by: anilkeshav27 <you@example.com>

* Update image for gradle build (#3479)

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* Last Changed not Zero check added

* Added pseudo_comment_policy in struct

* Unit Test adaption

* smaller refactoring, Unit Test, removed doubles

* fix(cnbBuild) do not add complete path to telemetry (#3487)

Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
Co-authored-by: Philipp Stehle <philipp.stehle@sap.com>

* Add limitation that table keys are exported generically (#3490)

* Add limitation that table keys are exported generically

* Fix formatting

* Clarify delta calculation of different package types (#3482)

Co-authored-by: tiloKo <70266685+tiloKo@users.noreply.github.com>

* Add troubleshooting for missing add-on registration (#3491)

Co-authored-by: tiloKo <70266685+tiloKo@users.noreply.github.com>

* feat (Documentation) documentation for mavenBuild and npmExecuteScripts that consume dependencies from a private repo. (#3484)

* build depdency docu for maven and npm

* removing trailing white space in yaml

* Update resources/metadata/mavenBuild.yaml

* relative url for vault and mta docu

* running go generate

* keeping vault relative path

* go generate

* reverting to global paths

* go generate

* wild card for a higher level dir

* searching on top folder only

* relative level above

* pointing to infrastructure

* correcting links

Co-authored-by: anilkeshav27 <you@example.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* fix(kanikoExecute): tmp dir (#3478)

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* feat(golangBuild): add support for publishing binaries (#3495)

* fix(golangBuild): keep track of the artifactversion in binary names (#3498)

* fix(golangBuild): keep track of the artifactversion in binary names

* improve the naming scheme

* fix (build dependency) typo corrections (#3494)

* typo corrections

* trailing white space

* go generate

Co-authored-by: anilkeshav27 <you@example.com>

* Revert "fix(golangBuild): keep track of the artifactversion in binary names (#3498)" (#3499)

This reverts commit ec783b0da6.

* sonarqube coverage: additional metrics (#3465)

* sonarqube coverage: additional metrics

* sonarExecuteScan: add lines of code and language distribution to sonarscan.json

* sonarExecuteScan: consider branch in componentService requests

* SonarQube: Do not omit empty values in SonarCoverage

* sonarExecuteScan: Add integration tests for ComponentService getLinesOfCode

* fix tests

* sonarExecuteScan: use pullRequest in componentService

Co-authored-by: I550025 <r.kloe@sap.com>
Co-authored-by: Marc Bormeth <marc.bormeth@sap.com>

* fix(golangBuild): targetRepositoryUrl (#3502)

* fix(golangBuild): targetRepositoryUrl

* regen

* fix(httpclient): folder permissions (#3506)

* fix(golangBuild): use PUT instead of POST (#3504)

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* feat(golangBuild): publish to subfolder (#3503)

* feat(golangBuild): publish to subfolder

* edge case handling

* fix

* fix(golangBuild): expect status 201 instead of 200 (#3508)

* feat(kanikoExecute): allow building multiple images (#3443)

* feat(kanikoExecute): allow building multiple images

* enhance tests

* chore: allow running tests in parallel

* small fixes

* fix: fix destination bug

* update formatting and defaults

* fix yml formatting

* chore: change cpe parameter names

* chore: improve variable naming

* Changes GetJobName value to repositoryname (#3509)

* Update npmExecuteScripts step (#3211)

* Update npmExecuteScripts step

* Fixed failing build

* Fixed path issue

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
Co-authored-by: Christian Volk <christian.volk@sap.com>

* Ignore violations if failOn is NONE (#3513)

* fix(sonarExecuteScan): error handling for report metrics (#3512)

* Generic step   input from addon descriptor (#3467)

* enhance build step to run based on addon.yml in steampunk environment

Co-authored-by: tiloKo <70266685+tiloKo@users.noreply.github.com>

* feat(golangBuild): add BOM creation (#3496)

* Added BOM creation

* Fix cyclonedx install

* undo config.yml changes

* metadata was updated

* Update golangBuild.go

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>

* If statement dearrangement

Co-authored-by: Daniel Bernd <93763187+danManSAP@users.noreply.github.com>
Co-authored-by: Mayur Belur Mohan <68264167+mayurmohan@users.noreply.github.com>
Co-authored-by: Roland Stengel <r.stengel@sap.com>
Co-authored-by: Oliver Feldmann <oliver.feldmann@sap.com>
Co-authored-by: Jordi van Liempt <35920075+jliempt@users.noreply.github.com>
Co-authored-by: Jesse Awan <jesse.awan@sap.com>
Co-authored-by: Pavel Busko <pavel.busko@sap.com>
Co-authored-by: Philipp Stehle <philipp.stehle@sap.com>
Co-authored-by: Marc Bormeth <marc.bormeth@sap.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
Co-authored-by: Anil Keshav <anil.keshav@sap.com>
Co-authored-by: anilkeshav27 <you@example.com>
Co-authored-by: tiloKo <70266685+tiloKo@users.noreply.github.com>
Co-authored-by: Daniel Mieg <56156797+DanielMieg@users.noreply.github.com>
Co-authored-by: Siarhei Pazdniakou <siarhei.pazdniakou@sap.com>
Co-authored-by: Christopher Fenner <26137398+CCFenner@users.noreply.github.com>
Co-authored-by: Peter Persiel <6087940+peterpersiel@users.noreply.github.com>
Co-authored-by: Ralf Pannemans <ralf.pannemans@sap.com>
Co-authored-by: Marcus Holl <marcus.holl@sap.com>
Co-authored-by: Johannes Dillmann <j.dillmann@sap.com>
Co-authored-by: Sumit Kulhadia <sumit.kulhadia@sap.com>
Co-authored-by: Nikolay Grechanov <nikolay.grechanov@sap.com>
Co-authored-by: Umidjon Urunov <79094563+UmidjonUrunov@users.noreply.github.com>
Co-authored-by: D072410 <giridhar.shenoy@sap.com>
Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Sarat Krishnan <78093145+sarat-krk@users.noreply.github.com>
Co-authored-by: Raghunath Deshpande <raghunath.deshpande@sap.com>
Co-authored-by: raghunathd8 <root@docker-evaluation.openstack.eu-nl-1.cloud.sap>
Co-authored-by: Christian Volk <christian.volk@sap.com>
Co-authored-by: Eugene Kortelyov <eugene.kortelyov@sap.com>
Co-authored-by: Linda Siebert <39100394+LindaSieb@users.noreply.github.com>
Co-authored-by: Thorsten Duda <thorsten.duda@sap.com>
Co-authored-by: Matthias Scudlik <matthias.scudlik@gmail.com>
Co-authored-by: I550025 <r.kloe@sap.com>
Co-authored-by: ffeldmann <f.feldmann@sap.com>
Co-authored-by: ManjunathMS35 <manjunathms35@gmail.com>
Co-authored-by: Matthias Scudlik <matthias.scudlik@sap.com>
Co-authored-by: rosemarieB <45030247+rosemarieB@users.noreply.github.com>
2022-02-08 16:14:29 +01:00
xgoffin
2cebf370c9
feat(fortifyExecuteScan): added conversion to SARIF for FPR files (#3485)
* feat(FPRtoSARIF): boilerplate & comments

* Feat(Ingest): Build done, Vulnerabilities partway

* feat(Vulnerabilities): now entirely parsed

* feat(Ingestion): handle Description object

* feat(FprToSarif): integration in Piper step, full xml structure

* feat(fpr_to_sarif): base program. Need to replace names in messages

* feat(fpr_to_sarif): message substitution and custom definition integration

* fix(fpr_to_sarif): missing replacement in tools object

* fix(fortifyExecuteScan): unit tests

* fix(fpr_to_sarif): failing unit test

* Fix fortify folder creation for generating sarif

* deletion of unzip folder

* fix(fortifyExecuteScan): change logging to info

* feat(fpr_to_sarif): better unit test

* fix(fpr_to_sarif): pr tests failing

* feat(fpr_to_sarif): add specific properties to sarif

* feat(fpr_to_sarif): severity integration

* fix(fpr_to_sarif): unit test fixed

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
Co-authored-by: Sumeet PATIL <sumeet.patil@sap.com>
2022-02-08 14:10:40 +01:00
Giridhar Shenoy
286ff1b6ef
detectExecuteScan : support for detect 7 (#3453)
* enable detect 7 script

* unit test uses detect7 as default

* add detect6 test case

* add check for OSEnv detect version

* add test for OSEnv detect version

* update customEnvironmentVariables docu

* fix linting

Co-authored-by: ffeldmann <f.feldmann@sap.com>
2022-02-08 11:55:01 +01:00
Siarhei Pazdniakou
4660f3a311
feat(golangBuild): add BOM creation (#3496)
* Added BOM creation

* Fix cyclonedx install

* undo config.yml changes

* metadata was updated

* Update golangBuild.go

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-08 09:23:33 +01:00
rosemarieB
d1eb87363f
Generic step input from addon descriptor (#3467)
* enhance build step to run based on addon.yml in steampunk environment

Co-authored-by: tiloKo <70266685+tiloKo@users.noreply.github.com>
2022-02-07 20:34:11 +01:00
Oliver Nocon
2ae1d9dac1
feat(kanikoExecute): allow building multiple images (#3443)
* feat(kanikoExecute): allow building multiple images

* enhance tests

* chore: allow running tests in parallel

* small fixes

* fix: fix destination bug

* update formatting and defaults

* fix yml formatting

* chore: change cpe parameter names

* chore: improve variable naming
2022-02-07 07:58:41 +01:00
Christian Volk
ed7323175d
feat(golangBuild): publish to subfolder (#3503)
* feat(golangBuild): publish to subfolder

* edge case handling

* fix
2022-02-04 15:22:57 +01:00
Christian Volk
f432d8455c
fix(golangBuild): targetRepositoryUrl (#3502)
* fix(golangBuild): targetRepositoryUrl

* regen
2022-02-04 12:18:35 +01:00
Oliver Nocon
42b9c2ce48
Revert "fix(golangBuild): keep track of the artifactversion in binary names (#3498)" (#3499)
This reverts commit ec783b0da6.
2022-02-03 11:23:34 +01:00
Anil Keshav
3f3f24cde6
fix (build dependency) typo corrections (#3494)
* typo corrections

* trailing white space

* go generate

Co-authored-by: anilkeshav27 <you@example.com>
2022-02-02 22:37:48 +01:00
Christian Volk
ec783b0da6
fix(golangBuild): keep track of the artifactversion in binary names (#3498)
* fix(golangBuild): keep track of the artifactversion in binary names

* improve the naming scheme
2022-02-02 17:30:56 +01:00
Christian Volk
78dac5973b
feat(golangBuild): add support for publishing binaries (#3495) 2022-02-02 15:44:51 +01:00
Christian Volk
eb0b5c1ffe
fix(kanikoExecute): tmp dir (#3478)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-02 08:04:07 +01:00
Anil Keshav
1546ca293a
feat (Documentation) documentation for mavenBuild and npmExecuteScripts that consume dependencies from a private repo. (#3484)
* build depdency docu for maven and npm

* removing trailing white space in yaml

* Update resources/metadata/mavenBuild.yaml

* relative url for vault and mta docu

* running go generate

* keeping vault relative path

* go generate

* reverting to global paths

* go generate

* wild card for a higher level dir

* searching on top folder only

* relative level above

* pointing to infrastructure

* correcting links

Co-authored-by: anilkeshav27 <you@example.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-02-01 20:32:05 +01:00
Christian Volk
880be73a4c
feat(golangBuild): support private modules (#3471)
* feat(golangBuild): support private module repositories
2022-01-31 10:45:40 +01:00
Eugene Kortelyov
91420e02ff
Update image for gradle build (#3479)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-01-28 15:58:01 +01:00
Eugene Kortelyov
f4db4e7e07
Update gradle version (#3476)
* Update gradle version

* Update generated file
2022-01-27 16:11:51 +01:00
Sven Merk
01c6f1a66c
fix(fortifyExecuteScan): User assignment based on PR ownership (#3472)
* Debug PR user details

* Check association

* Change to login

* Fix PR creator assignment

* Improve docs

* Fix test
2022-01-27 10:45:45 +01:00
Linda Siebert
480d1c260f
Add testing for helm during acceptance stage (#3402)
* Add kubernetesDeploy to Acceptance

* Add more kubernetesDeploy

* Add helm tests

* Change documentation

* Fix docu

* Change generated

* Add tests

* Add groovy tests

* Fix tests

* Change tests

Co-authored-by: Thorsten Duda <thorsten.duda@sap.com>
2022-01-25 10:42:42 +01:00
Anil Keshav
1a96d7a67e
fix (npmExecuteScripts) allow npm pack before npm publish (#3455)
* adding config to piperNpmr

* scope in cli

* adding scope to repo url and npmrc

* publish to scoped

* removing scope

* changing scope position

* adding scope to userconfig

* adding registry=

* pack and then tar

* not removing tmp folder

* adding flag

* pack before publish

* adding log

* debug

* debug with change directory

* publishing created tar ball

* debug

* üath

* adding main npmrc

* renaming old npmrc file

* error renaming old npmrc file

* renaming err

* correcting npmrc file path

* renaming file back to original

* current working directory

* renaming the npmrc file

* avoiding change directory

* with current working dir

* adding dot

* renaming npmrc and defer removal

* rename files

* Update pkg/npm/publish.go

* Update pkg/npm/publish.go

Co-authored-by: anilkeshav27 <you@example.com>
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-01-25 09:52:22 +01:00
Siarhei Pazdniakou
db7d85f3f2
Add gcs upload to uiVeri5ExecuteTests step (#3409)
* Add gcs upload to uiVeri5ExecuteTests step

* go generate

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-01-24 15:18:27 +01:00
Eugene Kortelyov
da450c5243
feat(gradleExecuteBuild): add stage scope to path parameter, fix project dir exist issue (#3401)
* add stage scope to path parameter, fix project dir exist issue

* fix unit test for gradleExecuteBuild

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-01-24 15:08:39 +01:00
Siarhei Pazdniakou
a8ef69bc0f
Add gcs upload to mavenBuild step (#3394)
* Add gcs upload to mavenBuild step

* Patterns were updated

* go generate

* removed patterns related to sapGenerateEnvironmentInfo step

Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2022-01-24 15:00:30 +01:00