OpenTofu and Pub/Sub

Pub/Sub as code: one name, four resources (topic, subscription and their dead-letter pair)

An OpenTofu module that turns a list of names into Pub/Sub topics, subscriptions and dead-letter queues, applied through GitLab CI. Bringing the existing hand-made topics under it showed that almost none of the dead-letter topics had a subscription, so dead-lettered messages were dropped on arrival.

October 7, 2026 · 8 min