ansible / ansible.builtin / v2.8.20 / module / gcpubsub_facts List Topics/Subscriptions and Messages from Google PubSub. | "added in version" 2.3 of ansible.builtin" Authors: Tom Melendez (@supertom) <tom@supertom.com> preview | supported by communityansible.builtin.gcpubsub_facts (v2.8.20) — module
pip
Install with pip install ansible==2.8.20
List Topics/Subscriptions from Google PubSub. Use the gcpubsub module for topic/subscription management. See U(https://cloud.google.com/pubsub/docs) for an overview.
## List all Topics in a project - gcpubsub_facts: view: topics state: list
## List all Subscriptions in a project - gcpubsub_facts: view: subscriptions state: list
## List all Subscriptions for a Topic in a project - gcpubsub_facts: view: subscriptions topic: my-topic state: list
view: description: - Choices are 'topics' or 'subscriptions' required: true state: description: - list is the only valid option. required: false topic: description: - GCP pubsub topic name. Only the name, not the full path, is required. required: false
subscriptions: description: List of subscriptions. returned: When view is set to subscriptions. sample: - mysubscription - mysubscription2 type: list topic: description: Name of topic. Used to filter subscriptions. returned: Always sample: mytopic type: str topics: description: List of topics. returned: When view is set to topics. sample: - mytopic - mytopic2 type: list