【问题标题】:When deploying my app in flexible environment getting error beta setting machine_type cannot be set in an App Engine Flexible Environment在柔性环境中部署我的应用时出现错误 beta 设置 machine_type 无法在 App Engine 柔性环境中设置
【发布时间】:2017-01-29 07:17:46
【问题描述】:

当尝试使用灵活的环境部署我的应用引擎时,我遇到了错误。

ERROR: (gcloud.preview.app.deploy) INVALID_ARGUMENT: 
The beta setting machine_type cannot be set in an App Engine Flexible Environment deployment.

我的 app.yaml 如下所示

runtime: nodejs
#vm: true
env: flex

# [END runtime]

network:
  instance_tag: app-tag
  name: network-tag

instance_class: F1
automatic_scaling:
  min_num_instances: 1
  max_num_instances: 2
  cool_down_period_sec: 60

beta_settings:
  machine_type: f1-micro

handlers:
- url: /.*
  script: IGNORED
  secure: always

# Temporary setting to keep gcloud from uploading node_modules
skip_files:
- ^node_modules$

还有谁能告诉我vm: trueenv: flex 有什么区别,因为两者都将应用引擎环境设置为灵活??

【问题讨论】:

    标签: google-app-engine google-cloud-platform google-compute-engine


    【解决方案1】:

    vm: true 更改为env: flex 时,您实际上是在切换到最新的基础架构版本,请参阅Upgrading to the Latest App Engine Flexible Environment Beta Release

    机器类型不再以这种方式配置。相反,您可以通过其resources 配置custom instance shape

    资源设置

    这些设置控制计算资源。 App Engine 分配一个 machine type 基于您拥有的 CPU 和内存量 指定的。该机器保证至少具有以下水平 您指定的资源,它可能有更多。

    您最多可以在资源设置中指定八个卷 tmpfs。 然后,您可以通过 tmpfs 启用需要共享内存的工作负载和 可以提高文件系统 I/O。

    例如:

    resources:
      cpu: 2
      memory_gb: 1.3
      disk_size_gb: 10
      volumes:
      - name: ramdisk1
        volume_type: tmpfs
        size_gb: 0.5
    

    【讨论】:

    • vm: true 是指标准环境吗?我猜不是
    猜你喜欢
    • 1970-01-01
    • 2020-10-09
    • 1970-01-01
    • 2019-04-24
    • 1970-01-01
    • 1970-01-01
    • 2018-04-12
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多