App Runner service based on source code
You can use AWS App Runner to create and manage services based on two fundamentally different types of service source: source code and source image. Regardless of the source type, App Runner takes care of starting, running, scaling, and load balancing your service. You can use the CI/CD capability of App Runner to track changes to your source image or code. When App Runner discovers a change, it automatically builds (for source code) and deploys the new version to your App Runner service.
This chapter discusses services based on source code. For information about services based on a source image, see App Runner service based on a source image.
Source code is application code that App Runner builds and deploys for you. You point App Runner to a source code repository and choose a suitable runtime that corresponds to a programming platform version. App Runner builds an image that's based on the base image of the runtime and your application code. It then starts a service that runs a container based on this image.
App Runner provides convenient platform-specific managed runtimes. Each one of these runtimes builds a container image from your source code, and adds language runtime dependencies into your image. You don't need to provide container configuration and build instructions such as a Dockerfile.
Subtopics of this chapter discuss the various platforms that App Runner supports— managed platforms that provide managed runtimes for different programming environments and versions.
Topics
Source code repository providers
App Runner deploys your source code by reading it from a source code repository. App Runner supports one source code repository provider: GitHub
Deploying from GitHub
To deploy your source code to an App Runner service from a GitHub
When you use the App Runner API or the AWS CLI, a connection is a separate resource. First, you create the connection using the CreateConnection API action. Then, you provide the connection's ARN during service creation using the CreateService API action.
For more information about App Runner service creation, see Creating an App Runner service. For more information about App Runner connections, see Managing App Runner connections.
App Runner managed platforms
App Runner managed platforms provide managed runtimes for various programming environments. Each managed runtime makes it easy to build and run containers
based on a version of a programming language or runtime environment. When you use a managed runtime, App Runner starts with a managed runtime image. This image
is based on the Amazon Linux Docker image
You specify a runtime for your App Runner service when you create a service using the App Runner console or the CreateService API. You can also specify a runtime as part of your source code. Use the runtime
keyword in a App Runner configuration file that you include in your code repository.
The naming convention of a managed runtime is <language-name><major-version>
.
App Runner updates the runtime for your service to the latest version on every deployment or service update. If your application requires a specific version of
a managed runtime, you can specify it using the runtime-version
keyword in the App Runner configuration file. You
can lock to any level of version (for example, major or minor), and App Runner only makes lower-level updates to the runtime of your service.