deploy.proto 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119
  1. // Copyright 2021 Google LLC
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.appengine.v1beta;
  16. import "google/protobuf/duration.proto";
  17. import "google/api/annotations.proto";
  18. option csharp_namespace = "Google.Cloud.AppEngine.V1Beta";
  19. option go_package = "google.golang.org/genproto/googleapis/appengine/v1beta;appengine";
  20. option java_multiple_files = true;
  21. option java_outer_classname = "DeployProto";
  22. option java_package = "com.google.appengine.v1beta";
  23. option php_namespace = "Google\\Cloud\\AppEngine\\V1beta";
  24. option ruby_package = "Google::Cloud::AppEngine::V1beta";
  25. // Code and application artifacts used to deploy a version to App Engine.
  26. message Deployment {
  27. // Manifest of the files stored in Google Cloud Storage that are included
  28. // as part of this version. All files must be readable using the
  29. // credentials supplied with this call.
  30. map<string, FileInfo> files = 1;
  31. // The Docker image for the container that runs the version.
  32. // Only applicable for instances running in the App Engine flexible environment.
  33. ContainerInfo container = 2;
  34. // The zip file for this deployment, if this is a zip deployment.
  35. ZipInfo zip = 3;
  36. // Google Cloud Build build information. Only applicable for instances running
  37. // in the App Engine flexible environment.
  38. BuildInfo build = 5;
  39. // Options for any Google Cloud Build builds created as a part of this
  40. // deployment.
  41. //
  42. // These options will only be used if a new build is created, such as when
  43. // deploying to the App Engine flexible environment using files or zip.
  44. CloudBuildOptions cloud_build_options = 6;
  45. }
  46. // Single source file that is part of the version to be deployed. Each source
  47. // file that is deployed must be specified separately.
  48. message FileInfo {
  49. // URL source to use to fetch this file. Must be a URL to a resource in
  50. // Google Cloud Storage in the form
  51. // 'http(s)://storage.googleapis.com/\<bucket\>/\<object\>'.
  52. string source_url = 1;
  53. // The SHA1 hash of the file, in hex.
  54. string sha1_sum = 2;
  55. // The MIME type of the file.
  56. //
  57. // Defaults to the value from Google Cloud Storage.
  58. string mime_type = 3;
  59. }
  60. // Docker image that is used to create a container and start a VM instance for
  61. // the version that you deploy. Only applicable for instances running in the App
  62. // Engine flexible environment.
  63. message ContainerInfo {
  64. // URI to the hosted container image in Google Container Registry. The URI
  65. // must be fully qualified and include a tag or digest.
  66. // Examples: "gcr.io/my-project/image:tag" or "gcr.io/my-project/image@digest"
  67. string image = 1;
  68. }
  69. // Google Cloud Build information.
  70. message BuildInfo {
  71. // The Google Cloud Build id.
  72. // Example: "f966068f-08b2-42c8-bdfe-74137dff2bf9"
  73. string cloud_build_id = 1;
  74. }
  75. // Options for the build operations performed as a part of the version
  76. // deployment. Only applicable for App Engine flexible environment when creating
  77. // a version using source code directly.
  78. message CloudBuildOptions {
  79. // Path to the yaml file used in deployment, used to determine runtime
  80. // configuration details.
  81. //
  82. // Required for flexible environment builds.
  83. //
  84. // See https://cloud.google.com/appengine/docs/standard/python/config/appref
  85. // for more details.
  86. string app_yaml_path = 1;
  87. // The Cloud Build timeout used as part of any dependent builds performed by
  88. // version creation. Defaults to 10 minutes.
  89. google.protobuf.Duration cloud_build_timeout = 2;
  90. }
  91. // The zip file information for a zip deployment.
  92. message ZipInfo {
  93. // URL of the zip file to deploy from. Must be a URL to a resource in
  94. // Google Cloud Storage in the form
  95. // 'http(s)://storage.googleapis.com/\<bucket\>/\<object\>'.
  96. string source_url = 3;
  97. // An estimate of the number of files in a zip for a zip deployment.
  98. // If set, must be greater than or equal to the actual number of files.
  99. // Used for optimizing performance; if not provided, deployment may be slow.
  100. int32 files_count = 4;
  101. }