Closed appiepollo14 closed 2 weeks ago
@appiepollo14 you can refer the steps here - https://argocd-operator.readthedocs.io/en/latest/developer-guide/development/#building-and-testing-locally
@saumeya I have thanks. The title is mentioned: 'Wip' which is in my opinion true as it looks not complete and guides me not into running the operator locally against a k8s cluster. Please check whether I'm overlooking or not.
Oh, not sure why it is WIP - the steps make install run
will work against a local k8s cluster, but I can check if maybe something more was intended and get back to you.
Our developer documentation is scattered, I think we should consolidate it in one place. I will take a look next week.
Below are some commands for local development till we get that sorted
# fetch deps
go mod tidy
go mod vendor
# run unit test
make test
# run operator locally
ARGOCD_REDIS_IMAGE=public.ecr.aws/docker/library/redis:6 make install run
# run all kuttl test
kubectl kuttl test tests/k8s/ --config tests/kuttl-tests.yaml
# run a single kuttl test
kubectl kuttl test tests/k8s/ --config tests/kuttl-tests.yaml --test 1-037_validate_applicationset_in_any_namespace
# generate manifests
make generate manifests
# generate bundle
# on mac, update the sed command in Makefile
# sed -i 's/control-plane..... -> sed -i '' 's/control-plane....
make bundle
# example ArgoCD
# argocd.yaml
apiVersion: argoproj.io/v1beta1
kind: ArgoCD
metadata:
name: example
spec: {}
# instructions to install operator using OLM
# https://github.com/argoproj-labs/argocd-operator/blob/master/tests/olm/README.md
# documentation generation
# https://github.com/argoproj-labs/argocd-operator/blob/master/docs/developer-guide/development.md#build-and-verify-argo-cd-operator-docs
@svghadi Do you want me to update the development.md and add the above steps?
Yes, please! That would be amazing! - @aali309
Is your task related to a problem? Please describe.
As a contributor, it is unclear to me how to run the operator locally. In particular how to run the kuttl tests against a running operator. Examining the ci-build workflow doesn't give an explanation either.
Describe the solution you'd like
Update the developer-guide docs in the docs folder to explain in detail, which steps / make commands should be run to run the operator locally for fast development cycles.