refactor: docker volume prefix

This commit is contained in:
Nicolas Meienberger
2025-09-27 14:49:22 +02:00
parent 88e310cc4f
commit aa32ea322d
8 changed files with 29 additions and 24 deletions

View File

@@ -16,17 +16,17 @@ export const DockerTabContent = ({ volume }: Props) => {
services: {
nginx: {
image: "nginx:latest",
volumes: [`${volume.name}:/path/in/container`],
volumes: [`im-${volume.name}:/path/in/container`],
},
},
volumes: {
[volume.name]: {
[`im-${volume.name}`]: {
external: true,
},
},
});
const dockerRunCommand = `docker run -v ${volume.name}:/path/in/container nginx:latest`;
const dockerRunCommand = `docker run -v im-${volume.name}:/path/in/container nginx:latest`;
const containersQuery = getContainersUsingVolumeOptions({ path: { name: volume.name } });
const { data: containersData, isLoading, error } = useQuery(containersQuery);