Sha256: 1b903cb139b1ddbe505d3d1acf98d3aa9e5e4689f476125b305e33dadf178783
Contents?: true
Size: 1011 Bytes
Versions: 3
Compression:
Stored size: 1011 Bytes
Contents
module Souls module Gcloud module Pubsub class << self def create_subscription( topic_name: "send-user-mail", project_id: "", service_account: "", endpoint: "https:://test.com" ) service_account = Souls.configuration.app if service_account.blank? project_id = Souls.configuration.project_id if project_id.blank? system( "gcloud pubsub subscriptions create #{topic_name}-sub \ --topic #{topic_name} \ --topic-project #{project_id} \ --push-auth-service-account #{service_account} \ --push-endpoint #{endpoint} \ --expiration-period never " ) end def update_subscription( topic_name: "send-user-mail", endpoint: "https:://test.com" ) system("gcloud pubsub subscriptions update #{topic_name}-sub --push-endpoint #{endpoint} ") end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
souls-0.32.11 | lib/souls/cli/gcloud/pubsub/subscriptions.rb |
souls-0.32.10 | lib/souls/cli/gcloud/pubsub/subscriptions.rb |
souls-0.32.9 | lib/souls/cli/gcloud/pubsub/subscriptions.rb |