Aller au contenu
Skillpedia
Déploiement et cloud (DevOps)40k · #7116

containerize-aspnet-framework

Ce qu’il fait

Cet outil crée les instructions nécessaires (appelées Dockerfile) pour transformer un projet ASP.NET .NET Framework en conteneur. Cela permet à votre application de fonctionner partout de manière identique.

Quand l’utiliser

  • ✓Lorsque vous voulez faire fonctionner votre application ASP.NET sur un autre serveur.
  • ✓Lorsque vous préparez votre application pour un déploiement dans le cloud.
  • ✓Pour vous assurer que votre application se comporte de la même façon dans différents environnements de test.

Lien du skill

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

Copiez-le et collez-le dans votre IA (Claude, ChatGPT ou Cursor) en lui demandant de suivre les instructions.

Comment l’utiliser

Le plus simple : copiez le message et collez-le dans votre IA. Elle lit le skill et suit les instructions.

Message prêt à coller

Utilise ce skill pour m’aider : https://github.com/github/awesome-copilot/blob/main/skills/containerize-aspnet-framework/SKILL.md Lis le fichier SKILL.md de ce lien et suis ses instructions pour ma tâche.
Envie que votre IA trouve seule des skills comme celui-ci ?Installez le MCP gratuit de Skillpedia : une ligne, et elle cherche parmi 15 000+ skills avant chaque tâche.Installer en 1 minute →

Exemple de demande à votre IA

“Conteneurise mon projet ASP.NET situé dans « C:\myproject\myproject.csproj », en utilisant Windows Server 2022 Core et en exposant le port 80.”

5 nouveaux skills par semaine. 1 minute de lecture.

Comment ça marche

L'outil analyse les paramètres que vous fournissez, comme le chemin du projet et les ports. Il génère ensuite un fichier nommé Dockerfile qui contient toutes les commandes pour compiler et lancer votre application dans un environnement isolé (conteneur).

Contenu technique (SKILL.md original)

Texte original de l’auteur, en anglais, directement depuis GitHub.

ASP.NET .NET Framework Containerization Prompt

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

REMEMBER: This is a .NET Framework application, not .NET Core. The containerization process will be different from that of a .NET Core application.

Containerization Settings

This section of the prompt contains the specific settings and configurations required for containerizing the ASP.NET (.NET Framework) 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. Windows Server SKU to use:

    • [Windows Server Core (Default) or Windows Server Full]
  3. Windows Server version to use:

    • [2022, 2019, or 2016 (Default 2022)]
  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., 80]
    • Additional ports: [List any additional ports, or "None"]
  2. User account the container should run as:

    • [User account, or default to "ContainerUser"]
  3. IIS settings that must be configured in the container image:

    • [List any specific IIS settings, or "None"]

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"]

Dependencies

  1. .NET assemblies that should be registered in the GAC in the container image:

    • [Assembly name and version, or "None"]
  2. MSIs that must be copied to the container image and installed:

    • [MSI names and versions, or "None"]
  3. COM components that must be registered in the container image:

    • [COM component names, or "None"]

System Configuration

  1. Registry keys and values that must be added to the container image:

    • [Registry paths and values, or "None"]
  2. Environment variables that must be set in the container image:

    • [Variable names and values, or "Use defaults"]
  3. Windows Server roles and features that must be installed in the container image:

    • [Role/feature names, or "None"]

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"]

.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 config builders are used to read app settings and connection strings from the environment variables
  • ✅ Dockerfile creation and configuration for an ASP.NET application
  • ✅ Specifying multiple stages in the Dockerfile to build/publish the application and copy the output to the final image
  • ✅ Configuration of Windows container platform compatibility (Windows Server Core or Full)

…

Questions fréquentes

Qu'est-ce qu'un conteneur ?

Un conteneur est comme une boîte légère et isolée qui contient tout ce dont votre application a besoin pour fonctionner : le code, les bibliothèques et les paramètres. Cela garantit qu'elle fonctionne de la même façon sur n'importe quel ordinateur.

Quelle est la différence entre .NET Framework et .NET Core ?

.NET Framework est une version plus ancienne, généralement utilisée sur les systèmes Windows. .NET Core (aujourd'hui simplement appelé .NET) est plus moderne, multiplateforme et plus souple. Cet outil est spécifique à .NET Framework.

Dois-je installer quelque chose au préalable ?

Oui, le projet doit avoir installé le package NuGet « Microsoft.Configuration.ConfigurationBuilders.Environment ». Si ce n'est pas le cas, vous devrez l'installer manuellement dans Visual Studio avant d'utiliser cet outil.

Détails

Description originale de l’auteur

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

repo: github/awesome-copilot

Popularité

Étoiles GitHub
40k
Position au classement
#7116
Licence
MIT
Mis à jour
15/10/2026

Ce skill vous est-il utile ?

0

Connectez-vous pour voter.

Commentaires

  • …

Autres skills de ce dépôt

Skills similaires