Skip to content

Instantly share code, notes, and snippets.

Last active March 1, 2022 20:32
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
# coding=utf-8
import pika
import environ
env = environ.Env()
rabbitmq_url = env("RABBITMQ_URL")
params = pika.URLParameters(rabbitmq_url)
connection = pika.BlockingConnection(params)
channel =
channel.basic_publish(exchange='', routing_key='intro_rabbitmq', body='Ola Mundo!')
print(" [x] Enviado 'Ola Mundo!'")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment