* fix multi-source refresh
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* serialize nil and empty resolvedRevisions the same to avoid cache misses
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* more consistent naming
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* document duplication
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* add todo
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
---------
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* feat: add support for plugin name in cmpV2
Signed-off-by: Soumya Ghosh Dastidar <gdsoumya@gmail.com>
* feat: updated e2e test to use name for CMPv2 plugin
Signed-off-by: Soumya Ghosh Dastidar <gdsoumya@gmail.com>
* docs: updated docs
Signed-off-by: Soumya Ghosh Dastidar <gdsoumya@gmail.com>
* fix: check whether final socket path is inside sock dir or not
Signed-off-by: Soumya Ghosh Dastidar <gdsoumya@gmail.com>
Signed-off-by: Soumya Ghosh Dastidar <gdsoumya@gmail.com>
* feat: parameterized CMPs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* values types for parameters
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Add types for CMP announcement
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Reorg
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* finish type
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* First pass at working GetParametersAnnouncement
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Typos
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Make all fields optional
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Make sure response makes it to repo server
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Refactor for testing
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* send build env to param announcement gen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* test parameter announcement
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* environ tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Rename workdir to app dir
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* handle empty command, start ui work (#11)
* Add types for CMP announcement
Signed-off-by: zachaller <zachaller@hotmail.com>
* Reorg
Signed-off-by: zachaller <zachaller@hotmail.com>
* finish type
Signed-off-by: zachaller <zachaller@hotmail.com>
* First pass at working GetParametersAnnouncement
Signed-off-by: zachaller <zachaller@hotmail.com>
* Typos
Signed-off-by: zachaller <zachaller@hotmail.com>
* Make all fields optional
Signed-off-by: zachaller <zachaller@hotmail.com>
* Make sure response makes it to repo server
Signed-off-by: zachaller <zachaller@hotmail.com>
* Refactor for testing
Signed-off-by: zachaller <zachaller@hotmail.com>
* values types for parameters
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* send build env to param announcement gen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* test parameter announcement
* tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* environ tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Rename workdir to app dir
Signed-off-by: zachaller <zachaller@hotmail.com>
* handle empty command, start ui work
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix order
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix map merging, make params read-only
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Co-authored-by: zachaller <zachaller@hotmail.com>
* Add helm PoC example plugin
Signed-off-by: zachaller <zachaller@hotmail.com>
* example as kustomize overlay
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* Parameterized cmps docs (#12)
* use printf instead of echo
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* test for temp dir cleanup
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* handle empty params
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* handle empty values
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* consolidate types
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* remove duplicate info
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* add warning about param announcements vs param values
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* tests (#13)
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* tests
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix types
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix test
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix codegen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix codegen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* revert test hack
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* docs correction
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix indentation
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* fix spacing
Signed-off-by: CI <michael@crenshaw.dev>
* move util function to util file and add test
Signed-off-by: CI <michael@crenshaw.dev>
* wrap error
Signed-off-by: CI <michael@crenshaw.dev>
* correct version number
Signed-off-by: CI <michael@crenshaw.dev>
* document necessity of collectionType param
Signed-off-by: CI <michael@crenshaw.dev>
* remove part of error message that's not useful (dir name is now randomized)
Signed-off-by: CI <michael@crenshaw.dev>
* fix things so that they are not broken
Signed-off-by: CI <michael@crenshaw.dev>
* don't close file before caller gets a chance to use it
Signed-off-by: CI <michael@crenshaw.dev>
* codegen
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* fix test
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* comments
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* fix test
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* DON'T PANIC
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
Signed-off-by: zachaller <zachaller@hotmail.com>
Signed-off-by: CI <michael@crenshaw.dev>
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
Co-authored-by: zachaller <zachaller@hotmail.com>
* Add wildcard support in OCI Helm Repositories
A naive approach, adapting existing code for fetching the index.
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Fix unittest missing mock
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Fix release resolution also in Manual Sync dialog
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Show target revision in application list. Tiles and Table updated
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Follow Link rel=next in tags response for tag list completion (signed)
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Wrap errors into fmt.Errorf according to PR review
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Address PR comments, add test for tags MaxVersion and pagination
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Apply suggestions from code review
Co-authored-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* more feedback from pr
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Revert url.JoinPath change - only available in 1.19
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* use strings.Join. add unittest
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Safe access to app.status.sync object
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Remove status.revision from UI. It doesn't bring much value and it does clutter the ui a bit
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
* Update util/helm/client.go
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* Update util/helm/client.go
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
Signed-off-by: Alex Eftimie <alex.eftimie@getyourguide.com>
Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
Co-authored-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
* docs: note one single CMP per app
Signed-off-by: Artur Rodrigues <artur.rodrigues@lacework.net>
* cmp: debug logs around manifest handling
Signed-off-by: Artur Rodrigues <artur.rodrigues@lacework.net>
Signed-off-by: Artur Rodrigues <artur.rodrigues@lacework.net>
* 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>
* chore: deprecate argocd-cm plugins (#8117)
Signed-off-by: CI <michael@crenshaw.dev>
* more warnings
Signed-off-by: CI <michael@crenshaw.dev>
* more warnings
Signed-off-by: CI <michael@crenshaw.dev>
Signed-off-by: CI <michael@crenshaw.dev>
* 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>
* fix: CMP manifest generation fails with ENHANCE_YOUR_CALM if over 40s
Signed-off-by: notfromstatefarm <86763948+notfromstatefarm@users.noreply.github.com>
* fix timeouts across all gRPC servers
Signed-off-by: notfromstatefarm <86763948+notfromstatefarm@users.noreply.github.com>
* use common consts
Signed-off-by: notfromstatefarm <86763948+notfromstatefarm@users.noreply.github.com>
* 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>
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
defer instead of multiple close calls
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
oops
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
don't count jsonnet against max
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
fix codegen
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
add caveat about 300x ratio
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
fix versions
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
fix tests/lint
Signed-off-by: Michael Crenshaw <michael@crenshaw.dev>
* 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>
* 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: 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>
* 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: 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>
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: 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>
* 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>
* 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>
* 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>
* 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>
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>
* fix: repository name already exists when multiple helm dependencies from same private repo server
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: add test cases
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: clean up
Signed-off-by: May Zhang <may_zhang@intuit.com>
* feat: add first class support to access repositories using proxy
Currently, users need to set the proxy URLs as env variables in the repo server. This is not user-friendly and also error-prone. This PR adds support to maintain proxy URLs along with repository configs in the argocd-cm. Argo CD uses this proxy to access your repository. In case the custom proxy is absent, it defaults to reading the proxy from the env variables.
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* set both http & https proxy variables
Signed-off-by: Chetan Banavikalmutt <chetanrns1997@gmail.com>
* fix: add helm dependecies with custom CA
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* fixed go lint error
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* ignore existing repos
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* fix: Enable helm OCI to work for lots of different URLs without having to create a repo for each one
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: Enable helm OCI to work for lots of different URLs without having to create a repo for each one
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: lint
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: lint
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: fix test code
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: dependency add for https and oci
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: go.sum and install.yaml
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: fix checking if repo exits
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: fix generated files
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: fix go.mod and go.sum
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: clean up code
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: rename RepoCreds to HelmRepoCreds
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: Added type for repoCreds.
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: checking in install.yaml
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: checking in install.yaml
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: checking in install.yaml
Signed-off-by: May Zhang <may_zhang@intuit.com>
* fix: Makefile
Signed-off-by: May Zhang <may_zhang@intuit.com>
Co-authored-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* fix: add helm dependecies with custom CA
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* fixed go lint error
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* ignore existing repos
Signed-off-by: Shubham Agarwal <shubhamagarawal19@gmail.com>
* fix: Enable helm OCI to work for lots of different URLs without having to create a repo for each one
Signed-off-by: May Zhang <may_zhang@intuit.com>
* Revert "fix: Enable helm OCI to work for lots of different URLs without having to create a repo for each one"
This reverts commit a8ae8cf1b9.
* fix: only adding the dependency repo which does not exist in the repo list
Co-authored-by: May Zhang <may_zhang@intuit.com>
* fix: consistently display information about 'compared to' and 'synced to' revisions
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* apply review notes
Signed-off-by: Alexander Matyushentsev <AMatyushentsev@gmail.com>
* chore: Upgrade go-jsonnet to v0.17.0
Signed-off-by: Maxime Brunet <max@brnt.mx>
* Fix vm.EvaluateSnippet is deprecated
Use EvaluateFile or EvaluateAnonymousSnippet instead.
Signed-off-by: Maxime Brunet <max@brnt.mx>
* Do not read Jsonnet files
Signed-off-by: Maxime Brunet <max@brnt.mx>
* chore: Add a GitHub action that runs unit tests with -race to CI build (#4774)
Signed-off-by: Jonathan West <jonwest@redhat.com>
* chore: Add a GitHub action that runs unit tests with -race to CI build (#4774)
Signed-off-by: Jonathan West <jonwest@redhat.com>
* fix: failUnmarshal only checked for file contains information which has apiVersion, kind and metadata.
Signed-off-by: May Zhang <may_zhang@intuit.com>
* add negative test case
Signed-off-by: May Zhang <may_zhang@intuit.com>
* modified negative test data
Signed-off-by: May Zhang <may_zhang@intuit.com>
* modified negative test data
Signed-off-by: May Zhang <may_zhang@intuit.com>
* feat: Add autocomplete for repo Revisions
- Introduces api/v1/repositories/{repo}/refs which returns branches and tags
- Add new RevisionFormField component to Create and Edit Application pages
Signed-off-by: Tim Etchells <tetchell@redhat.com>
* chore: Replace deprecated set-env directives
* revert lint version change
* Revert go.mod and go.sum changes
* Fix typo
* Update golangci-lint-action to v2
* Fix golangci-lint version
* Skip new lint complaints in test
* Skip more new lint complaints in test
* Exclude new SA5011 check in lint
Newer versions of the redis go libraries include built-in support for
compression of values going to and from redis. Since the controller
is extremely chatty and makes heavy use of redis for caching, this
reduces the amount of bandwidth requires significantly.
This change should be backwards compatible since the redis libraries
detect whether or not compression was used and does not error in the
no compression case.
Fixes#4256
This commit adds support for configurable Helm version either via
declarative syntax or via argocd cli.
New helm option 'Version' added to the ApplicationSourceHelm
struct which can be either 'v2' or 'v3'.
Argocd app create accepts '--helm-version' that also looks for the
same Helm versions as above.
* feat: added Libs field to ApplicationSourceJsonnet
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: codegen
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: implemented jsonnet jpath arguments
- Implement the `-J` command line flag for jsonnet
- adapt test to include a nested library for testing the VM
functionality
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: jsonnet import path relative to the repoRoot
- adapted testCase to make use of a jpath
- join repoRoot and provided jpath attributes
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* fix: added checking for out-of-repoRoot references
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: Added CLI option for passing jsonnet libs
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: Updated jsonnet docs
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* fix: renamed function
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* feat: Expose --local-repo-root flag
Allows passing a "virtal" git repository root when using the local sync
mode with --local.
Provides backwardscompatible with the previous default value ("/")
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* fix: added missing command
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* Remove obsolete line out of docs
Signed-off-by: Matthias Riegler <matthias.riegler@taotesting.com>
* Add initial primitives and tests for GPG related operations
* More tests and test documentation
* Move gpg primitives to own module
* Add initial primitives for running git verify-commit and tests
* Improve and better comment test
* Implement VerifyCommitSignature() primitive for metrics wrapper
* More commentary
* Make reposerver verify gpg signatures when generating manifests
* Make signature validation optional
* Forbid use of local manifests when signature verification is enabled
* Introduce new signatureKeys field in project CRD
* Initial support for only syncing against signed revisions
* Updates to GnuPG primitives and more test cases
* Move signature verification to correct place and add tests
* Add signature verification result to revision metadata and display it in UI
* Add more primitives and move out some stuff to common module
* Add more testdata
* Add key management primitives to ArgoDB
* Move type GnuPGPublicKey to appsv1 package
* Add const ArgoCDGPGKeysConfigMapName
* Handle key operations with appsv1.GnuPGPublicKey
* Add initial API for managing GPG keys
* Remove deprecated code
* Add primitives for adding public keys to configuration
* Change semantics of ValidateGPGKeys to return more key information
* Add key import functionality to public key API
* Fix code quirks reported by linter
* More code quirks fixes
* Fix test
* Add primitives for deleting keys from configuration
* Add delete key operation to API and CLI
* Cosmetics
* Implement logic to sync configuration to keyring in repo-server
* Add IsGPGEnabled() primitive and also update trustdb on ownertrust changes
* Use gpg.IsGPGEnabled() instead of custom test
* Remove all keyring manipulating methods from DB
* Cosmetics/comments
* Require grpc methods from argoproj pkg
* Enable setting config path via ARGOCD_GPG_DATA_PATH
* Allow "no" and any cases in ARGOCD_GPG_ENABLED
* Enable GPG feature on start and start-e2e and set required environment
* Cosmetics/comments
* Cosmetics and commentary
* Update API documentation
* Fix comment
* Only run GPG related operations if GPG is enabled
* Allow setting ARGOCD_GPG_ENABLE from the environment
* Create GPG ConfigMap resource during installation
* Use function instead of constant to get the watcher path
* Re-watch source path in case it gets recreated. Also, error on finish
* Add End-to-End tests for GPG commit verification
* Introduce SignatureKey type for AppProject CRD
* Fix merge error from previous commit
* Adapt test for additional manifest (argocd-gpg-keys-cm.yaml)
* Fix linter issues
* Adapt CircleCI configuration to enable running tests
* Add wrapper scripts for git and gpg
* Sigh.
* Display gpg version in CircleCI
* Install gnupg2 and link it to gpg in CI
* Try to install gnupg2 in CircleCI image
* More CircleCI tweaks
* # This is a combination of 10 commits.
# This is the 1st commit message:
Containerize tests - test cycle
# This is the commit message #2:
adapt working directory
# This is the commit message #3:
Build before running tests (so we might have a cache)
# This is the commit message #4:
Test limiting parallelism
# This is the commit message #5:
Remove unbound variable
# This is the commit message #6:
Decrease parallelism to find out limit
# This is the commit message #7:
Use correct flag
# This is the commit message #8:
Update Docker image
# This is the commit message #9:
Remove build phase and increase parallelism
# This is the commit message #10:
Further increase parallelism
* Dockerize toolchain
* Add new targets to Makefile
* Codegen
* Properly handle permissions for E2E tests
* Remove gnupg2 installation from CircleCI configuration
* Limit parallelism of build
* Fix Yarn lint
* Retrigger CI for possible flaky test
* Codegen
* Remove duplicate target in Makefile
* Pull in pager from dep ensure -v
* Adapt to gitops-engine changes and codegen
* Use new health package for health status constants
* Add GPG methods to ArgoDB mock module
* Fix possible nil pointer dereference
* Fix linter issue in imports
* Introduce RBAC resource type 'gpgkeys' and adapt policies
* Use ARGOCD_GNUPGHOME instead of GNUPGHOME for subsystem configuration
Also remove some deprecated unit tests.
* Also register GPG keys API with gRPC-GW
* Update from codegen
* Update GPG key API
* Add web UI to manage GPG keys
* Lint updates
* Change wording
* Add some plausibility checks for supplied data on key creation
* Update from codegen
* Re-allow binary keys and move check for ASCII armoured to UI
* Make yarn lint happy
* Add editing signature keys for projects in UI
* Add ability to configure signature keys for project in CLI
* Change default value to use for GNUPGHOME
* Do not include data section in default gpg keys CM
* Adapt Docker image for GnuPG feature
* Add required configuration to installation manifests
* Add add-signature-key and remove-signature-key commands to project CLI
* Fix typo
* Add initial user documentation for GnuPG verification
* Fix role name - oops
* Mention required RBAC roles in docs
* Support GPG verification of git annotated tags as well
* Ensure CLI can build succesfully
* Better support verification on tags
* Print key type in upper case
* Update user documentation
* Correctly disable GnuPG verification if ARGOCD_GPG_ENABLE=false
* Clarify that this feature is only available with Git repositories
* codegen
* Move verification code to own function
* Remove deprecated check
* Make things more developer friendly when running locally
* Enable GPG feature by default, and don't require ARGOCD_GNUPGHOME to be set
* Revert changes to manifests to reflect default enable state
* Codegen
* Move utils packages that are required for gitops engine under engine/pkg/utils package.
Following changes were implemented:
* util/health package is split into two parts: resource health assessement & resource health assessement and moved into engine/pkg/utils
* utils packages moved: Closer and Close method of util package moved into engine/pkg/utils/io package
* packages diff, errors, exec, json, kube and tracing moved into engine/pkg/utils
* Move single cluster caching into engine/kube/cache package
* move sync functionality to engine/kube/sync package
* remove dependency on metrics package from engine/pkg/utils/kube/cache
* move annotation label definitions into engine/pkg/utils/kube/sync
* make sure engine/pkg has no dependencies on other argo-cd packages
* allow importing engine as a go module
* implement a high-level interface that might be consumed by flux
* fix deadlock caused by cluster cache event handler
* ClusterCache should return error if requested group kind not found
* remove obsolete tests
* apply reviewer notes
* Fixing argocd app diff when using helm repo
* adding test code
* get rid of optional parameter
* get rid of optional parameter
* Added test case
* Fix failed tests
* ArgoCD plugin: add environment variable KUBEVERSION and KUBE_API_VERSIONS.
* Added test verification of KUBE_API_VERSION
* Using assert.EqualValues for assertion.
Necessary STDIN changes to support Windows
Added support for SE Linux
Informational message about linting OOM
Updated due to latest helm stable being 3.x
* Add support for hidden directories with directory enforcer
* Refactor
* Lint
* Rework done, still needs tests
* WIP
* Should be done
* Fix test
* Helm Charts
* Make directory enforcer more lenient and add flag
* Fixes
* Lint fixes
* Lint fixes
* Fixed test
* Minor
* Removed enforcer option
* Move directory traversal check higher up
* Go fmt
* Allow URLs
* Added test