diff --git a/fe/dns.go b/fe/dns.go index 417701514fb939a7e29e10c4bc1f87b6ac4fd159..a66d2fd3f436b693eaaffbc638f982db9af9e9f6 100644 --- a/fe/dns.go +++ b/fe/dns.go @@ -145,6 +145,11 @@ func NewDNSRedirector(client *autoradio.Client, origin string, publicIps []net.I ttl: ttl, nameservers: addDotToList(nameservers), soa: soa, + + // We expect the public URLs to just use the origin, + // but serve a number of extra domain names such as + // 'stream' and 'www' just in case (and for backwards + // compatibility reasons). queryTable: map[string]ipFunc{ "": getAutoradioIPs, "www": getAutoradioIPs, diff --git a/fe/templates/index.html b/fe/templates/index.html index b5d04f94905331e14c4b6f539ac04b6b9db2d820..1b95732d4a98425de82a412b0b13ae6ec2112155 100644 --- a/fe/templates/index.html +++ b/fe/templates/index.html @@ -1,7 +1,7 @@ <!DOCTYPE html> <html> <head> - <title>stream.{{.Domain}}</title> + <title>{{.Domain}}</title> <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css"> <link rel="stylesheet" href="/static/style.css"> @@ -25,21 +25,21 @@ {{$domain := .Domain}} {{range .Mounts}} <li> - <a href="http://stream.{{$domain}}{{.Mount.Name}}" + <a href="http://{{$domain}}{{.Mount.Name}}" {{if .Mount.RelayUrl}} data-toggle="tooltip" data-delay="300" title="relay of {{.Mount.RelayUrl}}" {{end}} >{{.Mount.Name}}</a> - <a href="http://stream.{{$domain}}{{.Mount.Name}}.m3u">(m3u)</a> + <a href="http://{{$domain}}{{.Mount.Name}}.m3u">(m3u)</a> <span class="badge">{{.Listeners}}</span> {{if .TransMounts}} <ul> {{range .TransMounts}} <li> - <a href="http://stream.{{$domain}}{{.Mount.Name}}" + <a href="http://{{$domain}}{{.Mount.Name}}" data-toggle="tooltip" data-delay="300" title="{{.Mount.Transcoding.String}}" >{{.Mount.Name}}</a> - <a href="http://stream.{{$domain}}{{.Mount.Name}}.m3u">(m3u)</a> + <a href="http://{{$domain}}{{.Mount.Name}}.m3u">(m3u)</a> <span class="badge">{{.Listeners}}</span> </li> {{end}}