Last active
July 17, 2020 18:08
-
-
Save pulumipus/057ca0abb4758161a4d3ce2698e9683a to your computer and use it in GitHub Desktop.
Headless service spec for stateless application
This file contains 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
const mariadbSvc = new k8s.core.v1.Service("mariadb", { | |
metadata: { | |
name: "mariadb", | |
}, | |
spec: { | |
type: "ClusterIP", | |
clusterIP: "None", | |
ports: [ | |
{ | |
name: "mysql", | |
port: 3306, | |
targetPort: "mysql" | |
} | |
], | |
selector: { | |
app: "mariadb", | |
component: "master", | |
release: "example" | |
} | |
} | |
}, { provider: provider }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment