Impact of Changing the Project Field in an ApplicationSet
When the project
field is modified in an Argo CD ApplicationSet
manifest that manages multiple applications (e.g., for dev, non-prod, and prod environments), the change will not trigger a re-deployment of the applications.
-
Instead, the
project
reference in each managedApplication
is updated in place. -
There is no removal or recreation of the applications.
-
The application sync status remains unchanged unless other fields affecting deployment (e.g., source or destination) are altered.
Requirement to Pre-Create Argo CD Projects
Before applying the ApplicationSet
, the referenced Argo CD AppProject
must already exist. If it does not, the ApplicationSet
controller will fail to generate valid applications and will report an error due to the missing project reference.
Creating Projects Programmatically Using Argo CD API
Projects can be created programmatically using the Argo CD REST API:
-
Endpoint:
POST /api/v1/projects
-
This endpoint accepts a JSON representation of the
AppProject
manifest. -
Authentication is required via an Argo CD API token or session cookie.
The OpenAPI documentation for your instance is accessible at:
<ARGOCD-URL>/swagger-ui
Or via the Argo CD UI under "Documentation" → "Open The API Docs".