Created
December 19, 2018 21:53
-
-
Save robotarmy/98a6eb59fafacf079292a04688554fd8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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