feat(rabbitmq): lab7 add CA creator script for rabbit, ACL, TLS-only

This commit is contained in:
Голиков Maximillian Антон
2026-11-26 08:32:54 +03:00
parent ff70413158
commit 424e9d6db1
6 changed files with 70 additions and 29 deletions
+1 -6
View File
@@ -124,12 +124,7 @@ func runWorker(ctx context.Context, cfg *config.Config, pipeline *worker.Pipelin
ch.Qos(2, 0, false)
q, err := ch.QueueDeclare("attachments.process", true, false, false, false, nil)
if err != nil {
return err
}
msgs, err := ch.Consume(q.Name, "", false, false, false, false, nil)
msgs, err := ch.Consume("attachments.process", "", false, false, false, false, nil)
if err != nil {
return err
}
-15
View File
@@ -50,21 +50,6 @@ func (p *RabbitPublisher) connect() error {
return fmt.Errorf("включение режима confirm: %w", err)
}
err = p.ch.ExchangeDeclare("attachments", "direct", true, false, false, false, nil)
if err != nil {
return fmt.Errorf("объявление exchange: %w", err)
}
_, err = p.ch.QueueDeclare("attachments.process", true, false, false, false, nil)
if err != nil {
return fmt.Errorf("объявление очереди: %w", err)
}
err = p.ch.QueueBind("attachments.process", "process", "attachments", false, nil)
if err != nil {
return fmt.Errorf("привязка очереди: %w", err)
}
return nil
}