Fix kind cluster to allow full Ingress on localhost
This commit is contained in:
parent
17509063be
commit
b824af236a
|
@ -12,7 +12,7 @@ spec:
|
||||||
ingressClassName: nginx
|
ingressClassName: nginx
|
||||||
# NOTE: overlays depend on the order of rule entries.
|
# NOTE: overlays depend on the order of rule entries.
|
||||||
rules:
|
rules:
|
||||||
- host: grafana
|
- host: grafana.internal
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- pathType: Prefix
|
- pathType: Prefix
|
||||||
|
@ -22,7 +22,7 @@ spec:
|
||||||
name: grafana
|
name: grafana
|
||||||
port:
|
port:
|
||||||
name: service
|
name: service
|
||||||
- host: invidious
|
- host: invidious.internal
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- pathType: Prefix
|
- pathType: Prefix
|
||||||
|
@ -32,7 +32,7 @@ spec:
|
||||||
name: invidious
|
name: invidious
|
||||||
port:
|
port:
|
||||||
name: http
|
name: http
|
||||||
- host: element
|
- host: element.internal
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- pathType: Prefix
|
- pathType: Prefix
|
||||||
|
@ -42,7 +42,7 @@ spec:
|
||||||
name: element
|
name: element
|
||||||
port:
|
port:
|
||||||
name: http
|
name: http
|
||||||
- host: gitea
|
- host: gitea.internal
|
||||||
http:
|
http:
|
||||||
paths:
|
paths:
|
||||||
- pathType: Prefix
|
- pathType: Prefix
|
||||||
|
|
|
@ -1,4 +1,13 @@
|
||||||
---
|
---
|
||||||
|
# Configure the ingress-nginx to use specific nodePorts for HTTP and HTTPS
|
||||||
|
# traffic. This allows the cluster to route traffic to the service via port
|
||||||
|
# mappings.
|
||||||
|
- op: replace
|
||||||
|
path: /spec/ports/0/nodePort
|
||||||
|
value: 32048
|
||||||
|
- op: replace
|
||||||
|
path: /spec/ports/1/nodePort
|
||||||
|
value: 32049
|
||||||
# Force the ingress-nginx service to expose port 22. This allows traffic to be
|
# Force the ingress-nginx service to expose port 22. This allows traffic to be
|
||||||
# routed to the Gitea SSH service.
|
# routed to the Gitea SSH service.
|
||||||
- op: add
|
- op: add
|
||||||
|
|
|
@ -6,13 +6,13 @@ RUN_USER = git
|
||||||
APP_DATA_PATH = /data/gitea
|
APP_DATA_PATH = /data/gitea
|
||||||
PROTOCOL = http
|
PROTOCOL = http
|
||||||
HTTP_PORT = 3000
|
HTTP_PORT = 3000
|
||||||
ROOT_URL = http://localhost:3000
|
ROOT_URL = http://gitea.internal
|
||||||
SSH_DOMAIN = localhost
|
SSH_DOMAIN = gitea.internal
|
||||||
SSH_LISTEN_PORT = 2222
|
SSH_LISTEN_PORT = 2222
|
||||||
SSH_PORT = 2222
|
SSH_PORT = 2222
|
||||||
START_SSH_SERVER = true
|
START_SSH_SERVER = true
|
||||||
ENABLE_PPROF = false
|
ENABLE_PPROF = false
|
||||||
DOMAIN = localhost:3000
|
DOMAIN = gitea.internal
|
||||||
OFFLINE_MODE = false
|
OFFLINE_MODE = false
|
||||||
LFS_START_SERVER = true
|
LFS_START_SERVER = true
|
||||||
LFS_JWT_SECRET = ebGusL71uqCv_YcAzbhoINeXMj1DtMO3q6StXHDzyi8
|
LFS_JWT_SECRET = ebGusL71uqCv_YcAzbhoINeXMj1DtMO3q6StXHDzyi8
|
||||||
|
@ -68,7 +68,7 @@ ENABLE_CAPTCHA = false
|
||||||
DEFAULT_KEEP_EMAIL_PRIVATE = true
|
DEFAULT_KEEP_EMAIL_PRIVATE = true
|
||||||
DEFAULT_ALLOW_CREATE_ORGANIZATION = true
|
DEFAULT_ALLOW_CREATE_ORGANIZATION = true
|
||||||
DEFAULT_ENABLE_TIMETRACKING = true
|
DEFAULT_ENABLE_TIMETRACKING = true
|
||||||
NO_REPLY_ADDRESS = noreply.localhost
|
NO_REPLY_ADDRESS = noreply.gitea.internal
|
||||||
|
|
||||||
[database]
|
[database]
|
||||||
DB_TYPE = postgres
|
DB_TYPE = postgres
|
||||||
|
|
|
@ -1,27 +1,4 @@
|
||||||
|
# TODO: setup TLS certs for local cluster.
|
||||||
- op: replace
|
- op: replace
|
||||||
path: /spec/ingressClassName
|
path: /spec/ingressClassName
|
||||||
value: dev-nginx
|
value: dev-nginx
|
||||||
- op: add
|
|
||||||
path: /metadata/annotations
|
|
||||||
value:
|
|
||||||
cert-manager.io/cluster-issuer: cluster-issuer-selfsigned
|
|
||||||
- op: replace
|
|
||||||
path: /spec/tls
|
|
||||||
value:
|
|
||||||
- hosts:
|
|
||||||
- grafana.local
|
|
||||||
- invidious.local
|
|
||||||
- element.local
|
|
||||||
- gitea.local
|
|
||||||
- op: replace
|
|
||||||
path: /spec/rules/0/host
|
|
||||||
value: grafana.local
|
|
||||||
- op: replace
|
|
||||||
path: /spec/rules/1/host
|
|
||||||
value: invidious.local
|
|
||||||
- op: replace
|
|
||||||
path: /spec/rules/2/host
|
|
||||||
value: element.local
|
|
||||||
- op: replace
|
|
||||||
path: /spec/rules/3/host
|
|
||||||
value: gitea.local
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
domain: localhost:3000
|
domain: invidious.local
|
||||||
channel_threads: 1
|
channel_threads: 1
|
||||||
feed_threads: 1
|
feed_threads: 1
|
||||||
registration_enabled: true
|
registration_enabled: true
|
||||||
|
|
|
@ -0,0 +1,18 @@
|
||||||
|
kind: Cluster
|
||||||
|
apiVersion: kind.x-k8s.io/v1alpha4
|
||||||
|
nodes:
|
||||||
|
- role: control-plane
|
||||||
|
kubeadmConfigPatches:
|
||||||
|
- |
|
||||||
|
kind: InitConfiguration
|
||||||
|
nodeRegistration:
|
||||||
|
kubeletExtraArgs:
|
||||||
|
node-labels: "ingress-ready=true"
|
||||||
|
extraPortMappings:
|
||||||
|
- containerPort: 32048
|
||||||
|
hostPort: 80
|
||||||
|
protocol: TCP
|
||||||
|
listenAddress: "0.0.0.0"
|
||||||
|
- containerPort: 32049
|
||||||
|
hostPort: 443
|
||||||
|
protocol: TCP
|
Loading…
Reference in New Issue