Compare commits

...

3 Commits

Author SHA1 Message Date
9dc85a1963 revert consul tags 2024-07-16 21:34:58 +02:00
91c27b30bf fix in consul register method 2024-07-16 19:13:40 +02:00
3ed094ff55 remove deprecated amqp mod, added official amqp mod 2024-07-16 18:54:28 +02:00
2 changed files with 4 additions and 4 deletions

View File

@@ -74,7 +74,7 @@ func (s *Service) Register() error {
ID: s.GetID(),
// Kind: consul.ServiceKindConnectProxy,
Name: s.Name,
Address: s.Address,
Address: s.domain,
Port: s.port,
Tags: s.getTags(),
// Connect: &consul.AgentServiceConnect{Native: true},
@@ -178,8 +178,8 @@ func (s *Service) healthCheck() (bool, error) {
func (s *Service) getTags() []string {
tags := []string{
"traefik.enable=true",
// "traefik.http.routers." + s.Name + ".rule=PathPrefix(`" + s.pathPrefix + "`)",
"traefik.http.routers." + s.Name + ".rule=Host(`" + s.domain + "`)",
"traefik.http.routers." + s.Name + ".rule=PathPrefix(`" + s.pathPrefix + "`)",
// "traefik.http.routers." + s.Name + ".rule=Host(`" + s.domain + "`)",
"traefik.http.routers." + s.Name + ".entryPoints=https",
// "traefik.http.routers." + s.Name + ".tls=true",
"traefik.http.routers." + s.Name + ".service=" + s.Name,

View File

@@ -3,7 +3,7 @@ package rabbitmq
import (
"log"
"github.com/streadway/amqp"
amqp "github.com/rabbitmq/amqp091-go"
)
func Open(url string) (*amqp.Connection, *amqp.Channel, error) {