Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
function(namespace, name, selector, port, internal_port) {
kind: 'Service',
apiVersion: 'v1',
metadata: {
name: name,
namespace: namespace,
},
spec: {
selector: {
app: selector,
},
ports: [{
name: 'http',
protocol: 'TCP',
port: port,
targetPort: internal_port,
}],
type: 'NodePort',
},
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment