Fix Dart service.yaml (indentation) and indicate that local dart is only needed for local development. (#477)

This commit is contained in:
Evan Anderson 2018-10-26 17:07:32 -07:00 committed by Knative Prow Robot
parent 6dc822ef81
commit 31ec1a3e92
2 changed files with 20 additions and 18 deletions

View File

@ -7,11 +7,12 @@ that you can use for testing. It reads in the env variable `TARGET` and prints
## Prerequisites ## Prerequisites
* A Kubernetes cluster with Knative installed. Follow the * A Kubernetes cluster with Knative installed. Follow the
[installation instructions](https://github.com/knative/docs/blob/master/install/README.md) if you need [installation instructions](https://github.com/knative/docs/blob/master/install/README.md)
to create one. if you need to create one.
* [Docker](https://www.docker.com) installed and running on your local machine, * [Docker](https://www.docker.com) installed and running on your local machine,
and a Docker Hub account configured (we'll use it for a container registry). and a Docker Hub account configured (we'll use it for a container registry).
* [dart-sdk](https://www.dartlang.org/tools/sdk#install) installed and configured. * [dart-sdk](https://www.dartlang.org/tools/sdk#install) installed and configured
if you want to run the program locally.
## Recreating the sample code ## Recreating the sample code
@ -32,7 +33,8 @@ created using the following instructions.
sdk: '>=2.0.0 <3.0.0' sdk: '>=2.0.0 <3.0.0'
``` ```
2. Install dependencies 2. If you want to run locally, install dependencies. If you only want to run in
Docker or Knative, you can skip this step.
```shell ```shell
pub get pub get

View File

@ -1,15 +1,15 @@
apiVersion: serving.knative.dev/v1alpha1 apiVersion: serving.knative.dev/v1alpha1
kind: Service kind: Service
metadata: metadata:
name: helloworld-dart name: helloworld-dart
namespace: default namespace: default
spec: spec:
runLatest: runLatest:
configuration: configuration:
revisionTemplate: revisionTemplate:
spec: spec:
container: container:
image: docker.io/{username}/helloworld-dart image: docker.io/{username}/helloworld-dart
env: env:
- name: TARGET - name: TARGET
value: "Dart Sample v1" value: "Dart Sample v1"