-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add Istio Service Mesh Gateway & Virtual Service
- Loading branch information
Showing
4 changed files
with
56 additions
and
4 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
apiVersion: networking.istio.io/v1alpha3 | ||
kind: Gateway | ||
metadata: | ||
name: {{ .Release.Name }}-gateway | ||
namespace: {{ .Values.istio.namespace }} | ||
spec: | ||
selector: | ||
istio: ingress | ||
servers: | ||
- port: | ||
number: {{ .Values.istio.gateway.port }} # the Gateway port to be exposed | ||
name: http | ||
protocol: HTTP | ||
hosts: | ||
- "*" # accepting requests from all the hosts |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
apiVersion: networking.istio.io/v1alpha3 | ||
kind: VirtualService | ||
metadata: | ||
name: {{ .Release.Name }}-vs | ||
namespace: {{ .Values.istio.namespace }} | ||
spec: | ||
hosts: | ||
- "*" | ||
gateways: | ||
- {{ .Release.Name }}-gateway | ||
http: | ||
- match: | ||
- port: {{ .Values.istio.gateway.port }} # to match the gateway port basically to bind this to gateway | ||
route: | ||
- destination: | ||
host: {{ .Release.Name }}-service.{{ .Values.namespace }}.svc.cluster.local # to match the service where we need to send the req (here we need to pass the Fully qualified domain name because our service is in different ns as from VS AND GATEWAY) | ||
port: | ||
number: {{.Values.service.port}} # the service port of the webapp | ||
# - route: | ||
# - destination: | ||
# host: infra-helm-release-kafka-broker-0.infra-helm-release-kafka-broker-headless.deps.svc.cluster.local | ||
# port: | ||
# number: 9094 | ||
# - route: | ||
# - destination: | ||
# host: infra-helm-release-kafka-broker-0.infra-helm-release-kafka-broker-headless.deps.svc.cluster.local | ||
# port: | ||
# number: 9094 | ||
# - route: | ||
# - destination: | ||
# host: infra-helm-release-kafka-broker-0.infra-helm-release-kafka-broker-headless.deps.svc.cluster.local | ||
# port: | ||
# number: 9094 |
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