Migrar usando Gordon
Puedes usar Gordon para migrar automáticamente tu Dockerfile para usar Docker Hardened Images (DHI).
- Asegúrate de que Gordon esté habilitado.
- En la terminal, navega al directorio que contiene tu Dockerfile.
- Inicia una conversación con el asistente:
docker ai - Escribe:
"Migrate my dockerfile to DHI" - Sigue la conversación con el asistente. El asistente editará tu Dockerfile, por lo que cuando solicite acceso al sistema de archivos y demás, escribe
yespara permitir que el asistente continúe.
Cuando la migración se complete, verás un mensaje de éxito:
The migration to Docker Hardened Images (DHI) is complete. The updated Dockerfile
successfully builds the image, and no vulnerabilities were detected in the final image.
The functionality and optimizations of the original Dockerfile have been preserved.ImportantAl igual que con cualquier herramienta de IA, debes verificar las ediciones del asistente y probar tu imagen.