Skip to content
This repository has been archived by the owner on Mar 12, 2024. It is now read-only.

Commit

Permalink
springboot
Browse files Browse the repository at this point in the history
  • Loading branch information
adkumar1 committed Mar 7, 2023
1 parent 0c9af87 commit a6a3dbe
Show file tree
Hide file tree
Showing 22 changed files with 65 additions and 100 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/chart-release.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/dapsreg-pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 Catena-X
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand All @@ -18,34 +18,32 @@
# SPDX-License-Identifier: Apache-2.0
################################################################################



name: DapsRegistrationService

# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches:
- main
# trigger events for SemVer like tags
tags:
- 'v*.*.*'
- 'v*.*.*-*'
pull_request:
branches:
- main

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:


env:
# Use GH Container Registry instead of docker
# github.repository equals to <account|org>/<repo>
REGISTRY: ghcr.io
IMAGE_NAME: catenax-ng/tx-daps-registration-service/dapsreg

jobs:
build:
docker:
runs-on: ubuntu-latest
permissions:
packages: write
Expand All @@ -62,9 +60,11 @@ jobs:
images: |
${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=latest,enable={{is_default_branch}}
type=semver,pattern={{version}},value=1.0.5-SNAPSHOT
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}
type=semver,pattern={{major}}.{{minor}}
- name: Log into registry ${{ env.REGISTRY }}
if: github.event_name != 'pull_request'
Expand All @@ -81,4 +81,4 @@ jobs:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}


4 changes: 2 additions & 2 deletions .github/workflows/kics.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 Catena-X
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand All @@ -16,7 +16,7 @@
# under the License.
#
# SPDX-License-Identifier: Apache-2.0
#################################################################################
################################################################################

name: "Trivy"
on:
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/veracode.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down Expand Up @@ -57,4 +57,4 @@ jobs:
filepath: "./target/*.jar"
vid: "${{ secrets.VERACODE_API_ID }}"
vkey: "${{ secrets.VERACODE_API_KEY }}"

13 changes: 8 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

NA

## [2.0.0] - 2023-03-07

### Changed
- upgrade Spring Boot to 3.0.3
- upgrade Snakeyaml to 2.0 as 1.33 has security issue
- New application.properties changes
- sprint boot upgrade, keycloak upgrade


## [1.0.6] - 2023-02-22

Expand All @@ -16,7 +24,6 @@ NA
- Added service port to values.yaml
- Added comments in values.yaml
- Created README.md inside charts/dapsreg-svc/


### Changed
- Upgrade the springboot Library
Expand Down Expand Up @@ -48,7 +55,3 @@ NA

### Removed
- Controller has been removed

### Known knowns
- Cross side scripting (XSS) shall be mitigated (low risk)
- Improving the validation of the input parameters (low risk)
1 change: 1 addition & 0 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ How to install application using helm:-
d.) These secrets should be defined in Hashicorp vault. <br />
e.) Deploy in a kubernetes cluster <br />
helm install daps-reg-svc charts/daps-reg-service/ -n NameSpace <br />
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@ keycloak bearer token and shall have appropriate role to create
records at DAPS side. Therefore, the secrets for admin interface
of the DAPS are not disclosed to the requester.


### Software Version
```shell
Helm version is v1.0.6
Application version is v1.0.5
Helm version is v2.0.0
Application version is v2.0.0
```

# Solution Strategy
Expand Down Expand Up @@ -131,6 +132,7 @@ Please note the name of jar-file as it may differ if version is changed.

## Installation Steps


[INSTALL.md](INSTALL.md)


Expand Down
3 changes: 2 additions & 1 deletion charts/daps-reg-service/.helmignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@
.git/
.gitignore
values?*.yaml
values?*.yml
values?*.yml

9 changes: 5 additions & 4 deletions charts/daps-reg-service/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down Expand Up @@ -38,10 +38,11 @@ sources:
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 1.0.6
version: 2.0.0


# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: 1.0.5
appVersion: 2.0.0
7 changes: 4 additions & 3 deletions charts/daps-reg-service/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# daps-reg-service

![Version: 1.0.6](https://img.shields.io/badge/Version-1.0.6-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.0.5](https://img.shields.io/badge/AppVersion-1.0.5-informational?style=flat-square)
![Version: 2.0.0](https://img.shields.io/badge/Version-2.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.0.0](https://img.shields.io/badge/AppVersion-2.0.0-informational?style=flat-square)

Daps regisgter service is used to register the EDC connector into DAPS

Expand All @@ -21,13 +21,14 @@ Daps regisgter service is used to register the EDC connector into DAPS
| drs.secret.authServerUrl | string | `""` | Auth URL for keycloak |
| drs.secret.clientId | string | `""` | Client id for DAPS |
| drs.secret.clientSecret | string | `""` | Client Secret for DAPS |
| drs.secret.jwkSetUri | string | `""` | JWK Set URI |
| drs.secret.realm | string | `""` | Realm for portal keycloak |
| drs.secret.resource | string | `""` | Resource for portal keycloak |
| drs.secret.tokenUri | string | `""` | DAPS token URL |
| fullnameOverride | string | `""` | |
| image.pullPolicy | string | `"Always"` | Set the Image Pull Policy |
| image.repository | string | `"ghcr.io/catenax-ng/tx-daps-registration-service/dapsreg"` | Image to use for deploying an application |
| image.tag | string | `"1.0.5-SNAPSHOT"` | Image tage is defined in chart appVersion. |
| image.tag | string | `""` | Image tage is defined in chart appVersion. |
| imagePullSecrets | list | `[]` | |
| ingress.annotations."cert-manager.io/cluster-issuer" | string | `"letsencrypt-prod"` | |
| ingress.annotations."nginx.ingress.kubernetes.io/use-regex" | string | `"true"` | |
Expand All @@ -49,7 +50,7 @@ Daps regisgter service is used to register the EDC connector into DAPS
| resources.requests.memory | string | `"300Mi"` | |
| securityContext.allowPrivilegeEscalation | bool | `false` | Controls whether a process can gain more privileges |
| securityContext.capabilities.drop[0] | string | `"ALL"` | |
| service.port | int | `8080` | Port details for sevice |
| service.port | int | `80` | Port details for sevice |
| service.targetPort | int | `8080` | Container Port details for sevice |
| service.type | string | `"ClusterIP"` | Type of service |
| serviceAccount.annotations | object | `{}` | |
Expand Down
2 changes: 1 addition & 1 deletion charts/daps-reg-service/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ spec:
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: 8080
containerPort: {{ .Values.service.targetPort }}
protocol: TCP
env:
- name: APP_DAPS_CLIENTID
Expand Down
5 changes: 3 additions & 2 deletions charts/daps-reg-service/templates/secret.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down Expand Up @@ -32,3 +32,4 @@ stringData:
apiUri: {{ .Values.drs.secret.apiUri | default "https://apiUri" }}
tokenUri: {{ .Values.drs.secret.tokenUri | default "https://tokenUri" }}
jwkSetUri: {{ .Values.drs.secret.jwkSetUri | default "https://jwk-set-uri" }}

4 changes: 2 additions & 2 deletions charts/daps-reg-service/templates/service.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
4 changes: 2 additions & 2 deletions charts/daps-reg-service/templates/serviceaccount.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{{- if .Values.serviceAccount.create -}}

#################################################################################
# Copyright (c) 2021,2022 Catena-X
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 Catena-X
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
4 changes: 2 additions & 2 deletions charts/daps-reg-service/values-beta.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
5 changes: 2 additions & 3 deletions charts/daps-reg-service/values-dev.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down Expand Up @@ -57,4 +57,3 @@ drs:
apiUri: "<path:essential-services/data/daps-register-svc#apiUri>"
tokenUri: "<path:essential-services/data/daps-register-svc#tokenUri>"
jwkSetUri: "<path:essential-services/data/daps-register-svc#jwk-set-uri>"

4 changes: 2 additions & 2 deletions charts/daps-reg-service/values-int.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
4 changes: 2 additions & 2 deletions charts/daps-reg-service/values-pen.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#################################################################################
# Copyright (c) 2021,2022 T-Systems International GmbH
# Copyright (c) 2021,2022 Contributors to the Eclipse Foundation
# Copyright (c) 2022,2023 T-Systems International GmbH
# Copyright (c) 2022,2023 Contributors to the Eclipse Foundation
#
# See the NOTICE file(s) distributed with this work for additional
# information regarding copyright ownership.
Expand Down
45 changes: 0 additions & 45 deletions charts/daps-reg-service/values-test.yaml

This file was deleted.

3 changes: 2 additions & 1 deletion charts/daps-reg-service/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ image:
# -- Set the Image Pull Policy
pullPolicy: Always
# -- Image tage is defined in chart appVersion.
tag: "1.0.5-SNAPSHOT"
tag: ""


imagePullSecrets: []
nameOverride: ""
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</parent>
<groupId>org.eclipse.tractusx</groupId>
<artifactId>dapsreg</artifactId>
<version>1.0.5-SNAPSHOT</version>
<version>2.0.0</version>
<name>dapsreg</name>
<description>client registration to the DAPS</description>
<properties>
Expand Down

0 comments on commit a6a3dbe

Please sign in to comment.