forked from hswaw/hscloud
Merge "app/radio: add support for following relays"
commit
6781f62ec4
|
@ -31,7 +31,8 @@ local kube = import "../../../kube/kube.libsonnet";
|
|||
},
|
||||
hostname: "localhost",
|
||||
listenPort: 8080,
|
||||
mounts: [],
|
||||
mounts: {},
|
||||
relays: {},
|
||||
},
|
||||
|
||||
tag: "latest",
|
||||
|
@ -123,7 +124,20 @@ local kube = import "../../../kube/kube.libsonnet";
|
|||
["fallback-override", "1"],
|
||||
] else [])
|
||||
for m in std.objectFields(cfg.icecast.mounts)
|
||||
]),
|
||||
] + [
|
||||
["relay",
|
||||
["server", cfg.icecast.relays[r].server],
|
||||
["port", std.toString(cfg.icecast.relays[r].port)],
|
||||
["mount", cfg.icecast.relays[r].mount],
|
||||
["local-mount", r],
|
||||
["on-demand", "0"],
|
||||
] + (if cfg.icecast.relays[r].username != null then [
|
||||
["username", cfg.icecast.relays[r].username]
|
||||
] else []) + (if cfg.icecast.relays[r].password != null then [
|
||||
["password", cfg.icecast.relays[r].password],
|
||||
] else [])
|
||||
for r in std.objectFields(cfg.icecast.relays)
|
||||
]),
|
||||
},
|
||||
},
|
||||
|
||||
|
@ -158,6 +172,7 @@ local kube = import "../../../kube/kube.libsonnet";
|
|||
spec+: {
|
||||
ports: [
|
||||
{ name: "client", port: cfg.port, targetPort: cfg.icecast.listenPort, protocol: "TCP" },
|
||||
{ name: "client80", port: 80, targetPort: cfg.icecast.listenPort, protocol: "TCP" },
|
||||
],
|
||||
type: "LoadBalancer",
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue