OLD | NEW |
(Empty) | |
| 1 This package provide support for running Dart on |
| 2 [Google App Engine Managed VMs][managed-vms]. |
| 3 |
| 4 ### Getting started |
| 5 |
| 6 Visit [dartlang.org/cloud](https://www.dartlang.org/cloud) for more information |
| 7 on the requirements for getting started. |
| 8 |
| 9 When you are up and running a simple hello world application looks like this: |
| 10 |
| 11 ``` |
| 12 import 'dart:io'; |
| 13 import 'package:appengine/appengine.dart'; |
| 14 |
| 15 void requestHandler(HttpRequest request) { |
| 16 request.response |
| 17 ..write('Hello, world!'); |
| 18 ..close(); |
| 19 } |
| 20 |
| 21 void main() { |
| 22 runAppEngine(requestHandler).then((_) { |
| 23 // Server running. |
| 24 }); |
| 25 } |
| 26 ``` |
| 27 |
| 28 Add the application configuration in a `app.yaml` file and run it locally using |
| 29 by running: |
| 30 |
| 31 gcloud preview app run app.yaml |
| 32 |
| 33 When you are ready to deploy your application, make sure you have authenticated |
| 34 with `gcloud` and defined your current project. Then run: |
| 35 |
| 36 gcloud preview app deploy app.yaml |
| 37 |
| 38 ### Send Feedback |
| 39 |
| 40 We'd love to hear from you! If you encounter a bug, have suggestions for our |
| 41 APIs or is missing a feature, file it an issue on the |
| 42 [GitHub issue tracker](https://github.com/dart-lang/appengine/issues/new). |
| 43 |
| 44 **Note** The Dart support for App Engine is currently in beta. |
| 45 |
| 46 [managed-vms]: https://developers.google.com/appengine/docs/managed-vms/ |
OLD | NEW |