How to create Project-level AppDeployments for use in multi-tenant logging

You must create AppDeployments in the Project namespace to enable and deploy the logging stack to all clusters within a Project. You can use the CLI to do this, or use the DKP UI to enable the logging applications.

To create the AppDeployments needed for Project-level logging, follow these steps on the management cluster:

  1. Determine the name and namespace of the workspace that your project is in. You can use the dkp get workspaces command to see the list of workspace names and their corresponding namespaces.

    dkp get workspaces
    CODE

    Copy the values under the NAME and NAMESPACE columns for your workspace.

  2. Export the WORKSPACE_NAME variable:

    export WORKSPACE_NAME=<WORKSPACE_NAME>
    CODE
  3. Export the WORKSPACE_NAMESPACE variable:

    export WORKSPACE_NAMESPACE=<WORKSPACE_NAMESPACE>
    CODE
  4. Execute the following command to get the namespace of your project:

    kubectl get projects -n ${WORKSPACE_NAMESPACE}
    CODE

    Copy the value under the NAME column for your project. This may NOT be identical to the Display Name of the Project.

  5. Export the PROJECT_NAME variable:

    export PROJECT_NAME=<PROJECT_NAME>
    CODE
  6. Copy these commands and execute them from a command line:

    dkp create appdeployment project-grafana-loki --app project-grafana-loki-0.48.3 --workspace ${WORKSPACE_NAME} --project ${PROJECT_NAME}
    dkp create appdeployment project-grafana-logging --app project-grafana-logging-6.28.0 --workspace ${WORKSPACE_NAME} --project ${PROJECT_NAME}
    CODE

Then, you can Verify the Project Logging Stack Installation for multi-tenant logging.