Saltar al contenido
Skillpedia
Deploy y nube (DevOps)40 mil · #7117

containerize-aspnetcore

Qué hace

Esta herramienta crea las instrucciones necesarias (llamadas Dockerfile) para convertir tu proyecto ASP.NET Core en un 'contenedor'. Un contenedor es como un paquete aislado que guarda todo lo que tu aplicación necesita para funcionar, lo que facilita desplegarla en distintos entornos.

Cuándo usarla

  • ✓Cuando quieras ejecutar tu aplicación ASP.NET Core en un servidor sin instalar todo a mano.
  • ✓Cuando prepares tu aplicación para desplegarla en la nube (como Azure, AWS o Google Cloud).
  • ✓Si necesitas asegurarte de que tu aplicación funciona igual en cualquier ordenador.

Link de la skill

https://github.com/github/awesome-copilot/blob/main/skills/containerize-aspnetcore/SKILL.md

Cópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.

Cómo usar

La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.

Mensaje listo para pegar

Usa esta skill para ayudarme: https://github.com/github/awesome-copilot/blob/main/skills/containerize-aspnetcore/SKILL.md Lee el archivo SKILL.md de ese link y sigue sus instrucciones en mi tarea.
¿Quieres que tu IA encuentre skills como esta por sí sola?Instala el MCP gratis de Skillpedia: una línea, y busca entre 15.000+ skills antes de cada tarea.Instalar en 1 minuto →

Ejemplo de qué pedirle a la IA

“Crea un contenedor para mi proyecto ASP.NET Core en la carpeta 'my-project/my-app.csproj', usando .NET 8 y la distribución Alpine Linux.”

5 skills nuevas por semana. 1 minuto de lectura.

Cómo funciona

La herramienta analiza los ajustes que le das, como la versión de .NET y el tipo de Linux que quieres. Con eso genera un archivo llamado Dockerfile, que es una guía paso a paso para construir el contenedor de tu aplicación.

Contenido técnico (SKILL.md original)

Texto original del autor, en inglés, directo de GitHub.

ASP.NET Core Docker Containerization Prompt

Containerization Request

Containerize the ASP.NET Core (.NET) project specified in the settings below, focusing exclusively on changes required for the application to run in a Linux Docker container. Containerization should consider all settings specified here.

Abide by best practices for containerizing .NET Core applications, ensuring that the container is optimized for performance, security, and maintainability.

Containerization Settings

This section of the prompt contains the specific settings and configurations required for containerizing the ASP.NET Core application. Prior to running this prompt, ensure that the settings are filled out with the necessary information. Note that in many cases, only the first few settings are required. Later settings can be left as defaults if they do not apply to the project being containerized.

Any settings that are not specified will be set to default values. The default values are provided in [square brackets].

Basic Project Information

  1. Project to containerize:

    • [ProjectName (provide path to .csproj file)]
  2. .NET version to use:

    • [8.0 or 9.0 (Default 8.0)]
  3. Linux distribution to use:

    • [debian, alpine, ubuntu, chiseled, or Azure Linux (mariner) (Default debian)]
  4. Custom base image for the build stage of the Docker image ("None" to use standard Microsoft base image):

    • [Specify base image to use for build stage (Default None)]
  5. Custom base image for the run stage of the Docker image ("None" to use standard Microsoft base image):

    • [Specify base image to use for run stage (Default None)]

Container Configuration

  1. Ports that must be exposed in the container image:

    • Primary HTTP port: [e.g., 8080]
    • Additional ports: [List any additional ports, or "None"]
  2. User account the container should run as:

    • [User account, or default to "$APP_UID"]
  3. Application URL configuration:

    • [Specify ASPNETCORE_URLS, or default to "http://+:8080"]

Build configuration

  1. Custom build steps that must be performed before building the container image:

    • [List any specific build steps, or "None"]
  2. Custom build steps that must be performed after building the container image:

    • [List any specific build steps, or "None"]
  3. NuGet package sources that must be configured:

    • [List any private NuGet feeds with authentication details, or "None"]

Dependencies

  1. System packages that must be installed in the container image:

    • [Package names for the chosen Linux distribution, or "None"]
  2. Native libraries that must be copied to the container image:

    • [Library names and paths, or "None"]
  3. Additional .NET tools that must be installed:

    • [Tool names and versions, or "None"]

System Configuration

  1. Environment variables that must be set in the container image:
    • [Variable names and values, or "Use defaults"]

File System

  1. Files/directories that need to be copied to the container image:

    • [Paths relative to project root, or "None"]
    • Target location in container: [Container paths, or "Not applicable"]
  2. Files/directories to exclude from containerization:

    • [Paths to exclude, or "None"]
  3. Volume mount points that should be configured:

    • [Volume paths for persistent data, or "None"]

.dockerignore Configuration

  1. Patterns to include in the .dockerignore file (.dockerignore will already have common defaults; these are additional patterns):
    • Additional patterns: [List any additional patterns, or "None"]

Health Check Configuration

  1. Health check endpoint:

    • [Health check URL path, or "None"]
  2. Health check interval and timeout:

    • [Interval and timeout values, or "Use defaults"]

Additional Instructions

  1. Other instructions that must be followed to containerize the project:

    • [Specific requirements, or "None"]
  2. Known issues to address:

    • [Describe any known issues, or "None"]

Scope

  • ✅ App configuration modification to ensure application settings and connection strings can be read from environment variables
  • ✅ Dockerfile creation and configuration for an ASP.NET Core application
  • ✅ Specifying multiple stages in the Dockerfile to build/publish the application and copy the output to the final image
  • ✅ Configuration of Linux container platform compatibility (Alpine, Ubuntu, Chiseled, or Azure Linux (Mariner))

…

Preguntas frecuentes

¿Qué es un contenedor?

Piensa en un contenedor como una caja estandarizada que incluye tu aplicación y todo lo que necesita para funcionar (código, librerías, configuraciones). Así se ejecuta de forma consistente en cualquier lugar.

¿Qué es un Dockerfile?

Es un archivo de texto con instrucciones que Docker (la tecnología de contenedores) sigue para crear la imagen de tu contenedor. Es como una receta para crear el paquete de tu aplicación.

¿Necesito saber mucho de Docker para usar esto?

No. Esta herramienta simplifica la complejidad: solo tienes que indicar los ajustes básicos de tu proyecto para crear el contenedor.

Detalles

Descripción original del autor

Containerize an ASP.NET Core project by creating Dockerfile and .dockerfile files customized for the project.

repo: github/awesome-copilot

Popularidad

Estrellas en GitHub
40 mil
Posición en el ranking
#7117
Licencia
MIT
Actualizada
15/10/2026

¿Te sirve esta skill?

0

Entra para votar.

Comentarios

  • …

Más skills de este repositorio

Skills parecidas