github.com/argoproj/argo-cd/v3@v3.2.1/docs/user-guide/commands/argocd_admin_proj_generate-spec.md (about)

     1  # `argocd admin proj generate-spec` Command Reference
     2  
     3  ## argocd admin proj generate-spec
     4  
     5  Generate declarative config for a project
     6  
     7  ```
     8  argocd admin proj generate-spec PROJECT [flags]
     9  ```
    10  
    11  ### Examples
    12  
    13  ```
    14    # Generate a YAML configuration for a project named "myproject"
    15    argocd admin proj generate-spec myproject
    16    
    17    # Generate a JSON configuration for a project named "anotherproject" and specify an output file
    18    argocd admin proj generate-spec anotherproject --output json --file config.json
    19    
    20    # Generate a YAML configuration for a project named "someproject" and write it back to the input file
    21    argocd admin proj generate-spec someproject --inline
    22  ```
    23  
    24  ### Options
    25  
    26  ```
    27        --allow-cluster-resource stringArray      List of allowed cluster level resources
    28        --allow-namespaced-resource stringArray   List of allowed namespaced resources
    29        --deny-cluster-resource stringArray       List of denied cluster level resources
    30        --deny-namespaced-resource stringArray    List of denied namespaced resources
    31        --description string                      Project description
    32    -d, --dest stringArray                        Permitted destination server and namespace (e.g. https://192.168.99.100:8443,default)
    33        --dest-service-accounts stringArray       Destination server, namespace and target service account (e.g. https://192.168.99.100:8443,default,default-sa)
    34    -f, --file string                             Filename or URL to Kubernetes manifests for the project
    35    -h, --help                                    help for generate-spec
    36    -i, --inline                                  If set then generated resource is written back to the file specified in --file flag
    37        --orphaned-resources                      Enables orphaned resources monitoring
    38        --orphaned-resources-warn                 Specifies if applications should have a warning condition when orphaned resources detected
    39    -o, --output string                           Output format. One of: json|yaml (default "yaml")
    40        --signature-keys strings                  GnuPG public key IDs for commit signature verification
    41        --source-namespaces strings               List of source namespaces for applications
    42    -s, --src stringArray                         Permitted source repository URL
    43  ```
    44  
    45  ### Options inherited from parent commands
    46  
    47  ```
    48        --argocd-context string           The name of the Argo-CD server context to use
    49        --auth-token string               Authentication token; set this or the ARGOCD_AUTH_TOKEN environment variable
    50        --client-crt string               Client certificate file
    51        --client-crt-key string           Client certificate key file
    52        --config string                   Path to Argo CD config (default "/home/user/.config/argocd/config")
    53        --controller-name string          Name of the Argo CD Application controller; set this or the ARGOCD_APPLICATION_CONTROLLER_NAME environment variable when the controller's name label differs from the default, for example when installing via the Helm chart (default "argocd-application-controller")
    54        --core                            If set to true then CLI talks directly to Kubernetes instead of talking to Argo CD API server
    55        --grpc-web                        Enables gRPC-web protocol. Useful if Argo CD server is behind proxy which does not support HTTP2.
    56        --grpc-web-root-path string       Enables gRPC-web protocol. Useful if Argo CD server is behind proxy which does not support HTTP2. Set web root.
    57    -H, --header strings                  Sets additional header to all requests made by Argo CD CLI. (Can be repeated multiple times to add multiple headers, also supports comma separated headers)
    58        --http-retry-max int              Maximum number of retries to establish http connection to Argo CD server
    59        --insecure                        Skip server certificate and domain verification
    60        --kube-context string             Directs the command to the given kube-context
    61        --logformat string                Set the logging format. One of: json|text (default "json")
    62        --loglevel string                 Set the logging level. One of: debug|info|warn|error (default "info")
    63        --plaintext                       Disable TLS
    64        --port-forward                    Connect to a random argocd-server port using port forwarding
    65        --port-forward-namespace string   Namespace name which should be used for port forwarding
    66        --prompts-enabled                 Force optional interactive prompts to be enabled or disabled, overriding local configuration. If not specified, the local configuration value will be used, which is false by default.
    67        --redis-compress string           Enable this if the application controller is configured with redis compression enabled. (possible values: gzip, none) (default "gzip")
    68        --redis-haproxy-name string       Name of the Redis HA Proxy; set this or the ARGOCD_REDIS_HAPROXY_NAME environment variable when the HA Proxy's name label differs from the default, for example when installing via the Helm chart (default "argocd-redis-ha-haproxy")
    69        --redis-name string               Name of the Redis deployment; set this or the ARGOCD_REDIS_NAME environment variable when the Redis's name label differs from the default, for example when installing via the Helm chart (default "argocd-redis")
    70        --repo-server-name string         Name of the Argo CD Repo server; set this or the ARGOCD_REPO_SERVER_NAME environment variable when the server's name label differs from the default, for example when installing via the Helm chart (default "argocd-repo-server")
    71        --server string                   Argo CD server address
    72        --server-crt string               Server certificate file
    73        --server-name string              Name of the Argo CD API server; set this or the ARGOCD_SERVER_NAME environment variable when the server's name label differs from the default, for example when installing via the Helm chart (default "argocd-server")
    74  ```
    75  
    76  ### SEE ALSO
    77  
    78  * [argocd admin proj](argocd_admin_proj.md)	 - Manage projects configuration
    79