How to use docker scout integration delete command to remove an integration

DockerDockerBeginner
Practice Now

Introduction

In this lab, you will learn how to manage Docker Scout integrations by deleting them. You will begin by listing your existing Docker Scout integrations to identify the one you wish to remove.

Following that, you will use the docker scout integration rm command to delete a specific integration by its name. Finally, you will verify that the integration has been successfully removed by listing the integrations again.


Skills Graph

%%%%{init: {'theme':'neutral'}}%%%% flowchart RL docker(("Docker")) -.-> docker/ContainerOperationsGroup(["Container Operations"]) docker/ContainerOperationsGroup -.-> docker/ls("List Containers") docker/ContainerOperationsGroup -.-> docker/rm("Remove Container") subgraph Lab Skills docker/ls -.-> lab-555206{{"How to use docker scout integration delete command to remove an integration"}} docker/rm -.-> lab-555206{{"How to use docker scout integration delete command to remove an integration"}} end

List existing Docker Scout integrations

In this step, you will learn how to list existing Docker Scout integrations. Docker Scout helps you understand and improve the security posture of your container images. Integrations allow Docker Scout to connect with other services to gather information about your images.

To list the existing Docker Scout integrations, you can use the docker scout integration ls command. This command will display a table showing the name, type, and status of each configured integration.

Let's execute the command to see the current integrations. Open your terminal in the LabEx environment.

docker scout integration ls

You should see output similar to this, although the specific integrations listed may vary depending on your environment:

NAME      TYPE      STATUS
my-integration  my-type   ready

The output provides the following information for each integration:

  • NAME: The unique name of the integration.
  • TYPE: The type of integration (e.g., a specific registry or service).
  • STATUS: The current status of the integration (e.g., ready, error).

Understanding the existing integrations is the first step in managing them. In the next steps, you will learn how to delete an integration.

Delete a specific Docker Scout integration by name

In this step, you will learn how to delete a specific Docker Scout integration using its name. Deleting an integration removes the connection between Docker Scout and the external service.

To delete an integration, you use the docker scout integration rm command followed by the name of the integration you want to remove.

From the previous step, you should have seen the name of the integration you want to delete. Let's assume the integration name is my-integration. Replace my-integration with the actual name if it was different in your environment.

Execute the following command to delete the integration:

docker scout integration rm my-integration

If the command is successful, you will see output confirming the deletion, similar to this:

Integration 'my-integration' deleted

This confirms that the specified integration has been removed from your Docker Scout configuration. In the next step, you will verify that the integration is no longer listed.

Verify the integration has been deleted

In this step, you will verify that the Docker Scout integration you deleted in the previous step is no longer listed. This confirms that the deletion was successful.

To verify the deletion, you will again use the docker scout integration ls command to list the current integrations.

Execute the following command:

docker scout integration ls

After executing the command, observe the output. The integration named my-integration (or whatever name you used in the previous step) should no longer appear in the list. If no integrations are configured, the output might show only the table headers or indicate that no integrations are found.

For example, if my-integration was the only integration, the output might now look like this:

NAME      TYPE      STATUS

If other integrations were present, the output will list them, but my-integration should be absent. This confirms that the docker scout integration rm command successfully removed the integration.

You have now successfully listed, deleted, and verified the deletion of a Docker Scout integration.

Summary

In this lab, you learned how to manage Docker Scout integrations. You began by listing existing integrations using the docker scout integration ls command, which displays the name, type, and status of each configured integration.

Following that, you practiced deleting a specific integration by its name using the docker scout integration rm command. Finally, you verified that the integration was successfully removed by listing the integrations again, confirming that the deleted integration no longer appeared in the list.