Skip to content

Commit 9d1a833

Browse files
authored
Merge branch 'master' into master
2 parents 7ba1df9 + 1a6973a commit 9d1a833

File tree

71 files changed

+318
-105
lines changed

Some content is hidden

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

71 files changed

+318
-105
lines changed

.github/workflows/bump-major-version.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
rsync -a --exclude=.git /home/runner/go/src/github.com/argoproj/argo-cd/ ../argo-cd
7575
7676
- name: Create pull request
77-
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
77+
uses: peter-evans/create-pull-request@84ae59a2cdc2258d6fa0732dd66352dddae2a412 # v7.0.9
7878
with:
7979
commit-message: "Bump major version to ${{ steps.get-target-version.outputs.TARGET_VERSION }}"
8080
title: "Bump major version to ${{ steps.get-target-version.outputs.TARGET_VERSION }}"

.github/workflows/init-release.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ jobs:
7070
git stash pop
7171
7272
- name: Create pull request
73-
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
73+
uses: peter-evans/create-pull-request@84ae59a2cdc2258d6fa0732dd66352dddae2a412 # v7.0.9
7474
with:
7575
commit-message: "Bump version to ${{ inputs.TARGET_VERSION }}"
7676
title: "Bump version to ${{ inputs.TARGET_VERSION }} on ${{ inputs.TARGET_BRANCH }} branch"

.github/workflows/release.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ jobs:
344344
if: ${{ env.UPDATE_VERSION == 'true' }}
345345

346346
- name: Create PR to update VERSION on master branch
347-
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e # v7.0.8
347+
uses: peter-evans/create-pull-request@84ae59a2cdc2258d6fa0732dd66352dddae2a412 # v7.0.9
348348
with:
349349
commit-message: Bump version in master
350350
title: 'chore: Bump version in master'

.github/workflows/renovate.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
go-version: 1.25.3
3131

3232
- name: Self-hosted Renovate
33-
uses: renovatebot/github-action@c91a61c730fa166439cd3e2c300c041590002b1d #44.0.3
33+
uses: renovatebot/github-action@5712c6a41dea6cdf32c72d92a763bd417e6606aa #44.0.5
3434
with:
3535
configurationFile: .github/configs/renovate-config.js
3636
token: '${{ steps.get_token.outputs.token }}'

cmd/argocd/commands/context.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,10 @@ argocd context cd.argoproj.io --delete`,
3434
Run: func(c *cobra.Command, args []string) {
3535
localCfg, err := localconfig.ReadLocalConfig(clientOpts.ConfigPath)
3636
errors.CheckError(err)
37+
if localCfg == nil {
38+
fmt.Println("No local configuration found")
39+
os.Exit(1)
40+
}
3741

3842
if deletion {
3943
if len(args) == 0 {

common/common.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,10 @@ const (
225225
// Ex: "http://grafana.example.com/d/yu5UH4MMz/deployments"
226226
// Ex: "Go to Dashboard|http://grafana.example.com/d/yu5UH4MMz/deployments"
227227
AnnotationKeyLinkPrefix = "link.argocd.argoproj.io/"
228+
// AnnotationKeyIgnoreDefaultLinks tells the Application to not add autogenerated links from this object into its externalURLs
229+
// This applies to ingress objects and takes effect if set to "true"
230+
// This only disables the default behavior of generating links based on the ingress spec, and does not disable AnnotationKeyLinkPrefix
231+
AnnotationKeyIgnoreDefaultLinks = "argocd.argoproj.io/ignore-default-links"
228232

229233
// AnnotationKeyAppSkipReconcile tells the Application to skip the Application controller reconcile.
230234
// Skip reconcile when the value is "true" or any other string values that can be strconv.ParseBool() to be true.

controller/cache/info.go

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,9 +225,19 @@ func populateIngressInfo(un *unstructured.Unstructured, res *ResourceInfo) {
225225
if res.NetworkingInfo != nil {
226226
urls = res.NetworkingInfo.ExternalURLs
227227
}
228-
for url := range urlsSet {
229-
urls = append(urls, url)
228+
229+
enableDefaultExternalURLs := true
230+
if ignoreVal, ok := un.GetAnnotations()[common.AnnotationKeyIgnoreDefaultLinks]; ok {
231+
if ignoreDefaultLinks, err := strconv.ParseBool(ignoreVal); err == nil {
232+
enableDefaultExternalURLs = !ignoreDefaultLinks
233+
}
230234
}
235+
if enableDefaultExternalURLs {
236+
for url := range urlsSet {
237+
urls = append(urls, url)
238+
}
239+
}
240+
231241
res.NetworkingInfo = &v1alpha1.ResourceNetworkingInfo{TargetRefs: targets, Ingress: ingress, ExternalURLs: urls}
232242
}
233243

controller/cache/info_test.go

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,40 @@ var (
126126
ingress:
127127
- ip: 107.178.210.11`)
128128

129+
testIgnoreDefaultLinksIngress = strToUnstructured(`
130+
apiVersion: extensions/v1beta1
131+
kind: Ingress
132+
metadata:
133+
name: helm-guestbook
134+
namespace: default
135+
uid: "4"
136+
annotations:
137+
link.argocd.argoproj.io/external-link: http://my-grafana.example.com/ingress-link
138+
argocd.argoproj.io/ignore-default-links: "true"
139+
spec:
140+
backend:
141+
serviceName: not-found-service
142+
servicePort: 443
143+
rules:
144+
- host: helm-guestbook.example.com
145+
http:
146+
paths:
147+
- backend:
148+
serviceName: helm-guestbook
149+
servicePort: 443
150+
path: /
151+
- backend:
152+
serviceName: helm-guestbook
153+
servicePort: https
154+
path: /
155+
tls:
156+
- host: helm-guestbook.example.com
157+
secretName: my-tls-secret
158+
status:
159+
loadBalancer:
160+
ingress:
161+
- ip: 107.178.210.11`)
162+
129163
testIngressWildCardPath = strToUnstructured(`
130164
apiVersion: extensions/v1beta1
131165
kind: Ingress
@@ -1200,6 +1234,30 @@ func TestGetLinkAnnotatedIngressInfo(t *testing.T) {
12001234
}, info.NetworkingInfo)
12011235
}
12021236

1237+
func TestGetIgnoreDefaultLinksIngressInfo(t *testing.T) {
1238+
info := &ResourceInfo{}
1239+
populateNodeInfo(testIgnoreDefaultLinksIngress, info, []string{})
1240+
assert.Empty(t, info.Info)
1241+
sort.Slice(info.NetworkingInfo.TargetRefs, func(i, j int) bool {
1242+
return info.NetworkingInfo.TargetRefs[i].Name < info.NetworkingInfo.TargetRefs[j].Name
1243+
})
1244+
assert.Equal(t, &v1alpha1.ResourceNetworkingInfo{
1245+
Ingress: []corev1.LoadBalancerIngress{{IP: "107.178.210.11"}},
1246+
TargetRefs: []v1alpha1.ResourceRef{{
1247+
Namespace: "default",
1248+
Group: "",
1249+
Kind: kube.ServiceKind,
1250+
Name: "helm-guestbook",
1251+
}, {
1252+
Namespace: "default",
1253+
Group: "",
1254+
Kind: kube.ServiceKind,
1255+
Name: "not-found-service",
1256+
}},
1257+
ExternalURLs: []string{"http://my-grafana.example.com/ingress-link"},
1258+
}, info.NetworkingInfo)
1259+
}
1260+
12031261
func TestGetIngressInfoWildCardPath(t *testing.T) {
12041262
info := &ResourceInfo{}
12051263
populateNodeInfo(testIngressWildCardPath, info, []string{})

docs/operator-manual/resource_actions.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,3 +235,43 @@ See the [Deployment actions discovery script](https://github.com/argoproj/argo-c
235235
```
236236

237237
The [resource scale actions](../user-guide/scale_application_resources.md) documentation shows how this function behaves in the UI.
238+
239+
## Contributing a Custom Resource Action
240+
241+
A resource action can be bundled into Argo CD. Custom resource action scripts are located in the `resource_customizations` directory of [https://github.com/argoproj/argo-cd](https://github.com/argoproj/argo-cd). Each contributed custom action needs to have a Lua script for discovery and a Lua script for the actual action logic. It also needs to have testdata and expected K8s resource manifests, which represent the outcome of performing the action.
242+
243+
The following directory structure must be respected:
244+
245+
```
246+
argo-cd
247+
|-- resource_customizations
248+
| |-- your.crd.group.io # CRD group
249+
| | |-- MyKind # Resource kind
250+
| | | |-- actions # Actions folder
251+
| | | | |-- action_test.yaml # Test inputs and expected results
252+
| | | | |-- testdata # Folder with sample K8s manifest yaml files, for testing the outcome of performing the custom actions
253+
| | | | |-- discovery.lua # Conditions upon which the custom action would be visible in the UI
254+
| | | | |-- <action_name> # Folder for each custom action, named as the custom action
255+
| | | | | |-- action.lua # Custom action logic Lua script
256+
```
257+
It is required to provide both discovery tests and action tests for your custom action.
258+
259+
Example of a [complete custom action](https://github.com/argoproj/argo-cd/tree/master/resource_customizations/argoproj.io/AnalysisRun/actions) called `terminate` for AnalysisRun.
260+
261+
262+
Example of `action_test.yaml` file content with `discoveryTests` and `actionTests`:
263+
``` yaml
264+
discoveryTests:
265+
- inputPath: testdata/runningAnalysisRun.yaml
266+
result:
267+
- name: terminate
268+
disabled: false
269+
- inputPath: testdata/failedAnalysisRun.yaml
270+
result:
271+
- name: terminate
272+
disabled: true
273+
actionTests:
274+
- action: terminate
275+
inputPath: testdata/runningAnalysisRun.yaml
276+
expectedOutputPath: testdata/runningAnalysisRun_terminated.yaml
277+
```
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,27 @@
11
# v3.2 to 3.3
22

3+
## Helm Upgraded to 3.19.2
4+
5+
Argo CD v3.3 upgrades the bundled Helm version to 3.19.2. There are no breaking changes in Helm 3.19.2 according to the
6+
[release notes](https://github.com/helm/helm/releases/tag/v3.19.0).
7+
8+
## Kustomize Upgraded to 5.7.1
9+
10+
Argo CD v3.3 upgrades the bundled Kustomize version to 5.7.1. There are no breaking changes in Kustomize 5.7.1 according
11+
to the [release notes](https://github.com/kubernetes-sigs/kustomize/releases/tag/kustomize%2Fv5.7.1).
12+
However, bear in mind that Kustomize 5.7.1 introduces code to replace the `shlex` library used for parsing arguments in the exec plugin.
13+
If any existing manifests become corrupted, please follow the[release notes](https://github.com/kubernetes-sigs/kustomize/releases/tag/kustomize%2Fv5.7.1) instructions.
14+
315
## Breaking Changes
416

517
### Anonymous call to Settings API returns fewer fields
618

719
The Settings API now returns less information when accessed anonymously.
820
It no longer returns the `resourceOverrides` field which is considered sensitive information.
21+
22+
### New ENV Variable to control K8s Server Side Timeout of API Requests
23+
24+
The new environment variable `ARGOCD_K8S_SERVER_SIDE_TIMEOUT` can be used to control the K8s server side timeout of API requests.
25+
In 3.2 and before this change, the K8s server side timeout was controlled by `ARGOCD_K8S_TCP_TIMEOUT`
26+
which is also used to control the TCP timeout when communicating with the K8s API server.
27+
From now onwards, the Kubernetes server-side timeout is controlled by a separate environment variable.

0 commit comments

Comments
 (0)