* Add retry for cluster generation
Signed-off-by: Dan Garfield <dan@codefresh.io>
* Switch to human readable count
Signed-off-by: Dan Garfield <dan@codefresh.io>
* fix logic
Signed-off-by: Dan Garfield <dan@codefresh.io>
* Add retry for cluster generation
Signed-off-by: Dan Garfield <dan@codefresh.io>
* remove superfluous if from previous iteration.
Signed-off-by: Dan Garfield <dan@codefresh.io>
* clean up code for final PR
Signed-off-by: Dan Garfield <dan@codefresh.io>
Signed-off-by: Dan Garfield <dan@codefresh.io>
Co-authored-by: pasha-codefresh <pavel@codefresh.io>
With Kiali v1.57.1 an additional status condition was added:
```
- lastTransitionTime: '2022-10-14T11:56:24Z'
message: ''
reason: ''
status: 'False'
type: Failure
```
Based on the discussion in https://github.com/kiali/kiali/issues/5560 this should not lead to a degraded health state.
This will no longer return Degraded as a catch-all and use the `type` and `status` fields of the condition to determine the CR health.
Signed-off-by: Allex Veldman <allexveldman+github@gmail.com>
Signed-off-by: Allex Veldman <allexveldman+github@gmail.com>
* feat(ui): notification subscriptions edit field
> this new field is just an abstraction of relevant annotations
Signed-off-by: Mayursinh Sarvaiya <marvinduff97@gmail.com>
* fix: codeql regex issue
Signed-off-by: Mayursinh Sarvaiya <marvinduff97@gmail.com>
Signed-off-by: Mayursinh Sarvaiya <marvinduff97@gmail.com>
The "Webhook and Manifest Paths Annotation" section of the documentation
contained a number of grammar and spelling issues as well as what appeared
to be some unintentionally pasted text.
This commit attempts to address these issues.
Signed-off-by: Lars Kellogg-Stedman <lars@oddbit.com>
Signed-off-by: Lars Kellogg-Stedman <lars@oddbit.com>
- launch.json now uses `main.go` and env var to determine which service is launched
- telepresence v2 uses new structure to initialice and intercept connections
- Add .envrc.remote to .gitignore
Signed-off-by: Nathanael Liechti <technat@technat.ch>
Signed-off-by: Nathanael Liechti <technat@technat.ch>
* Add support for apple sillicon build machines
When building the docker image on my M1 laptop, I noticed the produced builds are not usable in our Kubernetes cluster (running on x86 nodes).
By passing the DOCKER_PLATFORM build argument to `docker build` I am able to overcome this and build x86 images locally.
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Hardcode platform in dev build (same as we hardcode GOOS and GOARCH)
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Drop platform from build-ui target
It is only used to produce app/dist, not relevant
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
This should clean up any old branches and save on disk space, and fix any errors around bad branch names.
Signed-off-by: Daniel Hix <danieljacobhix@gmail.com>
Signed-off-by: Daniel Hix <danieljacobhix@gmail.com>
* feat: argocd app delete apps by label
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: add path to e2e test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: use guestbook path in e2e test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: change operation status assertions in e2e test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: change sync status to synced
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: assert on cli output for err in e2e test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: assert on err not output in e2e test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: ignore error to allow assertion to take place in test
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: assert on Contains instead of Equal
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: swtich args to assert.Contains
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: selector and args should not be used together
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: add app to delete example
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: return err instead of nil
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
This commit adds a new flag, `permitOnlyProjectScopedClusters`, which
prevents any application from syncing to clusters which are not a part
of the same project. Fixes#10220.
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
* chore: Remove bad symlink used for tests
Signed-off-by: jannfis <jann@mistrust.net>
* Mark CreateSymlink as helper function
Signed-off-by: jannfis <jann@mistrust.net>
Signed-off-by: jannfis <jann@mistrust.net>
* add notifications API
we allow to list triggers, templates and services
Signed-off-by: Pavel <aborilov@gmail.com>
* fix: add notification manifest to tests
Signed-off-by: Pavel <aborilov@gmail.com>
* fix: add sleep to fix integration tests
for some reason notification configmap has old data, trying to fix with
the sleep
Signed-off-by: Pavel <aborilov@gmail.com>
* add proposal
Signed-off-by: Pavel <aborilov@gmail.com>
* more info to proposal
Signed-off-by: Pavel <aborilov@gmail.com>
* use struct for notifications objects instead of just strings
to be able easily extend API in the future return list of
trigger/template/service as list of structs
Signed-off-by: Pavel <aborilov@gmail.com>
Signed-off-by: Pavel <aborilov@gmail.com>
* fix(ui): Fix multi-app refresh and sync in the UI
Signed-off-by: jannfis <jann@mistrust.net>
* Also fix node info
Signed-off-by: jannfis <jann@mistrust.net>
* Pass namespace instead of name
Signed-off-by: jannfis <jann@mistrust.net>
Signed-off-by: jannfis <jann@mistrust.net>
* Expand `ListResourceActions` to support the root App
Prior to this change, `ListResourceActions` could only be performed on
resources managed by the Application; this implicitly did not include
the Application itself, unless it was a self-referential Application.
This prevents the listing of actions on the Application itself.
This change detects when the requested resource is an Application with
the same name as the managing Application, thus bypassing the fetching
of the requested resource listing and simply retrieving the
Application. It then retrieves the resource details from the
Application itself, instead of any sub-resource.
Signed-off-by: David Monks <david.monks@octoenergy.com>
* Expand `RunResourceAction` to support the root App
Prior to this change, similar to the `ListResourceActions` function
updated in the previous commit, the `RunResourceAction` function only
supports running actions on resources managed by the Application, rather
than the Application itself.
This change re-uses in the `RunResourceAction` function the new
behaviour introduced in the previous commit to make the Application a
valid target for resource actions.
Signed-off-by: David Monks <david.monks@octoenergy.com>
* Extract App actions resource gathering to a private function
This abstracts the fetching of resources that can provide custom resource actions for a given Application via the CLI to a new private function next to the two Commands that do it.
This is a precursor to expanding this set of resources to include the Application itself.
Signed-off-by: David Monks <david.monks@octoenergy.com>
* Include the Application in the `actions list` CLI command
Prior to this change, only resources managed by the Application (and not
the Application itself) were able to have actions associated with them
for running via the CLI.
This change includes the Application itself in the list of resources to
check for custom resource actions when listing or running them via the
CLI.
Signed-off-by: David Monks <david.monks@octoenergy.com>
Signed-off-by: David Monks <david.monks@octoenergy.com>
* chore: infer managed resources health from redis instead of storing it in CRD
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* apply reviewer notes
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* feat: support gzip compression for data stored in redis
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* allow using different redis compression algorithms
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* fix: Trim spaces from string slice retrieved from env
Signed-off-by: jannfis <jann@mistrust.net>
* Add more tests
Signed-off-by: jannfis <jann@mistrust.net>
* Construct slice a little more efficient
Signed-off-by: jannfis <jann@mistrust.net>
* Fix trim logic
Signed-off-by: jannfis <jann@mistrust.net>
Signed-off-by: jannfis <jann@mistrust.net>
* feat: add support for default container in logs/exec
Signed-off-by: Edward Grönroos <edward@gronroos.se>
* chore: resolve linting issues
Signed-off-by: Edward Grönroos <edward@gronroos.se>
* fix: Drop all references to exec unless the feature is enabled #9920
Signed-off-by: Patrick Kerwood <patrick@kerwood.dk>
* fixed tslint issues
Signed-off-by: Patrick Kerwood <patrick@kerwood.dk>
* feat: Added health check for spot.io SpotDeployment
Signed-off-by: Daniel Leinov <dleinov@netapp.com>
* feat: Added fixed SpotDeployment health check
Signed-off-by: Daniel Leinov <dleinov@netapp.com>
* feat: Added fixed SpotDeployment health check script
Signed-off-by: Daniel Leinov <dleinov@netapp.com>
* feat: Added Google PubSub Topic and Subscription to health checks
Signed-off-by: Patrick Kerwood <patrick@kerwood.dk>
* Fixed apiVersion in test files
Signed-off-by: Patrick Kerwood <patrick@kerwood.dk>
* Add env var support for value file paths
Signed-off-by: Marius Sturm <marius.sturm@snyk.io>
* Add note about env vars in value file path
Signed-off-by: Marius Sturm <marius.sturm@snyk.io>
* Fix yaml syntax
Signed-off-by: Marius Sturm <marius.sturm@snyk.io>
* Update docs/operator-manual/application.yaml
- Removed comment about what namePrefix does. (i.e. it does not add a prefix to the image)
- Added examples of other supported transformers. (based on looking at the source code)
- Added link to the kustomize docs where the transormers are described in more detail.
* Update kustomize casing to be consistent
Signed-off-by: whyvez <yves@premise.com>
This adds the ability to selectively deny destinations, by prefixing
either its `namespace` or `server` with a `!`. Closes#9464.
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
It seems like most of the work for the mentioned issue below is done
under the PR #9466 but from the issue description, it's probably
worth to mention the example as added here.
Related #9352
Signed-off-by: Sahdev Zala <spzala@us.ibm.com>
* chore: argocd app create output states whether app exists
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: determine if app has changed without server err
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: unchanged if app has not changed
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: add logic to tell user if app was updated
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: edit comments
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: check if get err is notfound
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* test: Use dedicated multi-arch workloads in e2e tests
Signed-off-by: jannfis <jann@mistrust.net>
* Use correct tag
Signed-off-by: jannfis <jann@mistrust.net>
* feat: support multiple extensions per resource group/kind
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* apply reviewers suggestions
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* apply reviewer notes: stream extension files one by one
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* wrap errors
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* skip symlinks
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* fix: 'unexpected reserved bits' breaking web terminal (#9605)
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* make things more like they were originally, since the mutex fixes the problem
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix typo, don't pass around a pointer when it isn't necessary
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* apply suggestions
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: Make change of tracking method work at runtime
Signed-off-by: jannfis <jann@mistrust.net>
* GetAppName() will figure tracking label or annotation on its own
Signed-off-by: jannfis <jann@mistrust.net>
* Correct test comments and add another test
Signed-off-by: jannfis <jann@mistrust.net>
* Add a read lock before getting cache settings
Signed-off-by: jannfis <jann@mistrust.net>
* test: Remove circular symlinks from testdata
Signed-off-by: jannfis <jann@mistrust.net>
* Another test case
Signed-off-by: jannfis <jann@mistrust.net>
* Use defer for changing back to original workdir
Signed-off-by: jannfis <jann@mistrust.net>
* Abort the test on error in defer
Signed-off-by: jannfis <jann@mistrust.net>
* Update helm.md
The `initContainer` example for installing Helm plugins broke after of version 3.32.1 of the ArgoCD Helm chart. I've updated it with a working code example.
Signed-off-by: Didrik Finnøy <djfinnoy@protonmail.com>
* docs: Updated USERS.md
Signed-off-by: Didrik Finnøy <djfinnoy@protonmail.com>
* fix: missing path segments for git file generator
given the path:
/one/two/file.yaml
This change adds the params:
path[1]=two
path.filename=file.yaml
path.filenameNormalized
The use case is for symmetry with other generators (e.g., merge with a directory generator using the key path[1]). As no existing parameter values are changed it should be non-breaking.
Signed-off-by: Noah Perks Sloan <noah@hackedu.io>
* fix: expose all path elements for directory generator
This makes it consistent with the files generator and removes un-intuitive behavior without any breaking change.
docs: clarify - can use either baseName or nth path element
docs: use "directory", like the name of the generator, where "folder" was mentioned
Signed-off-by: Noah Perks Sloan <noah@hackedu.io>
As far as I can tell, this isn't explicitly documented anywhere (some docs mentioned this label in reference to ConfigMaps) I only figure it out by looking at the code.
* Fix#9429: A couple of notes in the docs to explain that the default certificate is insecure.
Signed-off-by: Jim Talbut <jim.talbut@groupgti.com>
* Fixes#9429: More verbose, but complete, text for Getting Started.
Signed-off-by: Jim Talbut <jim.talbut@groupgti.com>
* feat: allow interpolation of generator values
Allow the interpolation of `values` found in the cluster generator.
This allows interpolation of `{{name}}`, `{{server}}`,
`{{metadata.labels.*}}` and `{{metadata.annotations.*}}`. See
argoproj/applicationset#371.
This interpolation could potentially be extended to the list and
duck-type generators if desired.
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
* docs: add values interpolation usage instructions
Add a basic example of how values interpolation can be used with the
cluster generator.
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
* fix: remove billion-laughs attack vector
The previous implementation was vulnerable to a billion-laughs attack,
where someone could interpolate values based upon other values,
something like:
```yaml
values:
lol1: lol
lol2: '{{values.lol1}}{{values.lol1}}' #
lol3: '{{values.lol2}}{{values.lol2}}{{values.lol2}}{{values.lol2}}'
```
To counteract that, instead of directly manipulating the `params` map,
we create a map to keep track of the interpolated values, and only
template the values which have been previously whitelisted. Once we go
through all the values, we then merge the interpolated values map back
to the `params` map.
Signed-off-by: Blake Pettersson <blake.pettersson@gmail.com>
ubuntu:22.04 bumped the ppc64el baseline to POWER9, rendering this
unusable on existing POWER8 systems. This allows customization similar
to the top-level Dockerfile.
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
* chore: add k8s v1.24.1 to test matrix
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* chore: lower bearer token secret timeout to 5s
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: overrides should not appear in the manifest cache key
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix Helm regression
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix test again
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
While investigating how to disable the new terminal feature introduced in version 2.4, came across this accidental copy/paste. Figured would boyscout it in.
Signed-off-by: Evan Lowry <lowry.e@gmail.com>
* added environment variables page
Signed-off-by: Hari Sekhon <harisekhon@gmail.com>
* added Environment Variables page to User Guide
Signed-off-by: Hari Sekhon <harisekhon@gmail.com>
* reformatted table cells as multiline for clarity
Signed-off-by: Hari Sekhon <harisekhon@gmail.com>
* fixed typo
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: use serviceaccount name instead of struct
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: change name of param from sa to serviceAccount
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* fix: create serviceaccount token for v1.24 clusters
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* change create to get in err
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* Update microsoft.md
It was unclear the url was needed to be specified.
* Update docs/operator-manual/user-management/microsoft.md
Co-authored-by: jannfis <jann@mistrust.net>
Co-authored-by: jannfis <jann@mistrust.net>
* feat: combine form repo settings page
Signed-off-by: Regina Scott <rescott@redhat.com>
* Retrigger CI pipeline
Signed-off-by: Regina Scott <rescott@redhat.com>
Commit cc6c625401 changed a RUN mkdir
command into a WORKDIR, which also affected the entrypoint. This
triggered an error in goreman which looks for Procfile (which is
installed here in the root directory) in the working directory.
Since COPY creates any missing directories in the destination path,
there is no need for a separate step to create it. This change leaves
WORKDIR as the default (the root directory) as before.
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
* Upgraded Go to 1.18, & have changes related to matrix generator's child generators reading parameters. Specifically, 2nd generator reading the 1st generator's parameters.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added import for applicationSet in matrix.go
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added import for applicationSet in matrix.go
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added logging + small fixes for ArgoCD PR
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added testing for GetRelevantGenerators
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added a test for interpolating Generators
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Added a 2nd test for interpolating Generators
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Updated Generators-Matrix.md documentation to include an example + restrictions regarding child generator B consuming parameters produced by child generator A/
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Small wording fix.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Small change to generator_spec_processor.go
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Fixing Test case
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Small changes for matrix + generator_spec_processor.go
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Fixed (I believe) the issue that @Lobstrosity mentioned.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Refactored code to accept map[string]string instead of []map[string]string (for interpolateGenerator && Transform)
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Fixing test cases
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Fixing lint error.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Using test-case suggestion from @rumstead.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Changing up naming from testing.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Updated go.sum
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Cleaning up for linter.
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* Update Generators-Matrix.md
Changed all numbering back to 1 in "Restrictions" section
Signed-off-by: Jay P Kulkarni <jkulkarni@ucla.edu>
* Added changes as asked by @crenshaw-dev. These include
1) Removing part of comment in generator_spec_processor.go that was for an earlier iteration of code
2) Returning nil instead of an empty map in matrix.go
3) Creating a full-test (TestInterpolatedMatrixGenerate) in matrix.go. This example is not exactly the same, but very similar, to the example appset I had written in the Matrix Docs (also part of this PR).
Signed-off-by: jkulkarn <jay.p.kulkarni@blackrock.com>
Co-authored-by: jkulkarn <jay.p.kulkarni@blackrock.com>
* fix: missing Helm params
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* use absolute paths, fix tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix race in test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: Use the matchMode specified in the rbac configmap
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* add unit tests for checking policy using regex
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* docs: document plugin prefixed env vars
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* restructure, clarify env vars from main container behavior
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* grammer
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* grammer
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* no link - the cert is bad
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fixes
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: do not export repo-server environment to sidecar (#9393)
getPluginEnvs is both used for local plugins and sidecar plugins. For the later
do not include the environement variables of the repo-server in the supplied
variables.
Fixes: #9393
Signed-off-by: Pierre Crégut <pierre.cregut@orange.com>
* feat: Add plugin call variables to sidecar plugin discovery (#9273)
Gives access to variables declared in the call of the plugin in the application
manifest to the discover command run on the CMP server.
Variables are prefixed with ARGOCD_ENV_ to avoid security issues (plugin call
overiding important variables).
Fixes#9273
Signed-off-by: Pierre Crégut <pierre.cregut@orange.com>
the helm chart values should be copied as-is into the `notifications` section of the argo-cd chart
Signed-off-by: Pavel Savchenko <asfaltboy@gmail.com>
* git: prune any deleted refers before fetching
This commit modifies `nativeGitClient.Fetch()` to call `git remote prune origin` before fetching refs.
In some cases, an old branch may exist that conflicts with the name of a new branch. The old branch will have been deleted from `origin` but still exist locally in the `argocd-repo-server`.
Example: an old branch `feature/foo` conflicts with a new branch `feature/foo/bar`
In these cases, syncing an application results in the error:
```
rpc error: code = Internal desc = Failed to fetch default: `git fetch origin --tags --force` failed exit status 1: error: cannot lock ref 'refs/remotes/origin/feature/foo/bar': 'refs/remotes/origin/feature/foo' exists; cannot create 'refs/remotes/origin/feature/foo/bar' From https://github.com/org/repo ! [new branch] feature/foo/bar -> origin/feature/foo/bar (unable to update local ref) error: some local refs could not be updated; try running 'git remote prune origin' to remove any old, conflicting branches
```
Adding `git remote prune origin` before fetching, as recommended by the error message, should fix this issue.
The current workaround is to restart the `argocd-repo-server` which should flush the local repository folder. This works when Argo CD is installed using the Helm chart.
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
* fix: added extra protection to syncing app with replace (#9187)
* fix: added extra protection to syncing app with replace
Signed-off-by: ciiay <yicai@redhat.com>
* Code clean up
Signed-off-by: ciiay <yicai@redhat.com>
* Updated logic for isAppOfAppsPattern
Signed-off-by: ciiay <yicai@redhat.com>
* Updated text strings as per comment
Signed-off-by: ciiay <yicai@redhat.com>
* Fixed lint issue
Signed-off-by: ciiay <yicai@redhat.com>
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
* chore: Simplified GetRepoHTTPClient function (#9396)
* chore: Simplified GetRepoHTTPClient function
Signed-off-by: ls0f <lovedboy.tk@qq.com>
* simplified code and improve unit test coverage
Signed-off-by: ls0f <lovedboy.tk@qq.com>
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
* Only prune if fetch error message indicates that it is worthwhile, add unit tests
Confirmed that `Test_nativeGitClient_Fetch_Prune` fails without the bug fix, succeeds with it.
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
* fix: avoid k8s call before authorization for terminal endpoint (#9434)
* fix: avoid k8s API call before authorization in k8s endpoint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* check for bad project
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* more logging
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* handle 404, return 500 instead of 400 for other errors
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* use user input
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* refactor validation
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fixes, tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
* Match against "try running 'git remote prune origin'"
Signed-off-by: Kevin Snyder <kevin.snyder.codes@gmail.com>
Co-authored-by: Yi Cai <yicai@redhat.com>
Co-authored-by: ls0f <lovedboy.tk@qq.com>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: avoid k8s API call before authorization in k8s endpoint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* check for bad project
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* more logging
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* handle 404, return 500 instead of 400 for other errors
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* use user input
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* refactor validation
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fixes, tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: Simplified GetRepoHTTPClient function
Signed-off-by: ls0f <lovedboy.tk@qq.com>
* simplified code and improve unit test coverage
Signed-off-by: ls0f <lovedboy.tk@qq.com>
* bug(gitpod): change Kubebuilder curl (#9097)
Signed-off-by: Joseph Casey <me@josephmcasey.com>
* bug(gitpod): Use go build cache permission
* Targets path that user has permission to use
Signed-off-by: Joseph Casey <me@josephmcasey.com>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: do not allow symlinks from directory-type applications
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: use t.TempDir for simpler tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* address comments
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: support pod exec terminal logging
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* enhanced validation and logging when resource not found
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* fix lint
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* log warning when pod or container not found
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* go/log-injection fixes
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* log levels and lowercase message
Signed-off-by: smcavallo <smcavallo@hotmail.com>
* fix: http headers contain colons in the field value
Signed-off-by: ls0f <lovedboy.tk@qq.com>
* add parseHeaders unit test
Signed-off-by: ls0f <lovedboy.tk@qq.com>
feat: Add cli support for additional linux based architectures, s390x + ppc64le (#8991)
Signed-off-by: David J. M. Karlsen <david@davidkarlsen.com>
* add more architectures for linux
Signed-off-by: David J. M. Karlsen <david@davidkarlsen.com>
* drop aix arch as it won't compile
Signed-off-by: David J. M. Karlsen <david@davidkarlsen.com>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* fix(ui): missing manifests and logs (#9231)
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: make exec feature opt-in
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix codegen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* use create instead of get for exec to match k8s
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* add RBAC instructions for exec
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* delete old line
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* remove unnecessary caveat
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: Prevent crash on server reload if opentelemtry is not enabled
Signed-off-by: jannfis <jann@mistrust.net>
* Move variable declaration into loop
Signed-off-by: jannfis <jann@mistrust.net>
We use argo extensively in production, appsets, notif controller, and now multi cluster, so figured add our name to the list
Signed-off-by: Michael Asper <asper@imaware.health>
* Detailed steps for Azure AD App Registration Auth using OIDC
* Detailed steps for Azure AD App Registration Auth using OIDC
* Validation steps for both Web and CLI
Signed-off-by: kulmam92 <kulmam92@gmail.com>
* Images for Azure AD App Registration Auth using OIDC
Images for Azure AD App Registration Auth using OIDC
Signed-off-by: kulmam92 <kulmam92@gmail.com>
* add more context for scope
Signed-off-by: kulmam92 <kulmam92@gmail.com>
* fix: fall back to only branch if default branch is missing in gitea
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* throw meaningful error, use different org for test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: fall back to only branch if default branch is missing in gitea
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* throw meaningful error, use different org for test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* test: tests for SSHCreds env var generation
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: sort imports
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: add support for otel grpc tracing
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* chore: rebase code to master
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* feat: add otelgrpc to cmpserver
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* feat: add util trace package
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* fix: fix tracer context
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* chore: move tracer initialization part to the loop
Signed-off-by: Ben Ye <ben.ye@bytedance.com>
* docs: upgrade notes for new RBAC resource in 2.4
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: use resources, not verbs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: better phrasing
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: add header to emphasize that the RBAC is just an example
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: upgrade notes for CMP changes in 2.4
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: simplify test tempdir
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* test: add test for traversal
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: do not unset passCredentials when it's not specified (#9102)
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: codegen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: more tests, no-update detection for kustomize
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: fix test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
This commit replaces `ioutil.TempDir` with `t.TempDir` in tests. The
directory created by `t.TempDir` is automatically removed when the test
and all its subtests complete.
Prior to this commit, temporary directory created using `ioutil.TempDir`
needs to be removed manually by calling `os.RemoveAll`, which is omitted
in some tests. The error handling boilerplate e.g.
defer func() {
if err := os.RemoveAll(dir); err != nil {
t.Fatal(err)
}
}
is also tedious, but `t.TempDir` handles this for us nicely.
Reference: https://pkg.go.dev/testing#T.TempDir
Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
* chore: eliminate go-mpatch dependency
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: abstract out resource list function
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: don't exit the program in anything but the main function
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: better error messages
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: better error messages
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: remove helm2
Reorder test/container/Dockerfile to mitigate issue of being unable to create
.gitconfig since the homedir is not present
chore: cleanup helm2 and tests related to it
Remove helm2 init. Fix unused import
Use helm 3 structure for CRDs
Remove helm2-dependency testdata
Address PR comments
Add back values-production and value.yaml on helm tests
Remove helm2 from openapi.
Signed-off-by: Shyukri Shyukriev <shyukri.shyukriev@mariadb.com>
modified: util/helm/cmd_test.go
* fix: generated openapi
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
The io.Closer returned from the call to creds.Environ() removes the
underlying file. The desired behavior here is to clean up the
credentials files only after the plugin code has been run, which now
happens one level up in the call stack.
Fixes#7995
Signed-off-by: D. Ryan Hild <rhild@starbucks.com>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: bump helm version to 3.8.1
Signed-off-by: Miguel A. Alvarado V <alvaradoma@gmail.com>
* fix: Adding simple sanitize for repo name
Signed-off-by: Miguel A. Alvarado V <alvaradoma@gmail.com>
* feat: expose default metrics port in manifest definitions.
Out of the box, Applicationset presents some controller-runtime metrics on port 8080. However, the metric port is not defined as a container port in manifest files, therefore, they are not accessible. This
commit aims to make it accessible.
Co-authored-by: Erkan Zileli <erkan.zileli@trendyol.com>
Signed-off-by: Celal Öner <celal.oner@trendyol.com>
* chore: add Trendyol to the list of users.
Signed-off-by: Celal Öner <celal.oner@trendyol.com>
* chore(docs): add ServiceMonitor manifest example for newly added metrics.
Signed-off-by: Celal Öner <celal.oner@trendyol.com>
* fix: regenerate manifest file via make file.
Co-authored-by: Erkan Zileli <erkan.zileli@trendyol.com>
Signed-off-by: Celal Öner <celal.oner@trendyol.com>
Co-authored-by: Erkan Zileli <erkan.zileli@trendyol.com>
* feat: add caching to application js bundle since it has a unique name
Signed-off-by: Jonah Back <jonah@jonahback.com>
* chore: simplify check and add tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: New SCM and pull request ApplicationSet generators for Gitea
An initial implementation of Pull Request and SCM generators for Gitea.
API paging, and repo labels have not been implemented.
Signed-off-by: Dan Molik <dan@danmolik.com>
* chore: white space in hack/test.sh
re-trigger linting check
Signed-off-by: Dan Molik <dan@danmolik.com>
* chore: add gitea_scm and gitea_pr tests
Signed-off-by: Dan Molik <dan@danmolik.com>
* bug: ensure gitea scm haspath detects directories correctly
Signed-off-by: Dan Molik <dan@danmolik.com>
* chore: setup go 1.17 before lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: use specific golang version
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: update error message for test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: use message that's common to different k8s versions
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: use markdown include to fix broken docs (#8913)
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: trigger CI
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: codeql check should run on merge commit
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: trigger CI
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: don't run codeql on push event for dependabot branches
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
The k3d flag --k3s-server-arg changed to --k3s-arg and '--disable=traefik' does not work without a node filter: '--disable=traefik@server:*'
Signed-off-by: ksch84 <ksch84@protonmail.com>
* add to approvers
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* fix issue with format condition test
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* Trigger Build
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* work with specific jinja version
Signed-off-by: pashavictorovich <pavel@codefresh.io>
The application object can have labels so that its easier to group together certain applications in the ArgoCD UI. Although labels can be specified, there is no mention of that in the documentation.
Signed-off-by: jeunii <46089687+jeunii@users.noreply.github.com>
Podman and older versions of docker do not support multiple args
on a single line. It was recently added to docker in this commit
https://github.com/moby/buildkit/pull/1692 and podman still dose not have support
for it.
Signed-off-by: zachaller <zachaller@hotmail.com>
* chore: upgrade to go 1.17.8
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: use 1.17 so it's always latest in the series
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Environment variable with "=" in its value is not passed to sidecar
config management plugin, but ignored.
Signed-off-by: Ilya Lesikov <ilya@lesikov.com>
* chore: add snyk scan to image build workflow
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: remove yaml accidentally left in file
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: run container scan after push
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: no separate push step
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: revert unnecessary change
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: fix working dir for Snyk scans
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: add snyk scan to image build workflow
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: remove yaml accidentally left in file
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: run container scan after push
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: no separate push step
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: revert unnecessary change
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Remove extra print of error message
* Enable SilenceUsage to not display full help message with error
Signed-off-by: Daniel Helfand <helfand.4@gmail.com>
* docs: add crenshaw-dev to approvers
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: add leoluz as approver
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Document changes needed to upgrade in waves.
Signed-off-by: David Parsley <david@welldhealth.com>
* Add info on patching argocd-cm
Signed-off-by: David Parsley <david@welldhealth.com>
- data.oicd has no effect on the integration
- SSO flow did not initiate without putting the URL for argocd at `data.url` in `argocd-cm.yaml`. This is specified in the keycloak integration instructions as well.
Signed-off-by: Mit Suthar <msuthar@splunk.com>
* feat: For ```app diff``` cli refactored code to calculate and Print diff in to function findandPrintDiff to support diff functionality while syncing app, Added yes/no prompt to take confirmation while syncing app after previewing diffchanges
Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
* feat: diff changes initialized diffoption struct at declaration and removed nil checks and yesNo prompt as commented in review
Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
* feat: Incorporated review changes, changed flag names and text,made printdiff function to return bool,added texts while previewing diff
Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
* Update cmd/argocd/commands/app.go
Correcting prompt text
Co-authored-by: jannfis <jann@mistrust.net>
Signed-off-by: rishabh625 <rishabhmishra625@gmail.com>
Co-authored-by: jannfis <jann@mistrust.net>
* chore: update dependencies before starting e2e server
The e2e test server will show errors if there are irregular vendor and UI dependencies. This PR updates the Makefile to update the dependencies before starting the e2e server.
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* increase timeout while checking for e2e server
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* chore: bump go-git version to help avoid CVE-2020-9283
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: tidy
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: prevent file traversal using helm file values param and application details api
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* apply reviewer notes: move resolve.go into separate package; use uuid to generate random file
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* docs: Correct typo to match with YAML input in Ingress documentation
Signed-off-by: Ryota <rytswd@gmail.com>
* Retrigger CI pipeline
Signed-off-by: Ryota <rytswd@gmail.com>
* feat(cli): Allow to view previously terminated container logs
This is useful when we want to see the snapshot of previously terminated container logs.
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
* chore: Generate docs
Signed-off-by: Yuan Tang <terrytangyuan@gmail.com>
* feat: support disabling manifest generation using config management tools
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* rename EnableManifestGenerationForSourceType to EnableSourceTypes
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
In order to get Dex working with an OIDC provider, I had to structure the Dex config according to the [Dex Documentation](https://dexidp.io/docs/connectors/oidc/#configuration).
This means placing the OIDC configuration within their own `config` element in the `dex.config`, rather than listing them on the same level as the generic connector settings.
* chore: use go install instead of deprecated go get
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: readme fixes
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* add values example and gcp support
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* add values example and gcp support
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* fix: fallback to fetch default only on error
Ignoring commit SHA breaks gerrit when the commit is not merged
Signed-off-by: Yujun Zhang <yujunz@nvidia.com>
* revert util/git/client.go changes
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
Co-authored-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
I found it non-intuitive to have to tell our users to use `--grpc-web-root-path /`
when logging in when the defaults should have just worked.
This commit updates the Host-based ambassador mappings to avoid that, making
plain `argocd login <host>` calls work.
Signed-off-by: Franklin "Snaipe" Mathieu <me@snai.pe>
* update go version
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* update go version
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* change version in docs
Signed-off-by: pashavictorovich <pavel@codefresh.io>
* docs: add chart field to application.yaml
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: more clarification
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: add skipCrds flag for helm charts
* replace additionalTemplateArgs with includeCrds flag
* add testcase for skip crds
Signed-off-by: patst <patrick.steinig@googlemail.com>
* feat: add skipCrds flag for helm charts
* replace additionalTemplateArgs with includeCrds flag
* add testcase for skip crds
Signed-off-by: patst <patrick.steinig@googlemail.com>
* feat: add skipCrds flag for helm charts
* replace additionalTemplateArgs with includeCrds flag
* add testcase for skip crds
Signed-off-by: patst <patrick.steinig@googlemail.com>
* feat: add skipCrds flag for helm charts
* make sure include crds is not added for helm2
Signed-off-by: patst <patrick.steinig@googlemail.com>
* docs: reorganize and clarify CMP docs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs: note that an empty plugin block is acceptable
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* feat: support XDG Base directory standard
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
* chore: set XDG_CONFIG_HOME env var for docs generation
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
* chore: regenerate cli docs
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
* feat: allow escaping dollar in Envsubst
Signed-off-by: Thomas Dy <thatsmydoing@gmail.com>
* docs: add variable escape documentation
Signed-off-by: Thomas Dy <thatsmydoing@gmail.com>
so as to allow operators to prevent Argo CD from passing valueFiles
to helm template if they don't exist in the source under the specified path.
Signed-off-by: Oscar Craviotto <craviotto@avellaneda.com>
When configuring an external OIDC provider which uses a private PKI
for its certificates it was not possible to properly verify the certificate
being served. Also, when using ArgoCD in insecure mode, e.g. when running
behind istio for providing mTLS, this resulted in errors.
Signed-off-by: Clive Jevons <clive@jevons-it.net>
* Docs: Helm plugins via initContainers
Related: #7066
Include an alternative method for installing Helm plugins that don't require users to maintain their own version of the ArgoCD container image.
Signed-off-by: Didrik Finnøy <djfinnoy@protonmail.com>
* add codeblock
Signed-off-by: Didrik Finnøy <djfinnoy@protonmail.com>
* change helm repo name in example code
Signed-off-by: Didrik Finnøy <djfinnoy@protonmail.com>
* docs: add a link from the base security doc to the operator manual security page
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: better copy
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: bump doc version
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix: add nil check, add revision tests, add docs about webhook behavior
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: move single-use function into test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: add comment about why some tests are absent
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* chore: fix text names
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Remove python3-pip and deps
Use hack/installers since AWS doesn't provide pip packages for v2
Side effect: image downsize 842 MB -> 483MB
Signed-off-by: Shyukri Shyukriev <shyukri.shyukriev@mariadb.com>
* When adding Kubernetes labels as Prometheus labels, replace with all the invalid Prometheus label chars
Signed-off-by: Xabier Larrakoetxea <me@slok.dev>
* Add Fonoa company to users doc
Signed-off-by: Xabier Larrakoetxea <me@slok.dev>
* Add comment and link to the Prometheus label valid characters
Signed-off-by: Xabier Larrakoetxea <me@slok.dev>
* fix: during import, if stop-operation flag is provided, then nil operation field of application
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: during import, if stop-operation flag is provided, then nil operation field of application
Signed-off-by: May Zhang <may_zhang@intuit.com>
* run goimports -local
Signed-off-by: May Zhang <may_zhang@intuit.com>
* updated docs
Signed-off-by: May Zhang <may_zhang@intuit.com>
Adding argocd-vault-replacer as another hashicorp vault tool with different abilities from the IBM version. Primary differences:
* Ability to use kubernetes authentication
* Textual replacement rather than understanding the YAML so secrets can be anywhere, not just in limited locations.
* Ability to process the secrets into other forms (e.g. base64 encode)
Signed-off-by: Alan Clucas <alan@clucas.org>
Co-authored-by: jannfis <jann@mistrust.net>
* docs: mention finalizer in app-of-apps doc
As it's easy to overlook the need for a specific finalizer in the Application CR to ensure cascading deletion I added an extra section describing the need and linking to the ArgoCD Docs for further information about App deletion.
Signed-off-by: PixelJonas <5434875+PixelJonas@users.noreply.github.com>
* doc: fix typo in cluster-bootstrappring docs
small typo fix
Signed-off-by: PixelJonas <5434875+PixelJonas@users.noreply.github.com>
* fix SyncWindow link when using baseherf
Signed-off-by: ln3333 <liangxu@outlook.com>
* fix: SyncWindow link not honoring basehref
Signed-off-by: ln3333 <liangxu@outlook.com>
If you are trying to resolve an environment-specific issue or have a one-off question about the edge case that does not require a feature then please consider asking a question in argocd slack [channel](https://argoproj.github.io/community/join-slack).
<!-- If you are trying to resolve an environment-specific issue or have a one-off question about the edge case that does not require a feature then please consider asking a question in argocd slack [channel](https://argoproj.github.io/community/join-slack). -->
Checklist:
@@ -16,19 +16,19 @@ Checklist:
**Describe the bug**
A clear and concise description of what the bug is.
<!-- A clear and concise description of what the bug is. -->
**To Reproduce**
A list of the steps required to reproduce the issue. Best of all, give us the URL to a repository that exhibits this issue.
<!-- A list of the steps required to reproduce the issue. Best of all, give us the URL to a repository that exhibits this issue. -->
**Expected behavior**
A clear and concise description of what you expected to happen.
<!-- A clear and concise description of what you expected to happen. -->
**Screenshots**
If applicable, add screenshots to help explain your problem.
<!-- If applicable, add screenshots to help explain your problem. -->
about: Propose adding security-related logs or tagging existing logs with security fields
title: "seclog: [Event Description]"
labels: security-log
assignees: notfromstatefarm
---
# Event to be logged
Specify the event that needs to be logged or existing logs that need to be tagged.
# Proposed level
What security level should these events be logged under? Refer to https://argo-cd.readthedocs.io/en/latest/operator-manual/security/#security-field for more info.
# Common Weakness Enumeration
Is there an associated [CWE](https://cwe.mitre.org/) that could be tagged as well?
# Secrets aren't available for dependabot on push. https://docs.github.com/en/enterprise-cloud@latest/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/troubleshooting-the-codeql-workflow#error-403-resource-not-accessible-by-integration-when-using-dependabot
branches-ignore:
- 'dependabot/**'
pull_request:
schedule:
- cron:'0 19 * * 0'
concurrency:
group:${{ github.workflow }}-${{ github.ref }}
cancel-in-progress:true
permissions:
contents:read
jobs:
CodeQL-Build:
permissions:
actions:read # for github/codeql-action/init to get workflow details
contents:read # for actions/checkout to fetch code
security-events:write # for github/codeql-action/autobuild to send a status report
if:github.repository == 'argoproj/argo-cd'
# CodeQL runs on ubuntu-latest and windows-latest
runs-on:ubuntu-latest
runs-on:ubuntu-22.04
steps:
- name:Checkout repository
uses:actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth:2
# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run:git checkout HEAD^2
if:${{ github.event_name == 'pull_request' }}
uses:actions/checkout@v3
# Initializes the CodeQL tools for scanning.
- name:Initialize CodeQL
uses:github/codeql-action/init@v1
uses:github/codeql-action/init@v2
# Override language selection by uncommenting this and choosing your languages
# TODO: clean up old images once github supports it: https://github.community/t5/How-to-use-Git-and-GitHub/Deleting-images-from-GitHub-Package-Registry/m-p/41202/thread-id/9811
* feat: Treat connection reset as a retryable error (#9739)
### Bug fixes
* fix: 'unexpected reserved bits' breaking web terminal (#9605) (#9895)
* fix: argocd login just hangs on 2.4.0 #9679 (#9935)
* fix: CMP manifest generation fails with ENHANCE_YOUR_CALM if over 40s (#9922)
* fix: NotAfter is not set when ValidFor is set (#9911)
* fix: add missing download CLI tool link for ppc64le, s390x (#9649)
* fix: Check tracking annotation for being self-referencing (#9791)
* fix: Make change of tracking method work at runtime (#9820)
* fix: argo-cd git submodule is using SSH auth instead of HTTPs (#3118) (#9821)
### Other
* docs: fix typo in Generators-Git.md (#9949)
* docs: add terminal documentation (#9948)
* test: Use dedicated multi-arch workloads in e2e tests (#9921)
* docs: Adding blank line so list is formatted correctly (#9880)
* docs: small fix for plugin stream filtering (#9871)
* docs: Document the possibility of rendering Helm charts with Kustomize (#9841)
* docs: getting started notes on self-signed cert (#9429) (#9784)
* test: check for error messages from CI env (#9953)
## v2.4.5 (2022-07-12)
### Security fixes
* HIGH: Certificate verification is skipped for connections to OIDC providers ([GHSA-7943-82jg-wmw5](https://github.com/argoproj/argo-cd/security/advisories/GHSA-7943-82jg-wmw5))
* LOW: A leaked API server encryption key can allow XSS for SSO users ([GHSA-pmjg-52h9-72qv](https://github.com/argoproj/argo-cd/security/advisories/GHSA-pmjg-52h9-72qv))
### Potentially-breaking changes
The fix for GHSA-7943-82jg-wmw5 enables TLS certificate validation by default for connections to OIDC providers. If
connections to your OIDC provider fails validation, SSO will be broken for your Argo CD instance. You should test 2.4.5
before upgrading it to production. From the new documentation:
> By default, all connections made by the API server to OIDC providers (either external providers or the bundled Dex
> instance) must pass certificate validation. These connections occur when getting the OIDC provider's well-known
> configuration, when getting the OIDC provider's keys, and when exchanging an authorization code or verifying an ID
> token as part of an OIDC login flow.
>
> Disabling certificate verification might make sense if:
> * You are using the bundled Dex instance **and** your Argo CD instance has TLS configured with a self-signed certificate
> **and** you understand and accept the risks of skipping OIDC provider cert verification.
> * You are using an external OIDC provider **and** that provider uses an invalid certificate **and** you cannot solve
> the problem by setting `oidcConfig.rootCA` **and** you understand and accept the risks of skipping OIDC provider cert
> verification.
>
> If either of those two applies, then you can disable OIDC provider certificate verification by setting
> `oidc.tls.insecure.skip.verify` to `"true"` in the `argocd-cm` ConfigMap.
### Bug fixes
* fix: webhook typo in case of error in GetManifests (#9671)
## v2.4.4 (2022-07-07)
### Bug fixes
- fix: missing path segments for git file generator (#9839)
- fix: make sure api server informer does not stop after setting change (#9842)
- fix: support resource logs and exec (#9833)
- fix: configurable CMP tar exclusions (#9675) (#9789)
- fix: prune any deleted refs before fetching (#9504)
### Other
- test: Remove circular symlinks from testdata (#9886)
- docs: custom secret must be labeled (#9835)
- docs: update archlinux install with official package (#9718)
- fix websockets for terminal not working on subPath (#9795)
- fix: avoid closing and re-opening port of api server settings change (#9778)
- fix: [ArgoCD] Fixing webhook typo in case of error in GetManifests (#9671)
- fix: overrides should not appear in the manifest cache key (#9601)
## v2.4.2 (2022-06-21)
### Bug fixes
* fix: project filter (#9651) (#9709)
* fix: broken symlink in Dockerfile (#9674)
* fix: updated baseHRefRegex to perform lazy match (#9724)
* fix: updated config file permission requirements for windows (#9666)
### Other
* docs: Update sync-options.md (#9687)
* test/remote: Allow override of base image (#9734)
## v2.4.1 (2022-06-21)
### Security fixes
* CRITICAL: External URLs for Deployments can include javascript ([GHSA-h4w9-6x78-8vrj](https://github.com/argoproj/argo-cd/security/advisories/GHSA-h4w9-6x78-8vrj))
* HIGH: Insecure entropy in PKCE/Oauth2/OIDC params ([GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v))
* MODERATE: DoS through large directory app manifest files ([GHSA-jhqp-vf4w-rpwq](https://github.com/argoproj/argo-cd/security/advisories/GHSA-jhqp-vf4w-rpwq))
* MODERATE: Symlink following allows leaking out-of-bounds YAML files from Argo CD repo-server ([GHSA-q4w5-4gq2-98vm](https://github.com/argoproj/argo-cd/security/advisories/GHSA-q4w5-4gq2-98vm))
### Potentially-breaking changes
From the [GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v) description:
> The patch introduces a new `reposerver.max.combined.directory.manifests.size` config parameter, which you should tune before upgrading in production. It caps the maximum total file size of .yaml/.yml/.json files in directory-type (raw manifest) Applications. The default max is 10M per Application. This max is designed to keep any single app from consuming more than 3G of memory in the repo-server (manifests consume more space in memory than on disk). The 300x ratio assumes a maliciously-crafted manifest file. If you only want to protect against accidental excessive memory use, it is probably safe to use a smaller ratio.
>
> If your organization uses directory-type Applications with very many manifests or very large manifests then check the size of those manifests and tune the config parameter before deploying this change to production. When testing, make sure to do a "hard refresh" in either the CLI or UI to test your directory-type App. That will make sure you're using the new max logic instead of relying on cached manifest responses from Redis.
### Other
* test: directory app manifest generation (#9503)
* chore: Implement tests to validate aws auth retry (#9627)
* chore: Implement a retry in aws auth command (#9618)
* test: Remove temp directories from repo server tests (#9501)
* test: Make context tests idempodent (#9502)
* test: fix plugin var test for OSX (#9590)
* docs: Document how to deploy from the root of the git repository (#9632)
Feature enables engineers to start a shell in the running application container without leaving the web interface. Just find the required Kubernetes
Pod using the Application Details page, click on it and select the Terminal tab. The shell starts automatically and enables you to execute the required
commands, and helps to troubleshoot the application state.
### Access Control For Pod Logs & WebTerminal
Argo CD is used to manage the critical infrastructure of multiple organizations, which makes security the top priority of the project. We've listened to
your feedback and introduced additional access control settings that control access to Kubernetes Pod logs and the new Web Terminal feature.
#### Pod Logs UI
Since 2.4.9, the LOGS tab in pod view is visible in the UI only for users with explicit allow get logs policy.
#### Known pod logs UI issue prior to 2.4.9
Upon pressing the "LOGS" tab in pod view by users who don't have an explicit allow get logs policy, the red "unable to load data: Internal error" is received in the bottom of the screen, and "Failed to load data, please try again" is displayed.
### OpenTelemetry Tracing Integration
The new feature allows emitting richer telemetry data that might make identifying performance bottlenecks easier. The new feature is available for argocd-server
and argocd-repo-server components and can be enabled using the --otlp-address flag.
### Power PC and IBM ZSupport
The list of supported architectures has been expanded, and now includes IBM Z (s390x) and PowerPC (ppc64le). Starting with the v2.4 release the official quay.io
repository is going to have images for amd64, arm64, ppc64le, and s390x architectures.
### Other NotableChanges
Overall v2.4 release includes more than 300 hundred commits from nearly 90 contributors. Here is a short sample of the contributions:
* Enforce the deployment to remote clusters only
* Native support of GCP authentication for GKE
* Secured Redis connection
* ApplicationSet Gitea support
## v2.3.7 (2022-07-29)
### Notes
This is mainly a security related release and updates compatibility with Kubernetes 1.24.
**Attention:** The base image for 2.3.x reached end-of-life on July 14, 2022. This release upgraded the base image to Ubuntu 22.04 LTS. The change should have no effect on the majority of users. But if any of your git providers only supports now-deprecated key hash algorithms, then Application syncing might break. See the [2.2-to-2.3 upgrade notes](https://argo-cd.readthedocs.io/en/latest/operator-manual/upgrading/2.2-2.3/#support-for-private-repo-ssh-keys-using-the-sha-1-signature-hash-algorithm-is-removed-in-237) for details and workaround instructions.
### Bug fixes
- fix: skip redirect url validation when it's the base href (#10058) (#10116)
- fix: upgrade moment from 2.29.2 to 2.29.3 (#9330)
- fix: avoid CVE-2022-28948 (#10093)
- fix: use serviceaccount name instead of struct (#9614)
- fix: create serviceaccount token for v1.24 clusters (#9546)
### Other changes
- test: Remove cluster e2e tests not intended for release-2.3
- test: Remove circular symlinks from testdata (#9886)
- chore(deps): bump moment from 2.29.3 to 2.29.4 in /ui (#9897)
- chore: upgrade moment to latest version to fix CVE (#9005)
- chore: move dependencies to dev dependencies (#8541)
- chore: update redis to 6.2.7 avoid CVE-2022-30065/CVE-2022-2097 (#10062)
- chore: upgrade Dex to 2.32.0 (#10036) (#10042)
- chore: update haproxy to 2.0.29 for redis-ha (#10045)
- test: check for error messages from CI env (#9953)
## v2.3.6 (2022-07-12)
### Security fixes
* HIGH: Certificate verification is skipped for connections to OIDC providers ([GHSA-7943-82jg-wmw5](https://github.com/argoproj/argo-cd/security/advisories/GHSA-7943-82jg-wmw5))
* LOW: A leaked API server encryption key can allow XSS for SSO users ([GHSA-pmjg-52h9-72qv](https://github.com/argoproj/argo-cd/security/advisories/GHSA-pmjg-52h9-72qv))
### Potentially-breaking changes
The fix for GHSA-7943-82jg-wmw5 enables TLS certificate validation by default for connections to OIDC providers. If
connections to your OIDC provider fails validation, SSO will be broken for your Argo CD instance. You should test 2.3.6
before upgrading it to production. From the new documentation:
> By default, all connections made by the API server to OIDC providers (either external providers or the bundled Dex
> instance) must pass certificate validation. These connections occur when getting the OIDC provider's well-known
> configuration, when getting the OIDC provider's keys, and when exchanging an authorization code or verifying an ID
> token as part of an OIDC login flow.
>
> Disabling certificate verification might make sense if:
> * You are using the bundled Dex instance **and** your Argo CD instance has TLS configured with a self-signed certificate
> **and** you understand and accept the risks of skipping OIDC provider cert verification.
> * You are using an external OIDC provider **and** that provider uses an invalid certificate **and** you cannot solve
> the problem by setting `oidcConfig.rootCA` **and** you understand and accept the risks of skipping OIDC provider cert
> verification.
>
> If either of those two applies, then you can disable OIDC provider certificate verification by setting
> `oidc.tls.insecure.skip.verify` to `"true"` in the `argocd-cm` ConfigMap.
### Bug fixes
* fix: webhook typo in case of error in GetManifests (#9671)
## v2.3.5 (2022-06-21)
### Security fixes
* CRITICAL: External URLs for Deployments can include javascript ([GHSA-h4w9-6x78-8vrj](https://github.com/argoproj/argo-cd/security/advisories/GHSA-h4w9-6x78-8vrj))
* HIGH: Insecure entropy in PKCE/Oauth2/OIDC params ([GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v))
* MODERATE: DoS through large directory app manifest files ([GHSA-jhqp-vf4w-rpwq](https://github.com/argoproj/argo-cd/security/advisories/GHSA-jhqp-vf4w-rpwq))
* MODERATE: Symlink following allows leaking out-of-bounds YAML files from Argo CD repo-server ([GHSA-q4w5-4gq2-98vm](https://github.com/argoproj/argo-cd/security/advisories/GHSA-q4w5-4gq2-98vm))
### Potentially-breaking changes
From the [GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v) description:
> The patch introduces a new `reposerver.max.combined.directory.manifests.size` config parameter, which you should tune before upgrading in production. It caps the maximum total file size of .yaml/.yml/.json files in directory-type (raw manifest) Applications. The default max is 10M per Application. This max is designed to keep any single app from consuming more than 3G of memory in the repo-server (manifests consume more space in memory than on disk). The 300x ratio assumes a maliciously-crafted manifest file. If you only want to protect against accidental excessive memory use, it is probably safe to use a smaller ratio.
>
> If your organization uses directory-type Applications with very many manifests or very large manifests then check the size of those manifests and tune the config parameter before deploying this change to production. When testing, make sure to do a "hard refresh" in either the CLI or UI to test your directory-type App. That will make sure you're using the new max logic instead of relying on cached manifest responses from Redis.
### Bug fixes
* fix: missing Helm params (#9565) (#9566)
### Other
* test: directory app manifest generation (#9503)
* chore: eliminate go-mpatch dependency (#9045)
* chore: Make unit tests run on platforms other than amd64 (#8995)
* chore: remove obsolete repo-server unit test (#9559)
* chore: update golangci-lint (#8988)
* fix: test race (#9469)
* chore: upgrade golangci-lint to v1.46.2 (#9448)
* test: fix ErrorContains (#9445)
## v2.3.4 (2022-05-18)
### Security fixes
- CRITICAL: Argo CD will trust invalid JWT claims if anonymous access is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-r642-gv9p-2wjj)
- LOW: Login screen allows message spoofing if SSO is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-xmg8-99r8-jc2j)
- MODERATE: Symlink following allows leaking out-of-bound manifests and JSON files from Argo CD repo-server (https://github.com/argoproj/argo-cd/security/advisories/GHSA-6gcg-hp2x-q54h)
### Argo CD ApplicationSet and Notifications are now part of Argo CD
Two popular [Argoproj Labs](https://github.com/argoproj-labs) projects [Argo CD ApplicationSet](https://github.com/argoproj/applicationset) and
[Argo CD Notifications](https://github.com/argoproj-labs/argocd-notifications) are now part of Argo CD! The default Argo CD installation manifests now
bundle both projects out of the box. Going forward you can expect more tightened integration of these projects into Argo CD.
### New sync and diff strategies
Users can now configure the Application resource to instruct Argo CD to consider the ignore difference setup during the sync process.
In order to do so, add the new sync option RespectIgnoreDifferences=true in the Application resource. Once the sync option is added,
Argo CD won't change ignored fields during the syncing process.
Configuring ignored fields is also easier now. Instead of listing fields one by one users can now leverage the
managedFields metadata to instruct Argo CD about trusted managers and automatically ignore any fields owned by them. A new diff customization
(managedFieldsManagers) is now available allowing users to specify managers the application should trust and to ignore all fields owned by those managers.
Read more about these changes at [New sync and diff strategies in ArgoCD](https://blog.argoproj.io/new-sync-and-diff-strategies-in-argocd-44195d3f8b8c) blog post.
### ARM Images
An officially supported ARM 64 image is now available. Enjoy running Argo CD on your Raspberry Pi! Additionally, the image size was reduced by nearly ~50%
and is only 200MB now. The ARM version of `argocd` CLI is also available and published as a Github release artifact.
### Compact Tree View And Click Application Navigation
The application details page now supports compact application resources tree visualization. Using the "Group Nodes" button, you can collapse the similar resources
into a single group node to remove the clutter and make it easier to understand the state of application resources. You still can get detailed information about the collapsed resources by clicking on the group node. The list of collapsed resources will be available in a sliding panel. Compact resource tree is still too big?
You can use the zoom in and zoom out feature to make it smaller - or even larger!
You no longer need to move back and forth between the application details page and the application list page. Instead you can navigate directly to the required application by clicking the search icon in the application details page title.
### Upgraded Config Management Tools
Both bundled Helm and Kustomize binaries have been upgraded to the latest versions. Kustomize has been upgraded from 4.2.0 to 4.4.1 and Helm has been upgraded from 3.7.1 to 3.8.0.
### Bug Fixes and Performance Enhancements
* Config management tools enhancements:
* The skipCrds flag and ability to ignore missing values files for Helm (#8012, #8003)
* Additional environment variables for Kustomize (#8096)
* Argo CD CLI follows the XDG Base directory standard (#7638)
* Redis is no longer used during SSO login (#8241)
### Features
- feat: Add app list and details page views to navigation history (#7776) (#7937)
- feat: Add skipCrds flag for helm charts (#8012)
- feat: Add visual indicator for newly created pods (#8006)
- feat: Added a new Helm option ignoreMissingValueFiles (#7767) (#8003)
- feat: Allow configuring system wide ignore differences for all resources (#8224)
- feat: Allow escaping dollar in Envsubst (#7961)
- feat: Allow external links on Application (#3487) (#8231)
- feat: Allow selecting application on detail page (#8176)
- feat: Bundle applicationset-controller with argocd (#8148)
- feat: Enable specifying root ca for oidc (#6712)
- feat: Expose ARGOCD_APP_NAME to the `kustomize build` command (#8096)
- feat: Ignore differences owned by trusted managers from managedFields (#7869)
- feat: New sync option to use ignore diff configs during sync (#8078)
- feat: Provide address flag for admin dashboard command (#8095)
- feat: Store "Group Nodes" button state in application details preferences (#8036)
- feat: Support specifying cluster by name in addition to API server URL in Cluster API (#8077)
- feat: Support XDG Base directory standard (#7638) (#7791)
- feat: Use encrypted cookie to store OAuth2 state nonce (instead of redis) (#8241)
- feat: Build images on PR and conditionally build arm64 image on push (#8108)
### Bug Fixes
- fix: Add "Restarting MinIO" status to MiniO Tenant health check (#8191)
- fix: Add all resources in list view (#7295)
- fix: Adding pagination to grouped nodes sliding panel#7837 (#7915)
- fix: Allow all resources to add external links (#7923)
- fix: Always call ValidateDestination (#7976)
- fix: Application exist panic when execute api call (#8188)
- fix: Application-icons-alignment (#8054)
- fix: Controller panics if resource manifest has incorrect annotation (#8022)
- fix: Correctly handle project field during partial cluster update (#7994)
- fix: Default value for retry validation #8055 (#8064)
- fix: Fix a possible crash when parsing RBAC (#8165)
- fix: Grouped node list missing resources on Compact resources view #8014 (#8018)
- fix: Issue with headless installation (#7958)
- fix: Issue with project scoped resources (#8048)
- fix: Kubernetes labels normalization for Prometheus (#7925)
- fix: Nested Refresh dropdown does not work on Application Details page #1524 (#7950)
- fix: Network line colors and menu icon alignment (#8059)
- fix: Opening app details shows UI error on some apps (#8016) (#8019)
- fix: Parse to correct uint32 type (#8177)
- fix: Prevent possible nil-pointer deref in normalizer (#8185)
- fix: Prevent possible out-of-bounds access when loading policies (#8186)
- fix: Provide a semantic version parsed version for KUBE_VERSION (#8250)
- fix: Refreshing label toast (#7979)
- fix: Resource details page crashes when resource is not deployed and hide managed fields is selected (#7971)
- fix: Retry disabled text (#8004)
- fix: Route health check stuck in 'Progressing' (#8170)
- fix: Sync window panel is crashed if resource name not contain letters (#8053)
- fix: Targetervision compatible without prefix refs/heads or refs/tags (#7939)
- fix: Trailing line in Filter Dropdown Menus #7821 (#8001)
- fix: Webhook URL matching edge cases (#7981)
- fix(ui): Use consistent case for diff modes (#7945)
- fix: Use gRPC timeout for sidecar CMPs (#8131) (#8236)
### Other
- chore: Bump go-jsonnet to v0.18.0 (#8011)
- chore: Escape proj in regex (#7985)
- chore: Exclude argocd-server rbac for core-install (#8234)
- chore: Log out the resource triggering reconciliation (#8192)
- chore: Migrate to use golang-jwt/jwt v4.2.0 (#8136)
- chore: Move resolveRevision from api-server to repo-server (#7966)
- chore: Update notifications version (#8267)
- chore: Update slack version (#8299)
- chore: Update to Redis 6.2.4 (#8157)
- chore: Upgrade awscli to 2.4.6 and remove python deps (#7947)
- chore: Upgrade base image to ubuntu:21.10 (#8230)
- chore: Upgrade dex to v2.30.2 (https://github.com/dexidp/dex/issues/2326) (#8237)
- chore: Upgrade gitops engine (#8288)
- chore: Upgrade golang to 1.17.6 (#8229)
- chore: Upgrade helm to most recent version (v3.7.2) (#8226)
- chore: Upgrade k8s client to v1.23 (#8213)
- chore: Upgrade kustomize to most recent version (v4.4.1) (#8227)
- refactor: Introduce 'byClusterName' secret index to speedup cluster server URL lookup (#8133)
- refactor: Move project filtering to server side (#8102)
## v2.2.12 (2022-07-29)
### Notes
This is mainly a security related release and updates compatibility with Kubernetes 1.24.
**Attention:** The base image for 2.2.x reached end-of-life on January 20, 2022. This release upgraded the base image to Ubuntu 22.04 LTS. The change should have no effect on the majority of users. But if any of your git providers only supports now-deprecated key hash algorithms, then Application syncing might break. See the [2.1-to-2.2 upgrade notes](https://argo-cd.readthedocs.io/en/latest/operator-manual/upgrading/2.1-2.2/#support-for-private-repo-ssh-keys-using-the-sha-1-signature-hash-algorithm-is-removed-in-2212) for details and workaround instructions.
### Bug fixes
- fix: create serviceaccount token for v1.24 clusters (#9546)
- fix: upgrade moment from 2.29.2 to 2.29.3 (#9330)
- fix: avoid CVE-2022-28948 (#10093)
### Other changes
- chore: Remove deprecated K8s versions from test matrix
- chore: Go mod tidy
- test: Remove circular symlinks from testdata (#9886)
- test: Fix e2e tests for release-2.2 branch
- chore: bump redoc vesion to avoid CVE-2021-23820 (#8604)
- chore(deps): bump moment from 2.29.3 to 2.29.4 in /ui (#9897)
- chore: upgrade moment to latest version to fix CVE (#9005)
- chore: move dependencies to dev dependencies (#8541)
- chore: update redis to 6.2.7 avoid CVE-2022-30065/CVE-2022-2097 (#10068)
- chore: upgrade Dex to 2.32.0 (#10036) (#10042)
- chore: update haproxy to 2.0.29 for redis-ha (#10045)
- test: check for error messages from CI env (#9953)
## v2.2.11 (2022-07-12)
### Security fixes
* HIGH: Certificate verification is skipped for connections to OIDC providers ([GHSA-7943-82jg-wmw5](https://github.com/argoproj/argo-cd/security/advisories/GHSA-7943-82jg-wmw5))
* LOW: A leaked API server encryption key can allow XSS for SSO users ([GHSA-pmjg-52h9-72qv](https://github.com/argoproj/argo-cd/security/advisories/GHSA-pmjg-52h9-72qv))
### Potentially-breaking changes
The fix for GHSA-7943-82jg-wmw5 enables TLS certificate validation by default for connections to OIDC providers. If
connections to your OIDC provider fails validation, SSO will be broken for your Argo CD instance. You should test 2.2.11
before upgrading it to production. From the new documentation:
> By default, all connections made by the API server to OIDC providers (either external providers or the bundled Dex
> instance) must pass certificate validation. These connections occur when getting the OIDC provider's well-known
> configuration, when getting the OIDC provider's keys, and when exchanging an authorization code or verifying an ID
> token as part of an OIDC login flow.
>
> Disabling certificate verification might make sense if:
> * You are using the bundled Dex instance **and** your Argo CD instance has TLS configured with a self-signed certificate
> **and** you understand and accept the risks of skipping OIDC provider cert verification.
> * You are using an external OIDC provider **and** that provider uses an invalid certificate **and** you cannot solve
> the problem by setting `oidcConfig.rootCA` **and** you understand and accept the risks of skipping OIDC provider cert
> verification.
>
> If either of those two applies, then you can disable OIDC provider certificate verification by setting
> `oidc.tls.insecure.skip.verify` to `"true"` in the `argocd-cm` ConfigMap.
### Features
* feat: enable specifying root ca for oidc (#6712)
### Bug fixes
* fix: webhook typo in case of error in GetManifests (#9671)
## v2.2.10 (2022-06-21)
### Security fixes
* CRITICAL: External URLs for Deployments can include javascript ([GHSA-h4w9-6x78-8vrj](https://github.com/argoproj/argo-cd/security/advisories/GHSA-h4w9-6x78-8vrj))
* HIGH: Insecure entropy in PKCE/Oauth2/OIDC params ([GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v))
* MODERATE: DoS through large directory app manifest files ([GHSA-jhqp-vf4w-rpwq](https://github.com/argoproj/argo-cd/security/advisories/GHSA-jhqp-vf4w-rpwq))
* MODERATE: Symlink following allows leaking out-of-bounds YAML files from Argo CD repo-server ([GHSA-q4w5-4gq2-98vm](https://github.com/argoproj/argo-cd/security/advisories/GHSA-q4w5-4gq2-98vm))
### Potentially-breaking changes
From the [GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v) description:
> The patch introduces a new `reposerver.max.combined.directory.manifests.size` config parameter, which you should tune before upgrading in production. It caps the maximum total file size of .yaml/.yml/.json files in directory-type (raw manifest) Applications. The default max is 10M per Application. This max is designed to keep any single app from consuming more than 3G of memory in the repo-server (manifests consume more space in memory than on disk). The 300x ratio assumes a maliciously-crafted manifest file. If you only want to protect against accidental excessive memory use, it is probably safe to use a smaller ratio.
>
> If your organization uses directory-type Applications with very many manifests or very large manifests then check the size of those manifests and tune the config parameter before deploying this change to production. When testing, make sure to do a "hard refresh" in either the CLI or UI to test your directory-type App. That will make sure you're using the new max logic instead of relying on cached manifest responses from Redis.
### Bug fixes
* fix: missing Helm params (#9565) (#9566)
### Other
* test: directory app manifest generation (#9503)
* test: fix erroneous test change
* chore: eliminate go-mpatch dependency (#9045)
* chore: Make unit tests run on platforms other than amd64 (#8995)
* chore: remove obsolete repo-server unit test (#9559)
* chore: upgrade golangci-lint to v1.46.2 (#9448)
* chore: update golangci-lint (#8988)
## v2.2.9 (2022-05-18)
### Notes
This is a security release. We urge all users of the 2.2.z branch to update as soon as possible. Please refer to the _Security fixes_ section below for more details.
### Security fixes
- CRITICAL: Argo CD will trust invalid JWT claims if anonymous access is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-r642-gv9p-2wjj)
- LOW: Login screen allows message spoofing if SSO is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-xmg8-99r8-jc2j)
- MODERATE: Symlink following allows leaking out-of-bound manifests and JSON files from Argo CD repo-server (https://github.com/argoproj/argo-cd/security/advisories/GHSA-6gcg-hp2x-q54h)
## v2.2.8 (2022-03-22)
### Special notes
This release contains the fix for a security issue with critical severity. We recommend users on the 2.2 release branch to update to this release as soon as possible.
As part of the security fix, the Argo CD UI no longer automatically presents child resources of allow-listed resources unless the child resources are also allow-listed. For example, Pods are not going to show up if only Deployment is added to the allow-list.
If you have [projects](https://argo-cd.readthedocs.io/en/stable/user-guide/projects/) configured with allow-lists, make sure the allow-lists include all the resources you want users to be able to view/manage through the UI. For example, if your project allows `Deployments`, you would add `ReplicaSets` and `Pods`.
#### Bug Fixes
- fix: application resource APIs must enforce project restrictions
## v2.2.7 (2022-03-08)
### Bug Fixes
- fix: correct jsonnet paths resolution (#8721)
## v2.2.6 (2022-03-06)
### Bug Fixes
- fix: prevent file traversal using helm file values param and application details api (#8606)
- feat: support custom helm values file schemes (#8535)
## v2.2.5 (2022-02-04)
- fix: Resolve symlinked value files correctly (#8387)
## v2.2.4 (2022-02-03)
### Special notes
This release contains the fix for a security issue with high severity. We recommend users on the 2.2 release branch to update to this release as soon as possible.
The project scoped repositories andclusters is a feature that simplifies registering the repositories and cluster credentials.
Instead of requiring operators to set up in advance all clusters and git repositories that can be used, developers can now do
this on their own in a self-service manner.
### Config Management PluginsV2
The Config Management PluginsV2 is set of enhancement of the existing config management plugins feature.
The list includes improved installation experience, ability to package plugin into a separate image and
improved plugin manifests discovery.
### Resource tracking
Argo CD has traditionally tracked the resources it manages by the well-known "app.kubernetes.io/instance" property.
While using this property works ok in simple scenarios, it also has several limitations. ArgoCD now allows you to use
a new annotation (argocd.argoproj.io/tracking-id) for tracking your resources. Using this annotation is a much more flexible approach
as there are no conflicts with other Kubernetes tools, and you can easily install multiple Argo CD instances on the same clusters.
### Bug Fixes and Performance Enhancements
* Argo CD API server caches RBAC checks that significantly improves the GET /api/v1/applications API performance (#7587)
* Argo CD RBAC supports regex matches (#7165)
* Health check support for KubeVirt (#7176), Cassandra (#7017), Openshift Route (#7112), DeploymentConfig (#7114), Confluent (#6957) and SparkApplication (#7434) CRDs.
* Persistent banner (#7312) with custom positioning (#7462)
* Cluster name support in project destinations (#7198)
* around 30 more features and a total of 84 bug fixes
## v2.1.16 (2022-06-21)
### Security fixes
* CRITICAL: External URLs for Deployments can include javascript ([GHSA-h4w9-6x78-8vrj](https://github.com/argoproj/argo-cd/security/advisories/GHSA-h4w9-6x78-8vrj))
* HIGH: Insecure entropy in PKCE/Oauth2/OIDC params ([GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v))
* MODERATE: DoS through large directory app manifest files ([GHSA-jhqp-vf4w-rpwq](https://github.com/argoproj/argo-cd/security/advisories/GHSA-jhqp-vf4w-rpwq))
* MODERATE: Symlink following allows leaking out-of-bounds YAML files from Argo CD repo-server ([GHSA-q4w5-4gq2-98vm](https://github.com/argoproj/argo-cd/security/advisories/GHSA-q4w5-4gq2-98vm))
**Note:** This will be the last security fix release in the 2.1.x series. Please [upgrade to a newer minor version](https://argo-cd.readthedocs.io/en/latest/operator-manual/upgrading/overview/) to continue to get security fixes.
### Potentially-breaking changes
From the [GHSA-2m7h-86qq-fp4v](https://github.com/argoproj/argo-cd/security/advisories/GHSA-2m7h-86qq-fp4v) description:
> The patch introduces a new `reposerver.max.combined.directory.manifests.size` config parameter, which you should tune before upgrading in production. It caps the maximum total file size of .yaml/.yml/.json files in directory-type (raw manifest) Applications. The default max is 10M per Application. This max is designed to keep any single app from consuming more than 3G of memory in the repo-server (manifests consume more space in memory than on disk). The 300x ratio assumes a maliciously-crafted manifest file. If you only want to protect against accidental excessive memory use, it is probably safe to use a smaller ratio.
>
> If your organization uses directory-type Applications with very many manifests or very large manifests then check the size of those manifests and tune the config parameter before deploying this change to production. When testing, make sure to do a "hard refresh" in either the CLI or UI to test your directory-type App. That will make sure you're using the new max logic instead of relying on cached manifest responses from Redis.
### Bug fixes
* fix: missing Helm params (#9565) (#9566)
### Other
* test: directory app manifest generation (#9503)
* test: fix erroneous test change
* chore: eliminate go-mpatch dependency (#9045)
* chore: Make unit tests run on platforms other than amd64 (#8995)
* chore: remove obsolete repo-server unit test (#9559)
* chore: upgrade golangci-lint to v1.46.2 (#9448)
* chore: update golangci-lint (#8988)
* test: fix ErrorContains (#9445)
## v2.1.15 (2022-05-18)
### Notes
This is a security release. We urge all users of the 2.1.z branch to update as soon as possible. Please refer to the _Security fixes_ section below for more details.
### Security fixes
- CRITICAL: Argo CD will trust invalid JWT claims if anonymous access is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-r642-gv9p-2wjj)
- LOW: Login screen allows message spoofing if SSO is enabled (https://github.com/argoproj/argo-cd/security/advisories/GHSA-xmg8-99r8-jc2j)
- MODERATE: Symlink following allows leaking out-of-bound manifests and JSON files from Argo CD repo-server (https://github.com/argoproj/argo-cd/security/advisories/GHSA-6gcg-hp2x-q54h)
## v2.1.14 (2022-03-22)
### Special notes
This release contains the fix for a security issue with critical severity. We recommend users on the 2.1 release branch to update to this release as soon as possible.
As part of the security fix, the Argo CD UI no longer automatically presents child resources of allow-listed resources unless the child resources are also allow-listed. For example, Pods are not going to show up if only Deployment is added to the allow-list.
If you have [projects](https://argo-cd.readthedocs.io/en/stable/user-guide/projects/) configured with allow-lists, make sure the allow-lists include all the resources you want users to be able to view/manage through the UI. For example, if your project allows `Deployments`, you would add `ReplicaSets` and `Pods`.
#### Bug Fixes
- fix: application resource APIs must enforce project restrictions
## v2.1.13 (2022-03-22)
Unused release number.
## v2.1.12 (2022-03-08)
### Bug Fixes
- fix: correct jsonnet paths resolution (#8721)
## v2.1.11 (2022-03-06)
### Bug Fixes
- fix: prevent file traversal using helm file values param and application details api (#8606)
- feat: support custom helm values file schemes (#8535)
## v2.1.10 (2022-02-04)
### Bug Fixes
- fix: Resolve symlinked value files correctly (#8387)
## v2.1.9 (2022-02-03)
### Special notes
This release contains the fix for a security issue with high severity. We recommend users on the 2.1 release branch to update to this release as soon as possible.
- fix: /api/version should not return tools version for unauthenticated requests (#5415)
- fix: account tokens should be rejected if required capability is disabled (#5414)
@@ -753,7 +1589,7 @@ More documentation and tools are coming in patch releases.
The Argo CD deletes all **in-flight** hooks if you terminate running sync operation. The hook state assessment change implemented in this release the Argo CD enables detection of
an in-flight state for all Kubernetes resources including `Deployment`, `PVC`, `StatefulSet`, `ReplicaSet` etc. So if you terminate the sync operation that has, for example,
`StatefulSet` hook that is `Progressing` it will be deleted. The long-running jobs are not supposed to be used as a sync hook and you should consider using
* User Community meeting: [Every other Wednesday](https://calendar.google.com/calendar/u/0/embed?src=argoproj@gmail.com) | [Agenda](https://docs.google.com/document/d/1xkoFkVviB70YBzSEa4bDnu-rUZ1sIFtwKKG1Uw8XsY8)
* User Community meeting: [First Wednesday of the month](https://calendar.google.com/calendar/u/0/embed?src=argoproj@gmail.com) | [Agenda](https://docs.google.com/document/d/1ttgw98MO45Dq7ZUHpIiOIEfbyeitKHNfMjbY5dLLMKQ)
Participation in the Argo CD project is governed by the [CNCF Code of Conduct](https://github.com/cncf/foundation/blob/master/code-of-conduct.md)
@@ -46,6 +43,7 @@ Participation in the Argo CD project is governed by the [CNCF Code of Conduct](h
### Blogs and Presentations
1. [Awesome-Argo: A Curated List of Awesome Projects and Resources Related to Argo](https://github.com/terrytangyuan/awesome-argo)
1. [Unveil the Secret Ingredients of Continuous Delivery at Enterprise Scale with Argo CD](https://blog.akuity.io/unveil-the-secret-ingredients-of-continuous-delivery-at-enterprise-scale-with-argo-cd-7c5b4057ee49)
1. [GitOps Without Pipelines With ArgoCD Image Updater](https://youtu.be/avPUQin9kzU)
1. [Combining Argo CD (GitOps), Crossplane (Control Plane), And KubeVela (OAM)](https://youtu.be/eEcgn_gU3SM)
1. [How to Apply GitOps to Everything - Combining Argo CD and Crossplane](https://youtu.be/yrj4lmScKHQ)
@@ -72,3 +70,6 @@ Participation in the Argo CD project is governed by the [CNCF Code of Conduct](h
1. [Solving configuration drift using GitOps with Argo CD](https://www.cncf.io/blog/2020/12/17/solving-configuration-drift-using-gitops-with-argo-cd/)
1. [Decentralized GitOps over environments](https://blogs.sap.com/2021/05/06/decentralized-gitops-over-environments/)
1. [How GitOps and Operators mark the rise of Infrastructure-As-Software](https://paytmlabs.com/blog/2021/10/how-to-improve-operational-work-with-operators-and-gitops/)
1. [Getting Started with ArgoCD for GitOps Deployments](https://youtu.be/AvLuplh1skA)
1. [Using Argo CD & Datree for Stable Kubernetes CI/CD Deployments](https://youtu.be/17894DTru2Y)
// If the finalizer length changed (due to filtering out an Argo finalizer), update the finalizer list on the app
iflen(newFinalizers)!=len(app.Finalizers){
app.Finalizers=newFinalizers
r.Recorder.Eventf(&applicationSet,corev1.EventTypeNormal,"Updated","Updated Application %q finalizer before deletion, because application has an invalid destination",app.Name)
appLog.Log(log.InfoLevel,"Updating application finalizer before deletion, because application has an invalid destination")
# How the Cluster Decision Resource generator works for clusterDecisionResource
1. The Cluster Decision Resource generator reads a configurable status format:
```yaml
status:
clusters:
- name:cluster-01
- name:cluster-02
```
This is a common status format. Another format that could be read looks like this:
```yaml
status:
decisions:
- clusterName:cluster-01
namespace:cluster-01
- clusterName:cluster-02
namespace:cluster-02
```
2. Any resource that has a list of key / value pairs, where the value matches ArgoCD cluster names can be used.
3. The key / value pairs found in each element of the list will be available to the template. As well, `name` and `server` will still be available to the template.
4. The Service Account used by the ApplicationSet controller must have access to `Get` the resource you want to retrieve the duck type definition from
5. A configMap is used to identify the resource to read status of generated ArgoCD clusters from. You can use multiple resources by creating a ConfigMap for each one in the ArgoCD namespace.
```yaml
apiVersion:v1
kind:ConfigMap
metadata:
name:my-configmap
data:
apiVersion:group.io/v1
kind:mykinds
statusListKey:clusters
matchKey:name
```
*`apiVersion` - This is the apiVersion of your resource
*`kind` - This is the plural kind of your resource
*`statusListKey` - Default is 'clusters', this is the key found in your resource's status that is a list of ArgoCD clusters.
*`matchKey` - Is the key name found in the cluster list, `name` and `clusterName` are the keys in the examples above.
# Applying the example
1. Connect to a cluster with the ApplicationSet controller running
2. Edit the Role for the ApplicationSet service account, and grant it permission to `list` the `placementdecisions` resources, from apiGroups `cluster.open-cluster-management.io/v1alpha1`
```yaml
- apiGroups:
- "cluster.open-cluster-management.io/v1alpha1"
resources:
- placementdecisions
verbs:
- list
```
3. Apply the following controller and associated ManagedCluster CRD's:
# Reference to a Secret containing an access token. (optional)
tokenRef:
secretName:github-token
key:token
# Labels is used to filter the PRs that you want to target. (optional)
labels:
- preview
template:
metadata:
name:'myapp-{{ .branch }}-{{ .number }}'
spec:
source:
repoURL:'https://github.com/myorg/myrepo.git'
targetRevision:'{{ .head_sha }}'
path:helm-guestbook
helm:
parameters:
- name:"image.tag"
value:"pull-{{ .head_sha }}"
project:default
destination:
server:https://kubernetes.default.svc
namespace:"{{ .branch }}-{{ .number }}"
syncPolicy:
syncOptions:
- CreateNamespace=true
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.