Der Support für Cloud Deployment Manager endet am 31. Dezember 2025. Wenn Sie derzeit Deployment Manager verwenden, müssen Sie bis zum 31. Dezember 2025 zu Infrastructure Manager oder einer alternativen Bereitstellungstechnologie migrieren, damit Ihre Dienste ohne Unterbrechung weiterlaufen.
Mit Sammlungen den Überblick behalten
Sie können Inhalte basierend auf Ihren Einstellungen speichern und kategorisieren.
Auf dieser Seite wird erklärt, wie Sie eine Config-Ressource erstellen. Eine Config-Ressource ist ein API-Objekt, das Variablen als Schlüssel/Wert-Paare speichert. Sie benötigen eine Config-Ressource, bevor Sie Variablen festlegen und abrufen können. Nachdem Sie eine Config-Ressource erstellt haben, können Sie beliebige Variablen erstellen, die Sie zur Speicherung von Daten nutzen können.
[PROJECT_ID] ist die Projekt-ID für diese Anfrage.
[CONFIG_NAME] ist der Name dieser RuntimeConfig.
[DESCRIPTION] ist die Beschreibung dieser Konfiguration (optional).
Weitere Informationen zu dieser Methode erhalten Sie in der Dokumentation zu configs().create.
RuntimeConfig-Ressource löschen
Wenn Sie eine RuntimeConfig-Ressource löschen, werden alle in dieser Ressource enthaltenen Ressourcen gelöscht, einschließlich aller Variablen und Waiter.
Deployment Manager
Sie können eine RuntimeConfig-Ressource, die Teil einer Bereitstellung ist, mit einer der folgenden Methoden löschen:
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-09-03 (UTC)."],[[["\u003cp\u003eThis document outlines the process of creating and deleting Config resources, which are API objects that store variables as key-value pairs, within the Runtime Configurator service.\u003c/p\u003e\n"],["\u003cp\u003eConfig resources must be created before variables can be set and retrieved, enabling users to store and manage data through arbitrary variables.\u003c/p\u003e\n"],["\u003cp\u003eConfig resources can be managed via Deployment Manager, the \u003ccode\u003egcloud\u003c/code\u003e command-line tool, or directly through the Runtime Configurator API using specific commands and requests, as shown in the examples.\u003c/p\u003e\n"],["\u003cp\u003eDeleting a Config resource will remove all associated variables and waiters, and can be done through Deployment Manager, \u003ccode\u003egcloud\u003c/code\u003e, or the REST API.\u003c/p\u003e\n"],["\u003cp\u003eThis is a Beta product, meaning it is subject to "Pre-GA Offerings Terms", with limited support and features available on an "as is" basis.\u003c/p\u003e\n"]]],[],null,["# Creating and Deleting RuntimeConfig Resources\n\n| **Beta**\n|\n|\n| This product or feature is subject to the \"Pre-GA Offerings Terms\" in the General Service Terms section\n| of the [Service Specific Terms](/terms/service-terms#1).\n|\n| Pre-GA products and features are available \"as is\" and might have limited support.\n|\n| For more information, see the\n| [launch stage descriptions](/products#product-launch-stages).\n\nThis page explains how to create a Config resource. A Config\nresource is an API object that stores variables as key value pairs. You need a\nConfig resource before you can set and get variables. After creating a Config\nresource, you can create arbitrary variables that you can use to store data.\n\nTo learn more about configurations, variables, and the Runtime Configurator\nservice, see\n[Runtime Configurator Fundamentals](/deployment-manager/runtime-configurator).\n\nBefore you begin\n----------------\n\n- If you want to use the command-line examples in this guide, install the [\\`gcloud\\` command-line tool](/sdk).\n- If you want to use the API examples in this guide, set up [API access](/deployment-manager/docs/reference/latest).\n- Read [Runtime Configurator Fundamentals](/deployment-manager/runtime-configurator).\n- Enable the [Runtime Configurator API](https://console.cloud.google.com/apis/api/runtimeconfig.googleapis.com/overview).\n\nCreating a config\n-----------------\n\nYou can create a Config resource with Deployment Manager, the `gcloud`\ncommand-line tool, or directly using the Runtime Configurator API. \n\n### Deployment Manager\n\nTo create a config in Deployment Manager, specify the RuntimeConfig type: \n\n runtimeconfig.v1beta1.config\n\nIn the `properties` of the resource, provide the `name` and other optional\nproperties if desired: \n\n resources:\n - name: [CONFIG_NAME]\n type: runtimeconfig.v1beta1.config\n properties:\n config: [CONFIG_NAME]\n description: [DESCRIPTION]\n\nwhere:\n\n- `[CONFIG_NAME]` is the name for this config.\n- `[DESCRIPTION]` is the description of this config (optional).\n\n### gcloud\n\nWith the Google Cloud CLI, use the\n`gcloud beta runtime-config configs create` command: \n\n gcloud beta runtime-config configs create [CONFIG_NAME] --description [DESCRIPTION]\n\nwhere:\n\n- `[CONFIG_NAME]` is the name for this config.\n- `[DESCRIPTION]` is the description of this config (optional).\n\n`gcloud` returns a response like: \n\n```\nCreated [https://runtimeconfig.googleapis.com/v1beta1/projects/[PROJECT_ID]/configs/[CONFIG_NAME]].\n```\n\nFor a complete reference for this `gcloud` command, read the\n[`runtime-config configs create`](/sdk/gcloud/reference/beta/runtime-config/configs/create)\nreference documentation.\n\n### API\n\nIn the REST API, make a `POST` request to the following URI: \n\n https://runtimeconfig.googleapis.com/v1beta1/projects/[PROJECT_ID]/configs/\n\nwhere `[PROJECT_ID]` is the project ID for this request. The payload for\nthe request looks like this: \n\n {\n \"name\": \"projects/[PROJECT_ID]/configs/[CONFIG_NAME]\",\n \"description\": \"[DESCRIPTION]\"\n\n }\n\nwhere:\n\n- `[PROJECT_ID]` is the project ID for this request.\n- `[CONFIG_NAME]` is the name of this RuntimeConfig.\n- `[DESCRIPTION]` is the description of this config (optional).\n\n To learn more about this method, read the\n [`configs().create`](/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs/create)\n documentation.\n\nDeleting a RuntimeConfig resource\n---------------------------------\n\nDeleting a RuntimeConfig resource deletes all resources contained by that\nresource, including all variables and waiters. \n\n### Deployment Manager\n\nDelete a RuntimeConfig resource that is part of a deployment using one\nof the following methods:\n\n- [Update the deployment](/deployment-manager/docs/deployments/updating-deployments) to omit the config and redeploy the deployment.\n- [Delete the deployment and the resources it contains](/deployment-manager/docs/deployments/deleting-deployments).\n\n### gcloud\n\nWith the Google Cloud CLI, use the `gcloud beta runtime-config configs delete`\ncommand: \n\n gcloud beta runtime-config configs delete [CONFIG_NAME]\n\nwhere `[CONFIG_NAME]` is the name of the configuration object.\n\nThe gcloud CLI returns a response like: \n\n```\nDeleted [https://runtimeconfig.googleapis.com/v1beta1/projects/[PROJECT_ID]/configs/[CONFIG_NAME]].\n```\n\nFor the full `gcloud` reference, read the [`runtime-config configs delete`](/sdk/gcloud/reference/beta/runtime-config/configs/delete)\nreference documentation.\n\n### API\n\nIn the REST API, make a `DELETE` request to the following URI: \n\n https://runtimeconfig.googleapis.com/v1beta1/projects/[PROJECT_ID]/configs/[CONFIG_NAME]\n\nwhere:\n\n- `[PROJECT_ID]` is the project ID for this request.\n- `[CONFIG_NAME]` is the name of this configuration.\n\n To learn more about this method, read the\n [`configs().delete`](/deployment-manager/runtime-configurator/reference/rest/v1beta1/projects.configs/delete)\n documentation.\n\nWhat's next\n-----------\n\n- Next, create some variables and learn how to [set and get data](/deployment-manager/runtime-configurator/set-and-get-variables).\n- Learn how to set a [Watcher on a specific variable](/deployment-manager/runtime-configurator/watching-a-variable).\n- [Create a Waiter](/deployment-manager/runtime-configurator/creating-a-waiter) that returns when a variable reaches a Cardinality condition.\n- Refer to the [v1beta1 reference](/deployment-manager/runtime-configurator/reference/rest).\n- Refer to the [Quotas for Runtime Configurator](/deployment-manager/pricing-and-quotas#runtime_configurator).\n- Learn about [Runtime Configurator](/deployment-manager/runtime-configurator)."]]