Skip to content

Commit

Permalink
Merge pull request #2396 from gravitl/remove-stun
Browse files Browse the repository at this point in the history
remove stun
  • Loading branch information
afeiszli authored Jun 28, 2023
2 parents ae92499 + 5857ff4 commit 0046bae
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 176 deletions.
4 changes: 1 addition & 3 deletions compose/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ services:
- sqldata:/root/data
environment:
# config-dependant vars
- STUN_LIST=stun.${NM_DOMAIN}:${STUN_PORT},stun1.netmaker.io:3478,stun2.netmaker.io:3478,stun1.l.google.com:19302,stun2.l.google.com:19302
- STUN_LIST=stun1.netmaker.io:3478,stun2.netmaker.io:3478,stun1.l.google.com:19302,stun2.l.google.com:19302
# The domain/host IP indicating the mq broker address
- BROKER_ENDPOINT=wss://broker.${NM_DOMAIN}
# The base domain of netmaker
Expand All @@ -26,8 +26,6 @@ services:
- TURN_SERVER_HOST=turn.${NM_DOMAIN}
# domain of the turn api server
- TURN_SERVER_API_HOST=https://turnapi.${NM_DOMAIN}
ports:
- "3478:3478/udp"

netmaker-ui:
container_name: netmaker-ui
Expand Down
6 changes: 0 additions & 6 deletions docker/Caddyfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,6 @@ https://api.{$NM_DOMAIN} {
reverse_proxy http://netmaker:8081
}

# STUN
https://stun.{$NM_DOMAIN} {
tls /root/certs/fullchain.pem /root/certs/privkey.pem
reverse_proxy netmaker:3478
}

# TURN
https://turn.{$NM_DOMAIN} {
tls /root/certs/fullchain.pem /root/certs/privkey.pem
Expand Down
6 changes: 0 additions & 6 deletions docker/Caddyfile-EE
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ https://api.{$NM_DOMAIN} {
reverse_proxy http://netmaker:8081
}

# STUN
https://stun.{$NM_DOMAIN} {
tls /root/certs/fullchain.pem /root/certs/privkey.pem
reverse_proxy netmaker:3478
}

# TURN
https://turn.{$NM_DOMAIN} {
tls /root/certs/fullchain.pem /root/certs/privkey.pem
Expand Down
5 changes: 0 additions & 5 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ import (
"github.com/gravitl/netmaker/netclient/ncutils"
"github.com/gravitl/netmaker/servercfg"
"github.com/gravitl/netmaker/serverctl"
stunserver "github.com/gravitl/netmaker/stun-server"
"golang.org/x/exp/slog"
)

Expand Down Expand Up @@ -149,10 +148,6 @@ func startControllers(wg *sync.WaitGroup, ctx context.Context) {
logger.Log(0, "No Server Mode selected, so nothing is being served! Set Rest mode (REST_BACKEND) or MessageQueue (MESSAGEQUEUE_BACKEND) to 'true'.")
}

// starts the stun server
wg.Add(1)
go stunserver.Start(wg, ctx)

wg.Add(1)
go logic.StartHookManager(ctx, wg)
}
Expand Down
1 change: 0 additions & 1 deletion scripts/nm-certs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ CERTBOT_PARAMS=$(cat <<EOF
certonly --standalone \
--non-interactive --agree-tos \
-m $NM_EMAIL \
-d stun.$NM_DOMAIN \
-d api.$NM_DOMAIN \
-d broker.$NM_DOMAIN \
-d dashboard.$NM_DOMAIN \
Expand Down
1 change: 0 additions & 1 deletion scripts/nm-upgrade-0-17-1-to-0-19-0.sh
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,6 @@ collect_server_settings() {
esac
done

STUN_DOMAIN="stun.$SERVER_NAME"
TURN_DOMAIN="turn.$SERVER_NAME"
TURNAPI_DOMAIN="turnapi.$SERVER_NAME"
echo "-----------------------------------------------------"
Expand Down
154 changes: 0 additions & 154 deletions stun-server/stun-server.go

This file was deleted.

0 comments on commit 0046bae

Please sign in to comment.