Returns a list of running App Runner services in your Amazon Web Services account.
See also: AWS API Documentation
See ‘aws help’ for descriptions of global parameters.
list-services
[--next-token <value>]
[--max-results <value>]
[--cli-input-json | --cli-input-yaml]
[--generate-cli-skeleton <value>]
--next-token
(string)
A token from a previous result page. Used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones specified in the initial request.
If you don’t specify
NextToken
, the request retrieves the first result page.
--max-results
(integer)
The maximum number of results to include in each response (result page). It’s used for a paginated request.
If you don’t specify
MaxResults
, the request retrieves all available results in a single response.
--cli-input-json
| --cli-input-yaml
(string)
Reads arguments from the JSON string provided. The JSON string follows the format provided by --generate-cli-skeleton
. If other arguments are provided on the command line, those values will override the JSON-provided values. It is not possible to pass arbitrary binary values using a JSON-provided value as the string will be taken literally. This may not be specified along with --cli-input-yaml
.
--generate-cli-skeleton
(string)
Prints a JSON skeleton to standard output without sending an API request. If provided with no value or the value input
, prints a sample input JSON that can be used as an argument for --cli-input-json
. Similarly, if provided yaml-input
it will print a sample input YAML that can be used with --cli-input-yaml
. If provided with the value output
, it validates the command inputs and returns a sample output JSON for that command. The generated JSON skeleton is not stable between versions of the AWS CLI and there are no backwards compatibility guarantees in the JSON skeleton generated.
See ‘aws help’ for descriptions of global parameters.
Note
To use the following examples, you must have the AWS CLI installed and configured. See the Getting started guide in the AWS CLI User Guide for more information.
Unless otherwise stated, all examples have unix-like quotation rules. These examples will need to be adapted to your terminal’s quoting rules. See Using quotation marks with strings in the AWS CLI User Guide .
To get a paginated listing of App Runner services
The following list-services
example lists all App Runner services in the AWS account. Up to two services are listed in each response.
This example shows the first request. The response includes two results and a token that can be used in the next request.
When a subsequent response doesn’t include a token, all services have been listed.
aws apprunner list-services \
--cli-input-json file://input.json
Contents of input.json
:
{
"MaxResults": 2
}
Output:
{
"NextToken": "eyJDdXN0b21lckFjY291bnRJZCI6IjI3MDIwNTQwMjg0NSIsIlNlcnZpY2VTdGF0dXNDb2RlIjoiUFJPVklTSU9OSU5HIiwiSGFzaEtleSI6IjI3MDIwNTQwMjg0NSNhYjhmOTRjZmUyOWE0NjBmYjg3NjBhZmQyZWU4NzU1NSJ9",
"ServiceSummaryList": [
{
"CreatedAt": "2020-11-20T19:05:25Z",
"UpdatedAt": "2020-11-23T12:41:37Z",
"ServiceArn": "arn:aws:apprunner:us-east-1:123456789012:service/python-app/8fe1e10304f84fd2b0df550fe98a71fa",
"ServiceId": "8fe1e10304f84fd2b0df550fe98a71fa",
"ServiceName": "python-app",
"ServiceUrl": "psbqam834h.us-east-1.awsapprunner.com",
"Status": "RUNNING"
},
{
"CreatedAt": "2020-11-06T23:15:30Z",
"UpdatedAt": "2020-11-23T13:21:22Z",
"ServiceArn": "arn:aws:apprunner:us-east-1:123456789012:service/golang-container-app/ab8f94cfe29a460fb8760afd2ee87555",
"ServiceId": "ab8f94cfe29a460fb8760afd2ee87555",
"ServiceName": "golang-container-app",
"ServiceUrl": "e2m8rrrx33.us-east-1.awsapprunner.com",
"Status": "RUNNING"
}
]
}
ServiceSummaryList -> (list)
A list of service summary information records. In a paginated request, the request returns up to
MaxResults
records for each call.(structure)
Provides summary information for an App Runner service.
This type contains limited information about a service. It doesn’t include configuration details. It’s returned by the ListServices action. Complete service information is returned by the CreateService , DescribeService , and DeleteService actions using the Service type.
ServiceName -> (string)
The customer-provided service name.
ServiceId -> (string)
An ID that App Runner generated for this service. It’s unique within the Amazon Web Services Region.
ServiceArn -> (string)
The Amazon Resource Name (ARN) of this service.
ServiceUrl -> (string)
A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.
CreatedAt -> (timestamp)
The time when the App Runner service was created. It’s in the Unix time stamp format.
UpdatedAt -> (timestamp)
The time when the App Runner service was last updated. It’s in theUnix time stamp format.
Status -> (string)
The current state of the App Runner service. These particular values mean the following.
CREATE_FAILED
– The service failed to create. Read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn’t usable, and still counts towards your service quota. When you’re done analyzing the failure, delete the service.
DELETE_FAILED
– The service failed to delete and can’t be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
NextToken -> (string)
The token that you can pass in a subsequent request to get the next result page. It’s returned in a paginated request.