{"id":28551875,"url":"https://github.com/heroku/buildpacks-dotnet","last_synced_at":"2026-04-14T23:02:17.612Z","repository":{"id":253241745,"uuid":"761308652","full_name":"heroku/buildpacks-dotnet","owner":"heroku","description":"Heroku's Cloud Native Buildpack for .NET applications.","archived":false,"fork":false,"pushed_at":"2026-03-04T00:09:50.000Z","size":887,"stargazers_count":13,"open_issues_count":4,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2026-03-04T03:39:41.113Z","etag":null,"topics":["aspnetcore","cloud-native-buildpacks","cnb","csharp","dotnet","heroku","heroku-languages","msbuild"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/heroku.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-02-21T16:19:42.000Z","updated_at":"2026-03-04T00:08:48.000Z","dependencies_parsed_at":"2025-01-15T09:45:30.362Z","dependency_job_id":"6f830bc1-3431-45a5-b21d-583b90188ed8","html_url":"https://github.com/heroku/buildpacks-dotnet","commit_stats":null,"previous_names":["heroku/buildpacks-dotnet"],"tags_count":52,"template":false,"template_full_name":null,"purl":"pkg:github/heroku/buildpacks-dotnet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heroku%2Fbuildpacks-dotnet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heroku%2Fbuildpacks-dotnet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heroku%2Fbuildpacks-dotnet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heroku%2Fbuildpacks-dotnet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/heroku","download_url":"https://codeload.github.com/heroku/buildpacks-dotnet/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/heroku%2Fbuildpacks-dotnet/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30355223,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T15:55:29.454Z","status":"ssl_error","status_checked_at":"2026-03-10T15:54:58.440Z","response_time":106,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aspnetcore","cloud-native-buildpacks","cnb","csharp","dotnet","heroku","heroku-languages","msbuild"],"created_at":"2025-06-10T04:07:14.673Z","updated_at":"2026-03-10T21:04:38.814Z","avatar_url":"https://github.com/heroku.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"![dotnet-buildpack-github-banner](https://raw.githubusercontent.com/heroku/buildpacks/refs/heads/main/assets/images/buildpack-banner-dotnet.png)\n\n# Heroku Cloud Native Buildpack: .NET\n\n[![Cloud Native Buildpacks Registry: heroku/dotnet][registry-badge]][registry-url]\n[![CI on Github Actions: heroku/dotnet][ci-badge]][ci-url]\n\n`heroku/dotnet` is the [Heroku Cloud Native Buildpack][heroku-buildpacks]\nfor .NET and ASP.NET Core applications. It builds .NET and ASP.NET Core application source code into application images with\nminimal configuration.\n\n\u003e [!IMPORTANT]\n\u003e This is a [Cloud Native Buildpack][cnb], and is a component of the [Heroku Cloud Native Buildpacks][heroku-buildpacks] project. If you are instead looking for the Heroku Classic Buildpack for .NET, you may find it [here][classic-buildpack].\n\n## Usage\n\n\u003e [!NOTE]\n\u003e Before getting started, ensure you have the `pack` CLI installed. Installation instructions are available [here][pack-install].\n\nTo build a .NET application codebase into a production image:\n\n```bash\n$ cd ~/workdir/sample-dotnet-app\n$ pack build sample-app --builder heroku/builder:24\n```\n\nThen run the image:\n```bash\ndocker run --rm -it -e \"PORT=8080\" -p 8080:8080 sample-app\n```\n\n## Application Requirements\n\nA .NET solution (e.g. `MySolution.sln` or `MySolution.slnx`), project (e.g. `*.csproj`, `*.vbproj` or `*.fsproj`) or C# (e.g. `MyApp.cs`) file must be present in the application’s root directory.\n\nIf the root directory contains both solution and project files, the solution file will be preferred for the build and publish process.\n\nIf the root directory contains neither solution or project files, the C# file will be published as a [.NET 10 file-based app][file-based-apps].\n\nThe buildpack supports C#, Visual Basic and F# apps using the .NET and ASP.NET Core frameworks (version 8.0 and up).\n\n## Configuration\n\n### .NET Version\n\nBy default, the buildpack will install the latest available .NET SDK based on the value of the [`TargetFramework` property][target-framework], which must be configured for each project. If a project file doesn't specify `TargetFramework`, the buildpack will look for a [`Directory.Build.props`][directory-build-props] file in the project directory or any parent directory and use the `TargetFramework` property if defined there.\n\nTarget framework moniker (TFM) values that follow the `net{major_version}.0` format are currently supported (e.g. `net8.0`, `net9.0`, `net10.0`). If a solution references projects that target different framework versions, the most recent version will be preferred when inferring the .NET SDK version to install.\n\nTo install a different .NET SDK version, add a [`global.json` file][global-json] to the root directory. The buildpack supports specifying both the `version` and `rollForward` policy to define which .NET SDK version to install. For instance, to install a specific version a `global.json` file may look like this:\n\n```json\n{\n  \"sdk\": {\n    \"version\": \"8.0.106\",\n    \"rollForward\": \"disable\"\n  }\n}\n```\n\nA complete inventory of supported .NET SDK versions and platforms [is available here](./buildpacks/dotnet/inventory.toml).\n\n### Solution File\n\nBy default, the buildpack automatically detects the solution, project or file-based app file to build and publish. However, if your codebase contains multiple solution files in the root directory, you must specify which one to use.\n\nYou can configure the solution file using either an environment variable or a `project.toml` file.\n\n#### Using Environment Variable\n\nSet the `SOLUTION_FILE` environment variable during build:\n\n```bash\n$ pack build sample-app \\\n    --env \"SOLUTION_FILE=foo.sln\" \\\n    --builder heroku/builder:24\n```\n\n#### Using project.toml\n\nAlternatively, create a `project.toml` file in the root of your project:\n\n```toml\n[_]\nschema-version = \"0.2\"\n\n[com.heroku.buildpacks.dotnet]\nsolution_file = \"foo.sln\"\n```\n\n\u003e [!NOTE]\n\u003e If you use both an environment variable and a `project.toml` file, the environment variable will take precedence.\n\n### MSBuild\n\nThe recommended way to customize MSBuild is by creating a `project.toml` file in the root of your project. This allows you to change the default build configuration, `Release`, and the default verbosity level, `minimal`.\n\n```toml\n[_]\nschema-version = \"0.2\"\n\n[com.heroku.buildpacks.dotnet.msbuild]\nconfiguration = \"Debug\"\nverbosity = \"quiet\"\n```\n\nAlternatively, you can use the `BUILD_CONFIGURATION` and `MSBUILD_VERBOSITY_LEVEL` environment variables during build.\n\nTo build using a `Debug` build configuration and `detailed` verbosity level:\n\n```bash\n$ pack build sample-app \\\n    --env \"BUILD_CONFIGURATION=Debug\" \\\n    --env \"MSBUILD_VERBOSITY_LEVEL=detailed\" \\\n    --builder heroku/builder:24\n```\n\n\u003e [!NOTE]\n\u003e If you use both a `project.toml` file and environment variables, the settings from the environment variables will take precedence.\n\n## Contributing\n\nIssues and pull requests are welcome. See our [contributing guidelines](./CONTRIBUTING.md) if you would like to help.\n\n[ci-badge]: https://github.com/heroku/buildpacks-dotnet/actions/workflows/ci.yml/badge.svg\n[ci-url]: https://github.com/heroku/buildpacks-dotnet/actions/workflows/ci.yml\n[classic-buildpack]: https://github.com/heroku/heroku-buildpack-dotnet\n[cnb]: https://buildpacks.io\n[directory-build-props]: https://learn.microsoft.com/en-us/visualstudio/msbuild/customize-by-directory#directorybuildprops-and-directorybuildtargets\n[file-based-apps]: https://learn.microsoft.com/en-us/dotnet/core/whats-new/dotnet-10/sdk#file-based-apps-enhancements\n[heroku-buildpacks]: https://github.com/heroku/buildpacks\n[pack-install]: https://buildpacks.io/docs/for-platform-operators/how-to/integrate-ci/pack/\n[target-framework]: https://learn.microsoft.com/en-us/dotnet/core/project-sdk/msbuild-props#targetframework\n[global-json]: https://learn.microsoft.com/en-us/dotnet/core/tools/global-json\n[registry-badge]: https://img.shields.io/badge/dynamic/json?url=https://registry.buildpacks.io/api/v1/buildpacks/heroku/dotnet\u0026label=version\u0026query=$.latest.version\u0026color=DF0A6B\u0026logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAACSVJREFUaAXtWQ1sFMcVnp/9ub3zHT7AOEkNOMYYp4CQQFBLpY1TN05DidI2NSTF0CBFQAOBNrTlp0a14sipSBxIG6UYHKCO2ka4SXD4SUuaCqmoJJFMCapBtcGYGqMkDgQ4++52Z2e3b87es+/s+wNHVSUPsnZv9s2b97335v0MCI2NMQ2MaeD/WgP4FqQnX//2K4tVWfa0X+9+q/N4dfgWeESXPPjUUd+cu+5cYmMcPvzawQOtrdVG9GMaLxkD+OZDex6WVeUgwhiZnH1g62bNX4+sPpLGXvEkdPNzLd93e9y/cCnabIQJCnz+2Q9rNs9tjCdM9ltK9nGkb5jYxYjIyDJDSCLSV0yFHCr/XsObvQH92X+8u/b0SGvi5zZUn1joc/u2qapajglB4XAfUlQPoqpyRzxtqt8ZA+AIcQnZEb6WZSKCMSZUfSTLg8vv/86e3b03AztO/u3p7pE2fvInfy70TpiwRVKU5YqqygbTEWL9lISaiDFujbQu2VzGAIYzs5HFDUQo8WKibMzy0Yr7Ht5Td/Nyd0NLS3VQ0FesOjDurtwvPaWp6gZVc080TR2FQn0x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S5a2YSuVizjkfBAo9l0tzyCDbSqKC7YUIu/daOFB3pbUxrf721B0rc/w+9zrYfK2K5QlhcCvnfFCigUr6L0ucDA3KeR8iYO3U8y8M6+ZGBDAgIc0vWl5BEakiijQTYmhkWpEVEBwOELgUt+y3QtysuXT21ahGoujSePl3/qpiRVK2wO3KY1ClyuJ8YHATcDPIyhQFud6JbfKr1vZz+xehd0a8e08GICKC318xzpejrpUQ3UAkaZK4yoGU/HduWts72hsPpyFnSpL2wjWlFNFfSoSWipqIWVYP1J27rwcCL839eF9PMgYpATiLJ01eOs2jaU+D03508cK/9iHUkm6F4LBI+hTlc9m0BSsVSufcCBkvzu7afSHpgrGPYxoY00BEA/8FOPrYBqYsE44AAAAASUVORK5CYII=\u0026labelColor=white\n[registry-url]: https://registry.buildpacks.io/buildpacks/heroku/dotnet\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheroku%2Fbuildpacks-dotnet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fheroku%2Fbuildpacks-dotnet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fheroku%2Fbuildpacks-dotnet/lists"}