Skip to content
Snippets Groups Projects
Commit 9549ce94 authored by OZGCloud's avatar OZGCloud
Browse files

OZG-6238 merge master

parent 9b11f3ba
No related branches found
No related tags found
1 merge request!1OZG-6238 NPM durch PNPM ersetzen
...@@ -80,25 +80,25 @@ pipeline { ...@@ -80,25 +80,25 @@ pipeline {
FAILED_STAGE=env.STAGE_NAME FAILED_STAGE=env.STAGE_NAME
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
sh 'npm --version' sh 'pnpm --version'
sh 'node --version' sh 'node --version'
dir('alfa-client') { dir('alfa-client') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
if (isMasterBranch()) { if (isMasterBranch()) {
withSonarQubeEnv('sonarqube-ozg-sh'){ withSonarQubeEnv('sonarqube-ozg-sh'){
sh 'npm run ci-sonar' sh 'pnpm run ci-sonar'
} }
} else { } else {
sh 'npm run ci-test' sh 'pnpm run ci-test'
} }
if (isReleaseBranch()) { if (isReleaseBranch()) {
sh 'npm run ci-prodBuild' sh 'pnpm run ci-prodBuild'
} }
else { else {
sh 'npm run ci-build' sh 'pnpm run ci-build'
} }
} }
} }
...@@ -119,7 +119,7 @@ pipeline { ...@@ -119,7 +119,7 @@ pipeline {
IMAGE_TAG = generateImageTag() IMAGE_TAG = generateImageTag()
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
sh 'npm run ci-build-alfa-client-container' sh 'pnpm run ci-build-alfa-client-container'
} }
withCredentials([usernamePassword(credentialsId: 'jenkins-nexus-login', usernameVariable: 'USER', passwordVariable: 'PASSWORD')]) { withCredentials([usernamePassword(credentialsId: 'jenkins-nexus-login', usernameVariable: 'USER', passwordVariable: 'PASSWORD')]) {
......
...@@ -64,20 +64,20 @@ pipeline { ...@@ -64,20 +64,20 @@ pipeline {
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
dir('alfa-client') { dir('alfa-client') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
if (isReleaseBranch()) { if (isReleaseBranch()) {
sh 'npm run ci-prodBuild-admin' sh 'pnpm run ci-prodBuild-admin'
} else { } else {
sh 'npm run ci-build-admin' sh 'pnpm run ci-build-admin'
} }
if (isMasterBranch()) { if (isMasterBranch()) {
withSonarQubeEnv('sonarqube-ozg-sh'){ withSonarQubeEnv('sonarqube-ozg-sh'){
sh 'npm run ci-sonar' sh 'pnpm run ci-sonar'
} }
} else { } else {
sh 'npm run ci-test' sh 'pnpm run ci-test'
} }
} }
} }
......
...@@ -226,11 +226,11 @@ pipeline { ...@@ -226,11 +226,11 @@ pipeline {
FAILED_STAGE = env.STAGE_NAME FAILED_STAGE = env.STAGE_NAME
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
sh 'npm --version' sh 'pnpm --version'
dir('alfa-client') { dir('alfa-client') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
sh "npm run cypress:install" sh "pnpm run cypress:install"
} }
} }
} }
...@@ -726,7 +726,7 @@ String runTests(String bezeichner, String appName, String appVariant, String key ...@@ -726,7 +726,7 @@ String runTests(String bezeichner, String appName, String appVariant, String key
def config = generateCypressConfig(bezeichner, appName, appVariant, keycloakClientName, dbPort) def config = generateCypressConfig(bezeichner, appName, appVariant, keycloakClientName, dbPort)
try { try {
dir('alfa-client'){ dir('alfa-client'){
sh "npm run cypress:version" sh "pnpm run cypress:version"
sh "apps/run-tests.sh ${appName} ${appVariant} ${config}" sh "apps/run-tests.sh ${appName} ${appVariant} ${config}"
} }
} catch (Exception e) { } catch (Exception e) {
...@@ -738,10 +738,10 @@ String runTests(String bezeichner, String appName, String appVariant, String key ...@@ -738,10 +738,10 @@ String runTests(String bezeichner, String appName, String appVariant, String key
Void printNpmDebugLog() { Void printNpmDebugLog() {
if (hasNpmDebugLog()) { if (hasNpmDebugLog()) {
sh "cat /root/.npm/_logs/*-debug.log" sh "cat pnpm-debug.log"
} }
else { else {
echo "Npm debug log not found" echo "pnpm debug log not found"
} }
} }
...@@ -939,7 +939,7 @@ Map getElasticsearchSecret(String namespace) { ...@@ -939,7 +939,7 @@ Map getElasticsearchSecret(String namespace) {
} }
Boolean hasNpmDebugLog() { Boolean hasNpmDebugLog() {
return sh (script: "ls -l /root/.npm/_logs/*-debug.log", returnStatus: true) == env.SH_SUCCESS_STATUS_CODE as Integer return sh (script: "ls -l pnpm-debug.log", returnStatus: true) == env.SH_SUCCESS_STATUS_CODE as Integer
} }
Map getSmockerEnv(String namespace) { Map getSmockerEnv(String namespace) {
......
...@@ -175,11 +175,11 @@ pipeline { ...@@ -175,11 +175,11 @@ pipeline {
FAILED_STAGE = env.STAGE_NAME FAILED_STAGE = env.STAGE_NAME
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
sh 'npm --version' sh 'pnpm --version'
dir('alfa-client') { dir('alfa-client') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
sh "npm run cypress:install" sh "pnpm run cypress:install"
} }
} }
} }
...@@ -356,7 +356,7 @@ String runTests(String bezeichner, String reportFolder, String userFolder, Integ ...@@ -356,7 +356,7 @@ String runTests(String bezeichner, String reportFolder, String userFolder, Integ
try { try {
dir("alfa-client") { dir("alfa-client") {
sh "npm run cypress:version" sh "pnpm run cypress:version"
sh "apps/alfa-e2e/run-tests.sh ${reportFolder} ${config}" sh "apps/alfa-e2e/run-tests.sh ${reportFolder} ${config}"
} }
} catch (Exception e) { } catch (Exception e) {
...@@ -368,10 +368,10 @@ String runTests(String bezeichner, String reportFolder, String userFolder, Integ ...@@ -368,10 +368,10 @@ String runTests(String bezeichner, String reportFolder, String userFolder, Integ
Void printNpmDebugLog() { Void printNpmDebugLog() {
if (hasNpmDebugLog()) { if (hasNpmDebugLog()) {
sh "cat /root/.npm/_logs/*-debug.log" sh "cat pnpm-debug.log"
} }
else { else {
echo 'Npm debug log not found' echo 'pnpm debug log not found'
} }
} }
...@@ -584,5 +584,5 @@ Map getElasticsearchSecret(String namespace) { ...@@ -584,5 +584,5 @@ Map getElasticsearchSecret(String namespace) {
} }
Boolean hasNpmDebugLog() { Boolean hasNpmDebugLog() {
return sh(script: "ls -l /root/.npm/_logs/*-debug.log", returnStatus: true) == env.SH_SUCCESS_STATUS_CODE as Integer return sh(script: "ls -l pnpm-debug.log", returnStatus: true) == env.SH_SUCCESS_STATUS_CODE as Integer
} }
\ No newline at end of file
...@@ -64,9 +64,9 @@ pipeline { ...@@ -64,9 +64,9 @@ pipeline {
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
dir('alfa-client') { dir('alfa-client') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
sh 'npm run ci-storybook' sh 'pnpm run ci-storybook'
} }
} }
} }
......
...@@ -36,8 +36,8 @@ pipeline { ...@@ -36,8 +36,8 @@ pipeline {
FAILED_STAGE = env.STAGE_NAME FAILED_STAGE = env.STAGE_NAME
dir('alfa-client') { dir('alfa-client') {
withNPM(npmrcConfig: 'npm-nexus-auth') { withNPM(npmrcConfig: 'npm-nexus-auth') {
sh 'npm cache verify' sh 'pnpm cache verify'
sh 'npm install' sh 'pnpm install'
sh 'npx nx run info:test' sh 'npx nx run info:test'
sh 'npx nx run info:test -- --runInBand --codeCoverage --coverageReporters=lcov --testResultsProcessor=jest-sonar-reporter && npx sonar-scanner' sh 'npx nx run info:test -- --runInBand --codeCoverage --coverageReporters=lcov --testResultsProcessor=jest-sonar-reporter && npx sonar-scanner'
......
This diff is collapsed.
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
<phase>test</phase> <phase>test</phase>
<configuration> <configuration>
<workingDirectory>./</workingDirectory> <workingDirectory>./</workingDirectory>
<executable>npm</executable> <executable>pnpm</executable>
<arguments> <arguments>
<argument>run</argument> <argument>run</argument>
<argument>test</argument> <argument>test</argument>
...@@ -81,7 +81,7 @@ ...@@ -81,7 +81,7 @@
<phase>compile</phase> <phase>compile</phase>
<configuration> <configuration>
<workingDirectory>./</workingDirectory> <workingDirectory>./</workingDirectory>
<executable>npm</executable> <executable>pnpm</executable>
<arguments> <arguments>
<argument>run</argument> <argument>run</argument>
<argument>ci-build</argument> <argument>ci-build</argument>
...@@ -116,7 +116,7 @@ ...@@ -116,7 +116,7 @@
<phase>generate-sources</phase> <phase>generate-sources</phase>
<configuration> <configuration>
<workingDirectory>./</workingDirectory> <workingDirectory>./</workingDirectory>
<executable>npm</executable> <executable>pnpm</executable>
<arguments> <arguments>
<argument>install</argument> <argument>install</argument>
</arguments> </arguments>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment