Skip to content

Commit 61bf950

Browse files
kartik-579prakash100198RajeevRanjan27prkhrkatashokdevtron
authored
chore: Main develop sync bd5118 (#5817)
* migration number changes (#5692) * refrain from checkin autoscalingCheckBeforeTrigger for virt clus (#5696) * fix: Decode secret fix on add update oss (#5695) * ValidateEncodedDataByDecoding in case add or update secret * wire fix from main * minor refactor * comment * saving pco concurrency case handled (#5688) * fix: script for pipelineStageStepVariable, making input value and default_value text from varchar255 (#5701) * script for pipelineStageStepVariable, making input value and default_value text from varchar255 * erro log fix * fix: ea fixes for helm app (#5708) * added the ea apps entry app table * resolved the ea mode multiple rows error during configuration of app * modified the ea dockerfile in ca-certificates cmd * uncommented the code and left the ea helm app making way untouched * remodified the dockerfile as previous state * modified the docker file ea mode * dockerfile exit code 100 due to ap install alternative in ea mode dockerfile * execute make after main merge * modified changes in dockerfile ea mode * resolved comments after first level review * Revert "fix: ea fixes for helm app (#5708)" (#5713) This reverts commit 3e31f49. * fix: SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation (#5712) * SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation * minor refactor * minor refactor * migration syn with ent (#5718) * doc: Edit Deployment Chart Schema (#5735) * Edit Deployment Chart Schema * Fixes * PM + CO Feedback Incorporated * doc: Redirection of old entry in gitbook.yaml (#5738) * Edit Deployment Chart Schema * Fixes * PM + CO Feedback Incorporated * Redirected Old Entry * docs: added Documentation for Air-Gapped Installation (#5360) * added docs for air-gapped-installation * added all the images in 7.0.0 * modified yq command in the docs * added an entry in summary.md * added installation commands * modified statements * modified variable name * added steps to navigation * added the latest oss chart images * added a note for docker * Added Intro + Proofreading + Structuring * Other fixes * Lang fix * added docs for ea-mode only * modified lang * Update install-devtron-in-airgapped-environment.md Changed h3 header to fit the ToC on the RHS * added changes * modified changes --------- Co-authored-by: Badal Kumar Prusty <[email protected]> Co-authored-by: ashokdevtron <[email protected]> * feat: Env description handling (#5744) * env description handling added * license handling * misc: Main sync rc - branch update (#5753) * added config sql script (#5681) * feat: CVE severity categorisation and scan result listing API enhancements (#5617) * feat: add support for app and env sorting in scan list api and add medium, high and unknown severity support * fix: query fix for appName sort or envName sort * fix: sql script number change * fix: minor changes * fix: review fix * fix: remove dml on cve_store and handle it in code handling this versioning * fix: review comments * fix: update script numbers * fix: minor fix * feat: casbin deny policy sql scripts (#5677) * system controller scripts * script additions * sql cript update * sql script number chnage * feat: Config diff phase 2 oss (#5488) * story(configDiffView) : open api spec * story(configDiffView) : open api spec updated * story(configDiffView) : open api spec updated for error state * story(configDiffView) : WIP * story(configDiffView) : WIP "some code changed" * story(configDiffView) : support for names added * story(configDiffView) : iota removed * story(configDiffView) : pg no rows handled * story(configDiffView) : spelling check * story(configDiffView) : code review comment resolved * story(configDiffView) : env id added * story(configDiffView) : intersection added * story(configDiffView) : comments removed * story(configDiffView) : code review comment resolved * story(configDiffView) : comment removed * story(configDiffView) : CMCSNames DTO moved * story(configDiffView) : null case handled * story(configDiffView) : logger added * story(configDiffView) : code refactored * story(configDiffView) : code refactored v2 * story(configDiffView) : spec updated * story(configDiffView) : code refactored * story(configDiffView) : config names * main sync * overridden and global flag introduced in config diff autocomplete api * ent sync * get config data in resthandler * new api for showing all config data in config/data :- Service func -> GetAllConfigData * using a single key instead of global and overridden key in config/autocomplete api * ConfigState made string instead of int * not sending inheriting in case base config * code review comment incorporation * ent sync * code review comment incorp -1 * code review comment incorp -2 * code review comment incorp -3 * small fix in plugin * migration number changes (#5692) * main sync * minor fix * refrain from checkin autoscalingCheckBeforeTrigger for virt clus (#5696) * fix: Decode secret fix on add update oss (#5695) * ValidateEncodedDataByDecoding in case add or update secret * wire fix from main * minor refactor * comment * saving pco concurrency case handled (#5688) * fix: script for pipelineStageStepVariable, making input value and default_value text from varchar255 (#5701) * script for pipelineStageStepVariable, making input value and default_value text from varchar255 * erro log fix * scipt number change --------- Co-authored-by: adi6859 <[email protected]> Co-authored-by: Vikram Singh <[email protected]> * fix: Helm apps entries in Ea mode (#5652) * added the ea apps entry app table * resolved the ea mode multiple rows error during configuration of app * modified the ea dockerfile in ca-certificates cmd * uncommented the code and left the ea helm app making way untouched * remodified the dockerfile as previous state * modified the docker file ea mode * dockerfile exit code 100 due to ap install alternative in ea mode dockerfile * execute make after main merge * modified changes in dockerfile ea mode * resolved comments after first level review * executed make after merging with develop branch * feat: refactoring deployment app name usage (#5702) * removing hard coded deployment app name * removing %s-%s usage * wip: query change for enterprise * wip * wip * wip * adding release mode in deployment config * wip: release changes * left join on pco and artifact * handling empty release mode - backward compatibility * fixing panic * migration number changes (#5692) * refrain from checkin autoscalingCheckBeforeTrigger for virt clus (#5696) * fix: Decode secret fix on add update oss (#5695) * ValidateEncodedDataByDecoding in case add or update secret * wire fix from main * minor refactor * comment * saving pco concurrency case handled (#5688) * migration updated * main merge and migration script updated * wip * review changes * fix sql no --------- Co-authored-by: Prakash <[email protected]> * migration syn with ent (#5719) * fix: group image vulnerabilities by base/os image (#5680) * feat: add support for app and env sorting in scan list api and add medium, high and unknown severity support * fix: query fix for appName sort or envName sort * fix: sql script number change * fix: minor changes * fix: review fix * fix: remove dml on cve_store and handle it in code handling this versioning * fix: review comments * feat: storing target,class and type values in imageScanExecutionResults * feat: add sql script * feat: add sql script * fix: add new columns * fix: update script numbers * fix: correct down script * fix: minor fix * chore: script number update * fix: remove sql script (#5727) * Revert "fix: Helm apps entries in Ea mode (#5652)" (#5733) This reverts commit f1aa1fc. * chore: custom argo-workflow dependency (#5731) * bumped github.com/argoproj/argo-workflows/v3 v3.5.10 => github.com/devtron-labs/argo-workflows/v3 v3.5.10 * migration number changes (#5692) * refrain from checkin autoscalingCheckBeforeTrigger for virt clus (#5696) * fix: Decode secret fix on add update oss (#5695) * ValidateEncodedDataByDecoding in case add or update secret * wire fix from main * minor refactor * comment * saving pco concurrency case handled (#5688) * fix: script for pipelineStageStepVariable, making input value and default_value text from varchar255 (#5701) * script for pipelineStageStepVariable, making input value and default_value text from varchar255 * erro log fix * fix: ea fixes for helm app (#5708) * added the ea apps entry app table * resolved the ea mode multiple rows error during configuration of app * modified the ea dockerfile in ca-certificates cmd * uncommented the code and left the ea helm app making way untouched * remodified the dockerfile as previous state * modified the docker file ea mode * dockerfile exit code 100 due to ap install alternative in ea mode dockerfile * execute make after main merge * modified changes in dockerfile ea mode * resolved comments after first level review * Revert "fix: ea fixes for helm app (#5708)" (#5713) This reverts commit 3e31f49. * fix: SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation (#5712) * SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation * minor refactor * minor refactor * migration syn with ent (#5718) * reverted main branch changes * reverted main branch changes --------- Co-authored-by: Prakash <[email protected]> Co-authored-by: Rajeev Ranjan <[email protected]> Co-authored-by: prakhar katiyar <[email protected]> * chore: fix go.sum file (#5734) * misc: Main sync develop (#5737) * migration number changes (#5692) * refrain from checkin autoscalingCheckBeforeTrigger for virt clus (#5696) * fix: Decode secret fix on add update oss (#5695) * ValidateEncodedDataByDecoding in case add or update secret * wire fix from main * minor refactor * comment * saving pco concurrency case handled (#5688) * fix: script for pipelineStageStepVariable, making input value and default_value text from varchar255 (#5701) * script for pipelineStageStepVariable, making input value and default_value text from varchar255 * erro log fix * fix: ea fixes for helm app (#5708) * added the ea apps entry app table * resolved the ea mode multiple rows error during configuration of app * modified the ea dockerfile in ca-certificates cmd * uncommented the code and left the ea helm app making way untouched * remodified the dockerfile as previous state * modified the docker file ea mode * dockerfile exit code 100 due to ap install alternative in ea mode dockerfile * execute make after main merge * modified changes in dockerfile ea mode * resolved comments after first level review * Revert "fix: ea fixes for helm app (#5708)" (#5713) This reverts commit 3e31f49. * fix: SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation (#5712) * SkipCiBuildCachePushPull code incorporated with minor refac in handle runtime params validation * minor refactor * minor refactor * migration syn with ent (#5718) --------- Co-authored-by: Prakash <[email protected]> Co-authored-by: Rajeev Ranjan <[email protected]> Co-authored-by: prakhar katiyar <[email protected]> * fix: Validate config cm cs (#5750) * validateConfigRequest before CMGlobalAddUpdate and CSGlobalAddUpdate * checkIfConfigDataAlreadyExist --------- Co-authored-by: ayu-devtron <[email protected]> Co-authored-by: Vikram Singh <[email protected]> Co-authored-by: Gireesh Naidu <[email protected]> Co-authored-by: Shivam Nagar <[email protected]> Co-authored-by: Prakash <[email protected]> Co-authored-by: adi6859 <[email protected]> Co-authored-by: Rajeev Ranjan <[email protected]> Co-authored-by: iamayushm <[email protected]> Co-authored-by: prakhar katiyar <[email protected]> Co-authored-by: Asutosh Das <[email protected]> Co-authored-by: Vikram <[email protected]> Co-authored-by: Prakarsh <[email protected]> * doc: Update prerequisites of code-scan (#5625) * Update prerequisites of code-scan * Hyperlinked the Vulnerability scanning doc --------- Co-authored-by: ashokdevtron <[email protected]> * fix: ci patch rbac for branch update (#5759) * feat: Added basic auth support for servicemonitor (#5761) * Added support for basic auth in servicemonitor * Added support for namespace selector and custom matchLabels * Fixed indentations * fix: Bitnami chart repo tls issue (#5740) * bitnami_chart_fix * Rename 278_bitnami_chart_fix.down.sql to 282_bitnami_chart_fix.down.sql * Rename 278_bitnami_chart_fix.up.sql to 282_bitnami_chart_fix.up.sql --------- Co-authored-by: Pawan Mehta <[email protected]> * doc: Cosign plugin doc (#5665) * doc for cosign plugin * edits in task name * updates in intro and other fixes. * Attached link to Cosign GitHub repo * Hyperlink fixes --------- Co-authored-by: ashokdevtron <[email protected]> * fix: check rbac on env if envName is present (#5765) * admin check fix in config draft * minor fix * doc: CraneCopy plugin doc (#5658) * doc for * edits in task name * spelling correction * Updated password --------- Co-authored-by: ashokdevtron <[email protected]> * doc: Devtron CD Trigger Plugin doc (#5747) * devtron-cd-trigger plugin doc * minor update * Proofreading done * Update devtron-cd-trigger.md * Removed unwanted phrase * Changed wording * Changed plurality * Updated devtron token --------- Co-authored-by: ashokdevtron <[email protected]> * doc: DockerSlim plugin doc (#5660) * doc for DockerSlim plugin * Updated Docker-Slim to DockerSlim * Minor fixes * url update * Fixes in url --------- Co-authored-by: ashokdevtron <[email protected]> * doc: Devtron Job Trigger Plugin doc (#5742) * devtron-job-trigger plugin doc * summary updated * Updated input variable description * token value updated --------- Co-authored-by: ashokdevtron <[email protected]> * fix: scan tool active check removed (#5771) * scan tool active check removed * query fix * feat: Docker pull env driven (#5767) * useDockerApiToGetDigest menv driven flag to control pulling image either using docker pull or docker API * UseAppDockerConfigForPrivateRegistries in workflow request * revert * revert * fix: panic handlings and argocd app delete stuck in partial stage (#5770) * fix: panic handlings * fix: false positive matrics on gitOps failures * fix: for GetConfigForHelmApps err: pg no row * feat: plugin creation support (#5630) * wip: new plugin creation api and min plugin api with only shared plugin list * wip: create new plugin version code * wip:plugin type SHARED by default * wip:find plugin either by identifier or by id while creating a new version of existing plugin * wip: create new plugin tag logic improved * wip: optimize GetAllFilteredPluginParentMetadata query * wip: create plugin tag new flow * wip: minor fix * wip: minor fix * wip: minor fix * wip: newTagsPresent -> areNewTagsPresent * wip: icon is not mandatory code incorporated * wip:minor refactoring * wip: prevent duplicate version from being created and save tags relation only when * wip: minor fix * wip: details api, get all plugin data or non * wip: code review incorp part -1 * wip: code review incorp part -2 * wip: code review incorp part -3 * wip: remove code duplication * wip: hardcode isExposed to true * wip: hardcode StepType= inline * wip: set default VariableStepIndex= 1 * Revert "feat: plugin creation support (#5630)" (#5778) This reverts commit 4296366. * fix: unimplemented cluster cron service (#5781) * fix: sql injection fixes (#5783) * sql injection fixes * query param init fix * doc: Vulnerability Scanning Plugin doc (#5722) * vulnerability scanning plugin doc * summary.md added * docs: Jira plugins doc (Validator + Updater) (#5709) * Docs of Jira Plugins - Validator and Updater * Added Index Links * Additional Proofreading * add basic auth and tls for sm (#5789) * docs: added commands enable ingress during helm installation (#5794) * added commands emable ingress during helm installation * modified commands * improved statement * removed unrequired lines --------- Co-authored-by: Badal Kumar Prusty <[email protected]> * Revamped + Restructured Ingress Setup Doc (#5798) * modifying route (#5799) Co-authored-by: Badal Kumar Prusty <[email protected]> * fix: cron status update refactoring (#5790) Co-authored-by: Nishant <[email protected]> * docs: modified the anchorlink in ingress.md (#5800) * modifying route * modified the anchorlink --------- Co-authored-by: Badal Kumar Prusty <[email protected]> * query param split (#5801) * fix: upgraded to /argo-cd/v2 v2.9.21 (#5758) * upgraded to /argo-cd/v2 v2.9.21 * argocd vendor files added * sync with common-lib * fix: Ea rbac fixes (#5813) * app found using display or app name * single query optimization * display name handling for new apps --------- Co-authored-by: kartik-579 <[email protected]> --------- Co-authored-by: Prakash <[email protected]> Co-authored-by: Rajeev Ranjan <[email protected]> Co-authored-by: prakhar katiyar <[email protected]> Co-authored-by: ashokdevtron <[email protected]> Co-authored-by: Badal Kumar <[email protected]> Co-authored-by: Badal Kumar Prusty <[email protected]> Co-authored-by: kripanshdevtron <[email protected]> Co-authored-by: ayu-devtron <[email protected]> Co-authored-by: Vikram Singh <[email protected]> Co-authored-by: Gireesh Naidu <[email protected]> Co-authored-by: Shivam Nagar <[email protected]> Co-authored-by: adi6859 <[email protected]> Co-authored-by: iamayushm <[email protected]> Co-authored-by: Asutosh Das <[email protected]> Co-authored-by: Vikram <[email protected]> Co-authored-by: Prakarsh <[email protected]> Co-authored-by: Bhushan Nemade <[email protected]> Co-authored-by: Pawan Mehta <[email protected]> Co-authored-by: akshatsinha007 <[email protected]> Co-authored-by: Nishant <[email protected]>
1 parent c0dc007 commit 61bf950

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+2903
-262
lines changed

api/cluster/EnvironmentRestHandler.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import (
2323
"net/http"
2424
"strconv"
2525
"strings"
26+
"sync"
2627
"time"
2728

2829
k8s2 "github.com/devtron-labs/common-lib/utils/k8s"
@@ -513,9 +514,8 @@ func (impl EnvironmentRestHandlerImpl) GetEnvironmentConnection(w http.ResponseW
513514
responseObj.ClusterReachable = false
514515
}
515516
//updating the cluster connection error to db
516-
mapObj := map[int]error{
517-
clusterBean.Id: err,
518-
}
517+
mapObj := &sync.Map{}
518+
mapObj.Store(clusterBean.Id, err)
519519
impl.environmentClusterMappingsService.HandleErrorInClusterConnections([]*request.ClusterBean{clusterBean}, mapObj, true)
520520
common.WriteJsonResp(w, nil, responseObj, http.StatusOK)
521521
}

api/cluster/wire_cluster.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ import (
2929
var ClusterWireSet = wire.NewSet(
3030
repository.NewClusterRepositoryImpl,
3131
wire.Bind(new(repository.ClusterRepository), new(*repository.ClusterRepositoryImpl)),
32+
cluster.NewClusterServiceImpl,
3233
cluster.NewClusterServiceImplExtended,
3334
wire.Bind(new(cluster.ClusterService), new(*cluster.ClusterServiceImplExtended)),
3435

api/k8s/application/k8sApplicationRestHandler.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -559,6 +559,7 @@ func (handler *K8sApplicationRestHandlerImpl) GetPodLogs(w http.ResponseWriter,
559559
common.WriteJsonResp(w, err, nil, http.StatusBadRequest)
560560
return
561561
}
562+
handler.logger.Infow("get pod logs request", "request", request)
562563
handler.requestValidationAndRBAC(w, r, token, request)
563564
lastEventId := r.Header.Get(bean2.LastEventID)
564565
isReconnect := false

api/k8s/wire_k8sApp.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,4 @@ var K8sApplicationWireSet = wire.NewSet(
5353
informer.NewGlobalMapClusterNamespace,
5454
informer.NewK8sInformerFactoryImpl,
5555
wire.Bind(new(informer.K8sInformerFactory), new(*informer.K8sInformerFactoryImpl)),
56-
57-
cluster.NewClusterCronServiceImpl,
58-
wire.Bind(new(cluster.ClusterCronService), new(*cluster.ClusterCronServiceImpl)),
5956
)

cmd/external-app/wire_gen.go

Lines changed: 6 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/SUMMARY.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,11 +146,14 @@
146146
* [DockerSlim](user-guide/plugins/docker-slim.md)
147147
* [GoLang-migrate](user-guide/plugins/golang-migrate.md)
148148
* [Jenkins](user-guide/plugins/jenkins.md)
149+
* [Jira Issue Validator](user-guide/plugins/jira-validator.md)
150+
* [Jira Issue Updater](user-guide/plugins/jira-updater.md)
149151
* [K6 Load Testing](user-guide/plugins/k6-load-testing.md)
150152
* [Pull images from container repository](user-guide/plugins/pull-images-from-container-repository.md)
151153
* [Semgrep](user-guide/plugins/semgrep.md)
152154
* [SonarQube](user-guide/plugins/sonarqube.md)
153155
* [SonarQube v1.1.0](user-guide/plugins/sonarqube-v1.1.0.md)
156+
* [Vulnerability Scanning](user-guide/plugins/vulnerability-scanning.md)
154157

155158

156159
## Resources

docs/setup/install/ingress-setup.md

Lines changed: 140 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,144 @@
11
# Ingress Setup
22

3-
After Devtron is installed, Devtron is accessible through service `devtron-service`.
4-
If you want to access Devtron through ingress, edit `devtron-service` and change the loadbalancer to ClusterIP. You can do this using `kubectl patch` command:
3+
## Introduction
4+
5+
If you wish to use [Ingress](https://kubernetes.io/docs/concepts/services-networking/ingress/) as a means to access the Devtron services available in your cluster, you can configure it either during the installation or after the installation of Devtron.
6+
7+
Refer the section relevant to you:
8+
* [During Devtron Installation](#enabling-ingress-during-devtron-installation)
9+
* [After Devtron Installation](#configuring-ingress-after-devtron-installation)
10+
11+
If you have successfully configured Ingress, refer [Post Ingress Setup](#enable-https-for-devtron).
12+
13+
---
14+
15+
## Enabling Ingress during Devtron Installation
16+
17+
If you are installing Devtron, you can enable Ingress either via [set flag](#using-set-flag) or by using [ingress-values.yaml](#using-ingress-values.yaml) to specify the desired Ingress settings.
18+
19+
### Using set flag
20+
21+
You can use the `--set` flag to specify the desired Ingress settings.
22+
23+
Here, we have added 5 configurations you can perform depending on your requirements:
24+
* [Only Basic Configuration](#only-basic-configuration)
25+
* [Configuration Including Labels](#configuration-including-labels)
26+
* [Configuration Including Annotations](#configuration-including-annotations)
27+
* [Configuration Including TLS Settings](#configuration-including-tls-settings)
28+
* [Comprehensive Configuration](#comprehensive-configuration)
29+
30+
#### Only Basic Configuration
31+
32+
To enable Ingress and set basic parameters, use the following command:
33+
34+
```bash
35+
helm install devtron devtron/devtron-operator -n devtroncd \
36+
--set components.devtron.ingress.enabled=true \
37+
--set components.devtron.ingress.className=nginx \
38+
--set components.devtron.ingress.host=devtron.example.com
39+
```
40+
41+
#### Configuration Including Labels
42+
43+
To add labels to the Ingress resource, use the following command:
44+
45+
```bash
46+
helm install devtron devtron/devtron-operator -n devtroncd \
47+
--set components.devtron.ingress.enabled=true \
48+
--set components.devtron.ingress.className=nginx \
49+
--set components.devtron.ingress.host=devtron.example.com \
50+
--set components.devtron.ingress.labels.env=production
51+
```
52+
53+
#### Configuration Including Annotations
54+
55+
To add annotations to the Ingress resource, use the following command:
56+
57+
```bash
58+
helm install devtron devtron/devtron-operator -n devtroncd \
59+
--set components.devtron.ingress.enabled=true \
60+
--set components.devtron.ingress.className=nginx \
61+
--set components.devtron.ingress.host=devtron.example.com \
62+
--set components.devtron.ingress.annotations."kubernetes\.io/ingress\.class"=nginx \
63+
--set components.devtron.ingress.annotations."nginx\.ingress\.kubernetes\.io\/app-root"="/dashboard"
64+
```
65+
66+
#### Configuration Including TLS Settings
67+
68+
To configure TLS settings, including `secretName` and `hosts`, use the following command:
69+
70+
```bash
71+
helm install devtron devtron/devtron-operator -n devtroncd \
72+
--set components.devtron.ingress.enabled=true \
73+
--set components.devtron.ingress.className=nginx \
74+
--set components.devtron.ingress.host=devtron.example.com \
75+
--set components.devtron.ingress.tls[0].secretName=devtron-tls \
76+
--set components.devtron.ingress.tls[0].hosts[0]=devtron.example.com
77+
```
78+
79+
#### Comprehensive Configuration
80+
81+
To include all the above settings in a single command, use:
82+
83+
```bash
84+
helm install devtron devtron/devtron-operator -n devtroncd \
85+
--set components.devtron.ingress.enabled=true \
86+
--set components.devtron.ingress.className=nginx \
87+
--set components.devtron.ingress.host=devtron.example.com \
88+
--set components.devtron.ingress.annotations."kubernetes\.io/ingress\.class"=nginx \
89+
--set components.devtron.ingress.annotations."nginx\.ingress\.kubernetes\.io\/app-root"="/dashboard" \
90+
--set components.devtron.ingress.labels.env=production \
91+
--set components.devtron.ingress.pathType=ImplementationSpecific \
92+
--set components.devtron.ingress.tls[0].secretName=devtron-tls \
93+
--set components.devtron.ingress.tls[0].hosts[0]=devtron.example.com
94+
```
95+
96+
97+
### Using ingress-values.yaml
98+
99+
As an alternative to the [set flag](#using-set-flag) method, you can enable Ingress using `ingress-values.yaml` instead.
100+
101+
Create an `ingress-values.yaml` file. You may refer the below format for an advanced ingress configuration which includes labels, annotations, secrets, and many more.
102+
103+
```yml
104+
components:
105+
devtron:
106+
ingress:
107+
enabled: true
108+
className: nginx
109+
labels: {}
110+
# env: production
111+
annotations: {}
112+
# nginx.ingress.kubernetes.io/app-root: /dashboard
113+
pathType: ImplementationSpecific
114+
host: devtron.example.com
115+
tls: []
116+
# - secretName: devtron-info-tls
117+
# hosts:
118+
# - devtron.example.com
119+
```
120+
121+
Once you have the `ingress-values.yaml` file ready, run the following command:
122+
123+
```bash
124+
helm install devtron devtron/devtron-operator -n devtroncd --reuse-values -f ingress-values.yaml
125+
```
126+
127+
---
128+
129+
## Configuring Ingress after Devtron Installation
130+
131+
After Devtron is installed, Devtron is accessible through `devtron-service`. If you wish to access Devtron through ingress, you'll need to modify this service to use a ClusterIP instead of a LoadBalancer.
132+
133+
You can do this using the `kubectl patch` command:
5134

6135
```bash
7136
kubectl patch -n devtroncd svc devtron-service -p '{"spec": {"ports": [{"port": 80,"targetPort": "devtron","protocol": "TCP","name": "devtron"}],"type": "ClusterIP","selector": {"app": "devtron"}}}'
8137
```
9138

10-
After this, create ingress by applying the ingress yaml file.
11-
You can use [this yaml file](https://github.com/devtron-labs/devtron/blob/main/manifests/yamls/devtron-ingress.yaml) to create ingress to access Devtron:
139+
Next, create ingress to access Devtron by applying the `devtron-ingress.yaml` file. The file is also available on this [link](https://github.com/devtron-labs/devtron/blob/main/manifests/yamls/devtron-ingress.yaml). You can access Devtron from any host after applying this yaml.
12140

13-
```yaml
141+
```yml
14142
apiVersion: networking.k8s.io/v1
15143
kind: Ingress
16144
metadata:
@@ -49,9 +177,9 @@ spec:
49177
pathType: ImplementationSpecific
50178
```
51179
52-
You can access Devtron from any host after applying this yaml. For k8s versions <1.19, [apply this yaml](https://github.com/devtron-labs/devtron/blob/main/manifests/yamls/devtron-ingress-legacy.yaml):
180+
For k8s versions < 1.19, [apply this yaml](https://github.com/devtron-labs/devtron/blob/main/manifests/yamls/devtron-ingress-legacy.yaml):
53181
54-
```yaml
182+
```yml
55183
apiVersion: extensions/v1beta1
56184
kind: Ingress
57185
metadata:
@@ -79,7 +207,7 @@ spec:
79207
80208
Optionally, you also can access Devtron through a specific host by running the following YAML file:
81209
82-
```yaml
210+
```yml
83211
apiVersion: networking.k8s.io/v1
84212
kind: Ingress
85213
metadata:
@@ -119,9 +247,11 @@ spec:
119247
pathType: ImplementationSpecific
120248
```
121249
250+
---
251+
122252
## Enable HTTPS For Devtron
123253
124-
Once ingress setup for devtron is done and you want to run Devtron over `https`, you need to add different annotations for different ingress controllers and load balancers.
254+
Once Ingress setup for Devtron is done and you want to run Devtron over `https`, you need to add different annotations for different ingress controllers and load balancers.
125255

126256
### 1. Nginx Ingress Controller
127257

@@ -175,7 +305,4 @@ In case of AWS application load balancer, the following annotations need to be a
175305
```
176306
For an Ingress resource to be observed by AGIC (Application Gateway Ingress Controller) must be annotated with kubernetes.io/ingress.class: azure/application-gateway. Only then AGIC will work with the Ingress resource in question.
177307

178-
> Note: Make sure NOT to use port 80 with HTTPS and port 443 with HTTP on the Pods.
179-
180-
181-
308+
> Note: Make sure NOT to use port 80 with HTTPS and port 443 with HTTP on the Pods.
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
# Jira Issue Updater
2+
3+
## Introduction
4+
The Jira Issue Updater plugin extends the capabilities of Devtron CI by allowing updates to Jira issues directly from the pipeline. It can add build pipeline status and docker image ID as a comment on Jira tickets, keeping the issue tracking synchronized with your CI processes.
5+
6+
### Prerequisites
7+
8+
- A Jira account with the necessary [API access](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/#Create-an-API-token).
9+
- The API credentials (username, password, and base URL) for your Jira instance. Obtain the API credentials from your Jira admin if required.
10+
- A pull request raised with your Git provider. Title of pull request must contain the Jira ID.
11+
- Jira Issue (e.g., REDOC-12)
12+
- Webhook added to the git repository. [Click here](https://docs.devtron.ai/usage/applications/creating-application/workflow/ci-pipeline#configuring-webhook) to know more.
13+
14+
---
15+
16+
## Steps
17+
18+
1. On the **Edit build pipeline** page, go to the **Post-Build Stage**.
19+
2. Click **+ Add task**.
20+
3. Select **Jira Issue Updater** from the list of plugins.
21+
* Enter a task name (mandatory).
22+
* Optionally, enter a description.
23+
* Provide values for the input variables.
24+
25+
| Variable | Format | Description |
26+
| ------------------------ | ------ | --------------------------------------------------------- |
27+
| JiraUsername | String | Your Jira username (e.g., [email protected]) |
28+
| JiraPassword | String | Your Jira API token provided by the Jira admin |
29+
| JiraBaseUrl | String | The base URL of your Jira instance (e.g., https://yourdomain.atlassian.net/) |
30+
| UpdateWithDockerImageId | Bool | Set to `true` to include the Docker Image ID in the update |
31+
| UpdateWithBuildStatus | Bool | Set to `true` to include the build status in the update |
32+
33+
* `Trigger/Skip Condition` allows you to set conditions under which this task will execute or be skipped.
34+
* `Pass/Failure Condition` allows you define conditions to determine if the build passes or fails based on the Jira update.
35+
36+
4. Go to the **Build Stage**.
37+
38+
5. Select **Pull Request** in the **Source Type** dropdown.
39+
40+
6. Use filters to fetch only the PRs matching your regex. Here are few examples:
41+
* **Title** can be a regex pattern (e.g., `^(?P<jira_Id>([a-zA-Z0-9-].*))`) to extract the Jira ID from the PR title. Only those PRs fulfilling the regex will be shown for image build process.
42+
* **State** can be `^open$`, where only PRs in open state will be shown for image build process.
43+
44+
7. Click **Update Pipeline**.
45+
46+
---
47+
48+
## Results
49+
50+
![Figure 1: Build Log](https://devtron-public-asset.s3.us-east-2.amazonaws.com/images/plugins/jira/jira-updater-log.jpg)
51+
52+
![Figure 2: Comments added by the Plugin on the Jira Issue](https://devtron-public-asset.s3.us-east-2.amazonaws.com/images/plugins/jira/jira-updater.jpg)
53+
54+
55+
56+
57+
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# Jira Issue Validator
2+
3+
## Introduction
4+
The Jira Issue Validator plugin extends the filtering capabilities of the Devtron CI and lets users perform validation based on Jira Ticket ID status. This plugin ensures that only builds associated with valid Jira tickets are executed, improving the accuracy of the CI process.
5+
6+
### Prerequisites
7+
8+
- A Jira account with the necessary [API access](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/#Create-an-API-token).
9+
- The API credentials (username, password, and base URL) for your Jira instance. Obtain the API credentials from your Jira admin if required.
10+
- A pull request raised with your Git provider. Title of pull request must contain the Jira ID.
11+
- Jira Issue (e.g., REDOC-12)
12+
- Webhook added to the git repository. [Click here](https://docs.devtron.ai/usage/applications/creating-application/workflow/ci-pipeline#configuring-webhook) to know more.
13+
14+
---
15+
16+
## Steps
17+
18+
1. On the **Edit build pipeline** page, go to the **Pre-Build Stage** (or Post-Build Stage).
19+
2. Click **+ Add task**.
20+
3. Select **Jira Issue Validator** from the list of plugins.
21+
* Enter a task name (mandatory).
22+
* Optionally, enter a description.
23+
* Provide values for the input variables.
24+
25+
| Variable | Format | Description |
26+
| -------------- | ------ | --------------------------------------------------------- |
27+
| JiraUsername | String | Your Jira username (e.g., [email protected]) |
28+
| JiraPassword | String | Your Jira API token provided by the Jira admin |
29+
| JiraBaseUrl | String | The base URL of your Jira instance (e.g., https://yourdomain.atlassian.net) |
30+
31+
* `Trigger/Skip Condition` allows you to set conditions under which this task will execute or be skipped.
32+
* `Pass/Failure Condition` allows you to define conditions that determine whether the build passes or fails based on Jira validation.
33+
34+
4. Go to the **Build Stage**.
35+
36+
5. Select **Pull Request** in the **Source Type** dropdown.
37+
38+
6. Use filters to fetch only the PRs matching your regex. Here are few examples:
39+
* **Title** can be a regex pattern (e.g., `^(?P<jira_Id>([a-zA-Z0-9-].*))`) to extract the Jira ID from the PR title. Only those PRs fulfilling the regex will be shown for image build process.
40+
* **State** can be `^open$`, where only PRs in open state will be shown for image build process.
41+
42+
7. Click **Update Pipeline**.
43+
44+
---
45+
46+
## Results
47+
48+
**Case 1**: If Jira issue exists and the same is found in the PR title
49+
50+
![Figure 1: Jira Issue Match](https://devtron-public-asset.s3.us-east-2.amazonaws.com/images/plugins/jira/jira-issue-validator.jpg)
51+
52+
**Case 2**: If Jira issue is not found
53+
54+
![Figure 2: Error in Finding Jira Issue](https://devtron-public-asset.s3.us-east-2.amazonaws.com/images/plugins/jira/issue-validation-failed.jpg)

0 commit comments

Comments
 (0)