Skip to content

Commit

Permalink
chore(dev-flow): maintain latest changes in main branch
Browse files Browse the repository at this point in the history
get rid of the dev branch
eclipse-tractusx/portal#243
  • Loading branch information
evegufy committed Jun 19, 2024
1 parent 57601b2 commit c5e5edd
Show file tree
Hide file tree
Showing 19 changed files with 120 additions and 225 deletions.
3 changes: 0 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ updates:
# NuGet
-
package-ecosystem: "nuget"
target-branch: dev
directory: /
labels:
- "dependabot"
Expand All @@ -42,7 +41,6 @@ updates:
# Github Actions
-
package-ecosystem: "github-actions"
target-branch: dev
directory: /
labels:
- "dependabot"
Expand All @@ -56,7 +54,6 @@ updates:
# Docker
-
package-ecosystem: "docker"
target-branch: dev
directory: ./docker/
labels:
- "dependabot"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/chart-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ on:
push:
paths:
- 'charts/policy-hub/**'
branches: [main, dev, release-candidate]
branches: [main]
pull_request:
paths:
- 'charts/policy-hub/**'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ name: Check Dependencies

on:
push:
branches: [main, dev]
branches: [main]
pull_request:
types: [opened, synchronize, reopened]
workflow_dispatch:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/kics.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ name: "KICS"

on:
push:
branches: [main, dev]
branches: [main]
# pull_request:
# The branches below must be a subset of the branches above
# branches: [main, dev]
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/migrations-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ on:
- 'docker/Dockerfile-policy-hub-migrations'

branches:
- 'dev'
- 'main'
workflow_dispatch:

env:
Expand Down Expand Up @@ -67,7 +67,7 @@ jobs:
with:
images: ${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=dev
type=raw,value=main
type=raw,value=${{ github.sha }}
- name: Build and push Docker image
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/quality-gate-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ jobs:
check-quality:
name: Check quality guidelines
uses: eclipse-tractusx/sig-infra/.github/workflows/reusable-quality-checks.yaml@main
secrets: inherit
secrets: inherit
3 changes: 2 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ on:
paths:
- 'charts/**'
branches:
- main
- 'main'
- 'release/v*.*.*'

jobs:
release-helm-chart:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/service-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ on:
- 'docker/Dockerfile-policy-hub-service'

branches:
- 'dev'
- 'main'
workflow_dispatch:

env:
Expand Down Expand Up @@ -66,7 +66,7 @@ jobs:
with:
images: ${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=dev
type=raw,value=main
type=raw,value=${{ github.sha }}
- name: Build and push Docker image
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
name: Sonarcloud
on:
push:
branches: [main, dev]
branches: [main]
paths:
- 'src/**'
pull_request:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
# Depending on the location of your Docker container
# you need to change the path to the specific Docker registry.
#
name: "Trivy Dev"
name: "Trivy Main"

on:
push:
branches: [ dev ]
branches: [main]
# pull_request:
# The branches below must be a subset of the branches above
# branches: [ main, master ]
Expand All @@ -39,7 +39,6 @@ on:

env:
IMAGE_NAMESPACE: "tractusx"
IMAGE_NAME: "policy-hub"

jobs:
analyze-config:
Expand Down Expand Up @@ -90,16 +89,16 @@ jobs:
uses: aquasecurity/trivy-action@b2933f565dbc598b29947660e66259e3c7bc8561 # v0.20.0
with:
# Path to Docker image
image-ref: "${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}-service:dev"
image-ref: "${{ env.IMAGE_NAMESPACE }}/policy-hub-service:main"
format: "sarif"
output: "trivy-results3.sarif"
output: "trivy-results2.sarif"
vuln-type: "os,library"

- name: Upload Trivy scan results to GitHub Security tab
if: always()
uses: github/codeql-action/upload-sarif@ccf74c947955fd1cf117aef6a0e4e66191ef6f61 # v3.25.4
with:
sarif_file: "trivy-results3.sarif"
sarif_file: "trivy-results2.sarif"

analyze-policy-hub-migrations:
runs-on: ubuntu-latest
Expand All @@ -122,14 +121,14 @@ jobs:
uses: aquasecurity/trivy-action@b2933f565dbc598b29947660e66259e3c7bc8561 # v0.20.0
with:
# Path to Docker image
image-ref: "${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}-migrations:dev"
image-ref: "${{ env.IMAGE_NAMESPACE }}/policy-hub-migrations:main"
format: "sarif"
output: "trivy-results9.sarif"
output: "trivy-results3.sarif"
vuln-type: "os,library"
skip-dirs: "docs/"

- name: Upload Trivy scan results to GitHub Security tab
if: always()
uses: github/codeql-action/upload-sarif@ccf74c947955fd1cf117aef6a0e4e66191ef6f61 # v3.25.4
with:
sarif_file: "trivy-results9.sarif"
sarif_file: "trivy-results3.sarif"
14 changes: 7 additions & 7 deletions .github/workflows/trivy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ name: "Trivy Stable"

on:
push:
branches: [ main ]
branches: [main]
# pull_request:
# The branches below must be a subset of the branches above
# branches: [ main, master ]
Expand Down Expand Up @@ -91,16 +91,16 @@ jobs:
uses: aquasecurity/trivy-action@b2933f565dbc598b29947660e66259e3c7bc8561 # v0.20.0
with:
# Path to Docker image
image-ref: "${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}-service:latest"
image-ref: "${{ env.IMAGE_NAMESPACE }}/policy-hub-service:latest"
format: "sarif"
output: "trivy-results3.sarif"
output: "trivy-results2.sarif"
vuln-type: "os,library"

- name: Upload Trivy scan results to GitHub Security tab
if: always()
uses: github/codeql-action/upload-sarif@ccf74c947955fd1cf117aef6a0e4e66191ef6f61 # v3.25.4
with:
sarif_file: "trivy-results3.sarif"
sarif_file: "trivy-results2.sarif"

analyze-policy-hub-migrations:
runs-on: ubuntu-latest
Expand All @@ -123,13 +123,13 @@ jobs:
uses: aquasecurity/trivy-action@b2933f565dbc598b29947660e66259e3c7bc8561 # v0.20.0
with:
# Path to Docker image
image-ref: "${{ env.IMAGE_NAMESPACE }}/${{ env.IMAGE_NAME }}-migrations:latest"
image-ref: "${{ env.IMAGE_NAMESPACE }}/policy-hub-migrations:latest"
format: "sarif"
output: "trivy-results9.sarif"
output: "trivy-results3.sarif"
vuln-type: "os,library"

- name: Upload Trivy scan results to GitHub Security tab
if: always()
uses: github/codeql-action/upload-sarif@ccf74c947955fd1cf117aef6a0e4e66191ef6f61 # v3.25.4
with:
sarif_file: "trivy-results9.sarif"
sarif_file: "trivy-results3.sarif"
2 changes: 1 addition & 1 deletion .github/workflows/unit.tests-formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ name: Unit-Tests and Formatting

on:
push:
branches: [main, dev]
branches: [main]
paths:
- 'src/**'
pull_request:
Expand Down
2 changes: 1 addition & 1 deletion consortia/argocd-app-templates/appsetup-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ spec:
source:
path: charts/policy-hub
repoURL: 'https://github.com/eclipse-tractusx/policy-hub.git'
targetRevision: dev
targetRevision: main
plugin:
env:
- name: AVP_SECRET
Expand Down
38 changes: 0 additions & 38 deletions consortia/argocd-app-templates/appsetup-upgrade.yaml

This file was deleted.

4 changes: 2 additions & 2 deletions consortia/environments/values-dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,13 @@ keycloak:

service:
image:
tag: "dev"
tag: "main"
imagePullPolicy: "Always"
swaggerEnabled: true

migrations:
image:
tag: "dev"
tag: "main"
imagePullPolicy: "Always"
logging:
default: "Debug"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ flowchart LR
end
subgraph eclipse-tractusx
direction LR
D -- PR* to dev*--> PH(policy-hub**)
D -- PR* to main*--> PH(policy-hub**)
click PH "https://github.com/eclipse-tractusx/policy-hub"
end
subgraph Argo CD - sync to k8s cluster
Expand Down
Loading

0 comments on commit c5e5edd

Please sign in to comment.