| // Copyright 2015 The Vanadium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style |
| // license that can be found in the LICENSE file. |
| // TODO(cnicolaou,benj): figure out how to support roaming as a chrome plugin |
| _ "v.io/x/ref/profiles/roaming" |
| "v.io/x/ref/services/wsprd/wspr" |
| port := flag.Int("port", 8124, "Port to listen on.") |
| identd := flag.String("identd", "", "name of identd server.") |
| ctx, shutdown := v23.Init() |
| listenSpec := v23.GetListenSpec(ctx) |
| proxy := wspr.NewWSPR(ctx, *port, &listenSpec, *identd, nil) |
| nhost, nport, _ := net.SplitHostPort(addr.String()) |
| fmt.Printf("Listening on host: %s port: %s\n", nhost, nport) |
| <-signals.ShutdownOnSignals(ctx) |