mirror of
https://github.com/submariner-io/submariner-charts.git
synced 2026-09-21 20:50:35 +00:00
Compare commits
81
Commits
@@ -0,0 +1,8 @@
|
|||||||
|
---
|
||||||
|
name: Broken link detected by CI
|
||||||
|
labels: bug
|
||||||
|
---
|
||||||
|
|
||||||
|
<!-- Used by automation to raise an Issue when the periodic link aliveness tests detect a broken link. -->
|
||||||
|
|
||||||
|
Periodic link aliveness CI detected a broken link. Please see the job results for details.
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
---
|
||||||
|
# Configuration for probot-stale - https://github.com/probot/stale
|
||||||
|
|
||||||
|
# Number of days of inactivity before an Issue becomes stale (pull request is overridden later)
|
||||||
|
daysUntilStale: 60
|
||||||
|
|
||||||
|
# Number of days of inactivity before an Issue or Pull Request with the stale label is closed.
|
||||||
|
# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale.
|
||||||
|
daysUntilClose: 7
|
||||||
|
|
||||||
|
# Only issues or pull requests with all of these labels are check if stale. Defaults to `[]` (disabled)
|
||||||
|
onlyLabels: []
|
||||||
|
|
||||||
|
# Issues or Pull Requests with these labels will never be considered stale. Set to `[]` to disable
|
||||||
|
exemptLabels:
|
||||||
|
- security
|
||||||
|
- confirmed
|
||||||
|
|
||||||
|
# Set to true to ignore issues in a project (defaults to false)
|
||||||
|
exemptProjects: false
|
||||||
|
|
||||||
|
# Set to true to ignore issues in a milestone (defaults to false)
|
||||||
|
exemptMilestones: false
|
||||||
|
|
||||||
|
# Set to true to ignore issues with an assignee (defaults to false)
|
||||||
|
exemptAssignees: false
|
||||||
|
|
||||||
|
# Label to use when marking as stale
|
||||||
|
staleLabel: wontfix
|
||||||
|
|
||||||
|
# Comment to post when marking as stale. Set to `false` to disable
|
||||||
|
markComment: >
|
||||||
|
This issue has been automatically marked as stale because it has not had
|
||||||
|
activity for 60 days. It will be closed if no further activity occurs.
|
||||||
|
Please make a comment if this issue/pr is still valid. Thank you
|
||||||
|
for your contributions.
|
||||||
|
|
||||||
|
# Comment to post when removing the stale label.
|
||||||
|
# unmarkComment: >
|
||||||
|
# Your comment here.
|
||||||
|
|
||||||
|
# Comment to post when closing a stale Issue or Pull Request.
|
||||||
|
# closeComment: >
|
||||||
|
# Your comment here.
|
||||||
|
|
||||||
|
# Limit the number of actions per hour, from 1-30. Default is 30
|
||||||
|
limitPerRun: 30
|
||||||
|
|
||||||
|
# Limit to only `issues` or `pulls`
|
||||||
|
# only: issues
|
||||||
|
|
||||||
|
pulls:
|
||||||
|
daysUntilStale: 30
|
||||||
|
markComment: >
|
||||||
|
This pull request has been automatically marked as stale because it has not had
|
||||||
|
recent activity. It will be closed if no further activity occurs. Thank you
|
||||||
|
for your contributions.
|
||||||
@@ -0,0 +1,57 @@
|
|||||||
|
---
|
||||||
|
name: Linting
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
dco:
|
||||||
|
name: DCO in Commit Message(s)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Get PR commits
|
||||||
|
id: 'get-pr-commits'
|
||||||
|
uses: tim-actions/get-pr-commits@master
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
- name: Run DCO check
|
||||||
|
uses: tim-actions/dco@master
|
||||||
|
with:
|
||||||
|
commits: ${{ steps.get-pr-commits.outputs.commits }}
|
||||||
|
|
||||||
|
markdown-link-check:
|
||||||
|
name: Markdown Links (modified files)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out the repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Run markdown-link-check
|
||||||
|
uses: gaurav-nelson/github-action-markdown-link-check@v1
|
||||||
|
with:
|
||||||
|
config-file: ".markdownlinkcheck.json"
|
||||||
|
check-modified-files-only: "yes"
|
||||||
|
|
||||||
|
markdownlint:
|
||||||
|
name: Markdown
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out the repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Run markdownlint
|
||||||
|
uses: nosborn/github-action-markdown-cli@v1.1.1
|
||||||
|
with:
|
||||||
|
files: .
|
||||||
|
config_file: ".markdownlint.yml"
|
||||||
|
|
||||||
|
yaml-lint:
|
||||||
|
name: YAML
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out the repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Run yamllint
|
||||||
|
uses: ibiqlik/action-yamllint@v1
|
||||||
|
with:
|
||||||
|
file_or_dir: submariner/values.yaml submariner-k8s-broker/values.yaml submariner/Chart.yaml submariner-k8s-broker/Chart.yaml
|
||||||
|
config_file: .yamllint.yml
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
---
|
||||||
|
name: Periodic
|
||||||
|
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: "0 0 * * 0"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
markdown-link-check-periodic:
|
||||||
|
name: Markdown Links (all files)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Check out the repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Run markdown-link-check
|
||||||
|
uses: gaurav-nelson/github-action-markdown-link-check@v1
|
||||||
|
with:
|
||||||
|
config-file: ".markdownlinkcheck.json"
|
||||||
|
|
||||||
|
- name: Raise an Issue to report broken links
|
||||||
|
if: ${{ failure() }}
|
||||||
|
uses: JasonEtco/create-an-issue@v2
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
filename: .github/ISSUE_TEMPLATE/broken-link.md
|
||||||
@@ -0,0 +1,25 @@
|
|||||||
|
---
|
||||||
|
name: Release Charts
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
release:
|
||||||
|
name: Release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Configure Git
|
||||||
|
run: |
|
||||||
|
git config user.name "$GITHUB_ACTOR"
|
||||||
|
git config user.email "$GITHUB_ACTOR@users.noreply.github.com"
|
||||||
|
|
||||||
|
- name: Run chart-releaser
|
||||||
|
uses: helm/chart-releaser-action@v1
|
||||||
|
env:
|
||||||
|
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
.idea
|
||||||
|
*.tgz
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"ignorePatterns": [
|
||||||
|
{
|
||||||
|
"pattern": "^https://github.com/\\S+/\\S+/(issues|pull)/[0-9]+"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"pattern": "^http://localhost:"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
---
|
||||||
|
# Breaks reusing MD snippets extracted to files
|
||||||
|
first-line-heading: false
|
||||||
|
|
||||||
|
# Set maximum line Length to 140c to match Go linting
|
||||||
|
line-length:
|
||||||
|
line_length: 140
|
||||||
|
|
||||||
|
# Allow HTML span elements to set font sizes
|
||||||
|
no-inline-html:
|
||||||
|
allowed_elements:
|
||||||
|
- span
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
---
|
||||||
|
extends: default
|
||||||
|
rules:
|
||||||
|
comments: disable
|
||||||
|
comments-indentation: disable
|
||||||
|
line-length:
|
||||||
|
max: 150
|
||||||
|
braces:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 0
|
||||||
|
brackets:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 0
|
||||||
|
indentation:
|
||||||
|
indent-sequences: consistent
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
* @mangelajo @tpantelis @Oats87
|
||||||
@@ -1,3 +1,116 @@
|
|||||||
# submariner-charts
|
# submariner-charts
|
||||||
|
|
||||||
Please see https://github.com/rancher/submariner for more information. This is only a supporting repository for Submariner
|
Please see the [Helm docs on Submariner's website](https://submariner.io/deployment/helm/).
|
||||||
|
|
||||||
|
## Dev workflow
|
||||||
|
|
||||||
|
### Prerequisites
|
||||||
|
|
||||||
|
- [helm]
|
||||||
|
- [docker] or [podman]
|
||||||
|
|
||||||
|
### Create a fork and checkout
|
||||||
|
|
||||||
|
[Create a fork] of the original repository, clone it locally and checkout a new branch from master.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/myuser/submariner-charts.git
|
||||||
|
cd submariner-charts
|
||||||
|
git checkout -b new-feature
|
||||||
|
```
|
||||||
|
|
||||||
|
Now you can modify the helm charts according to your needs.
|
||||||
|
|
||||||
|
### Serve the modified charts
|
||||||
|
|
||||||
|
Before serving the modified charts, the charts must be packaged for local usage.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm package ./submariner
|
||||||
|
helm package ./submariner-k8s-broker
|
||||||
|
```
|
||||||
|
|
||||||
|
Note: if you just installed helm, you have to init the helm, by running
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm init --client-only
|
||||||
|
```
|
||||||
|
|
||||||
|
Serve the packaged charts through a local helm repository:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker run -d --rm --name helm-repo -p 8080:8080 -v $PWD:/charts -e DEBUG=true -e STORAGE=local -e STORAGE_LOCAL_ROOTDIR=/charts chartmuseum/chartmuseum
|
||||||
|
```
|
||||||
|
|
||||||
|
or
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo podman run -d --rm --name helm-repo -p 8080:8080 -v $PWD:/charts -e DEBUG=true -e STORAGE=local -e STORAGE_LOCAL_ROOTDIR=/charts chartmuseum/chartmuseum
|
||||||
|
```
|
||||||
|
|
||||||
|
Get the container internal ip:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' helm-repo
|
||||||
|
```
|
||||||
|
|
||||||
|
The local container will serve the charts locally on port 8080.
|
||||||
|
|
||||||
|
Get logs for the container:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
docker logs -f helm-repo
|
||||||
|
```
|
||||||
|
|
||||||
|
### Use the modified charts
|
||||||
|
|
||||||
|
Init helm
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm init --client-only
|
||||||
|
```
|
||||||
|
|
||||||
|
Add your local repository to helm
|
||||||
|
|
||||||
|
```bash
|
||||||
|
internal_ip=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' helm-repo)
|
||||||
|
helm repo add test-repo http://$internal_ip:8080
|
||||||
|
```
|
||||||
|
|
||||||
|
List the repos:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm repo list
|
||||||
|
```
|
||||||
|
|
||||||
|
You should be able to see test-repo in the list
|
||||||
|
|
||||||
|
Search the new repo for submariner charts:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm search -l test-repo
|
||||||
|
```
|
||||||
|
|
||||||
|
### Modify submariner e2e tests helm deployment script to use your local test-repo
|
||||||
|
|
||||||
|
You can test your helm-charts with e2e tests from the [shipyard](https://github.com/submariner-io/shipyard) repository.
|
||||||
|
In the file `scripts/shared/lib/deploy_helm` change the line from:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
helm repo add submariner-latest https://submariner-io.github.io/submariner-charts/charts
|
||||||
|
```
|
||||||
|
|
||||||
|
to
|
||||||
|
|
||||||
|
```bash
|
||||||
|
internal_ip=$(docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' helm-repo)
|
||||||
|
helm repo add submariner-latest http://$internal_ip:8080
|
||||||
|
```
|
||||||
|
|
||||||
|
<!--links-->
|
||||||
|
[helm]: https://helm.sh/docs/using_helm/#installing-helm
|
||||||
|
[docker]: https://docs.docker.com/install/
|
||||||
|
[podman]: https://podman.io/getting-started/installation
|
||||||
|
[Create a fork]: https://help.github.com/en/articles/fork-a-repo
|
||||||
|
|||||||
@@ -1,11 +1,12 @@
|
|||||||
|
---
|
||||||
name: submariner-k8s-broker
|
name: submariner-k8s-broker
|
||||||
version: 0.0.1
|
version: 0.6.0
|
||||||
appVersion: v0.0.1
|
appVersion: 0.6.0
|
||||||
description: Submariner Kubernetes Broker
|
description: Submariner Kubernetes Broker
|
||||||
keywords:
|
keywords:
|
||||||
home: https://submariner.io/
|
home: https://submariner-io.github.io/
|
||||||
sources:
|
sources:
|
||||||
- https://github.com/rancher/submariner-charts
|
- https://submariner-io.github.io/submariner-charts/charts
|
||||||
maintainers:
|
maintainers:
|
||||||
- name: Rancher Labs
|
- name: Submariner Developers
|
||||||
email: charts@rancher.com
|
email: submariner-dev@googlegroups.com
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ The Submariner Kubernetes Broker is now setup.
|
|||||||
|
|
||||||
You can retrieve the server URL by running
|
You can retrieve the server URL by running
|
||||||
|
|
||||||
$ SUBMARINER_BROKER_URL=$(kubectl -n default get endpoints kubernetes -o jsonpath="{.subsets[0].addresses[0].ip}:{.subsets[0].ports[0].port}")
|
$ SUBMARINER_BROKER_URL=$(kubectl -n default get endpoints kubernetes -o jsonpath="{.subsets[0].addresses[0].ip}:{.subsets[0].ports[?(@.name=='https')].port}")
|
||||||
|
|
||||||
The broker client token and CA can be retrieved by running
|
The broker client token and CA can be retrieved by running
|
||||||
|
|
||||||
|
|||||||
@@ -26,4 +26,85 @@ spec:
|
|||||||
kind: Endpoint
|
kind: Endpoint
|
||||||
plural: endpoints
|
plural: endpoints
|
||||||
scope: Namespaced
|
scope: Namespaced
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: gateways.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: submariner.io
|
||||||
|
version: v1
|
||||||
|
names:
|
||||||
|
kind: Gateway
|
||||||
|
plural: gateways
|
||||||
|
scope: Namespaced
|
||||||
|
additionalPrinterColumns:
|
||||||
|
- name: ha-status
|
||||||
|
type: string
|
||||||
|
description: High Availability Status of the Gateway
|
||||||
|
JSONPath: .status.haStatus
|
||||||
|
---
|
||||||
|
{{- if .Values.submariner.serviceDiscovery }}
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: multiclusterservices.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v1
|
||||||
|
names:
|
||||||
|
kind: MultiClusterService
|
||||||
|
plural: multiclusterservices
|
||||||
|
singular: multiclusterservice
|
||||||
|
scope: Namespaced
|
||||||
|
validation:
|
||||||
|
openAPIV3Schema:
|
||||||
|
properties:
|
||||||
|
spec:
|
||||||
|
properties:
|
||||||
|
clusterServiceInfo:
|
||||||
|
properties:
|
||||||
|
clusterID:
|
||||||
|
type: "string"
|
||||||
|
clusterDomain:
|
||||||
|
type: "string"
|
||||||
|
serviceIP:
|
||||||
|
type: "string"
|
||||||
|
port:
|
||||||
|
type: "integer"
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: serviceexports.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v2alpha1
|
||||||
|
names:
|
||||||
|
kind: ServiceExport
|
||||||
|
plural: serviceexports
|
||||||
|
singular: serviceexport
|
||||||
|
scope: Namespaced
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: serviceimports.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v2alpha1
|
||||||
|
names:
|
||||||
|
kind: ServiceImport
|
||||||
|
plural: serviceimports
|
||||||
|
singular: serviceimport
|
||||||
|
scope: Namespaced
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
@@ -12,6 +12,12 @@ rules:
|
|||||||
- apiGroups: ["submariner.io"]
|
- apiGroups: ["submariner.io"]
|
||||||
resources: ["clusters", "endpoints"]
|
resources: ["clusters", "endpoints"]
|
||||||
verbs: ["create", "get", "list", "watch", "patch", "update", "delete"]
|
verbs: ["create", "get", "list", "watch", "patch", "update", "delete"]
|
||||||
|
- apiGroups: ["lighthouse.submariner.io"]
|
||||||
|
resources: ["*"]
|
||||||
|
verbs: ["create", "get", "list", "watch", "patch", "update", "delete"]
|
||||||
|
- apiGroups: ["discovery.k8s.io"]
|
||||||
|
resources: ["endpointslices"]
|
||||||
|
verbs: ["create", "get", "list", "watch","patch", "update", "delete"]
|
||||||
---
|
---
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
kind: RoleBinding
|
kind: RoleBinding
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
---
|
||||||
rbac:
|
rbac:
|
||||||
create: true
|
create: true
|
||||||
crd:
|
crd:
|
||||||
@@ -5,4 +6,6 @@ crd:
|
|||||||
serviceAccounts:
|
serviceAccounts:
|
||||||
client:
|
client:
|
||||||
create: true
|
create: true
|
||||||
name: ""
|
name: ""
|
||||||
|
submariner:
|
||||||
|
serviceDiscovery: false
|
||||||
|
|||||||
@@ -1,11 +1,12 @@
|
|||||||
|
---
|
||||||
name: submariner
|
name: submariner
|
||||||
version: 0.0.1
|
version: 0.6.0
|
||||||
appVersion: v0.0.1
|
appVersion: 0.6.0
|
||||||
description: Submariner
|
description: Submariner enables direct networking between Pods and Services in different Kubernetes clusters
|
||||||
keywords:
|
keywords:
|
||||||
home: https://submariner.io/
|
home: https://submariner-io.github.io/
|
||||||
sources:
|
sources:
|
||||||
- https://github.com/rancher/submariner-charts
|
- https://submariner-io.github.io/submariner-charts/charts
|
||||||
maintainers:
|
maintainers:
|
||||||
- name: Rancher Labs
|
- name: Submariner Developers
|
||||||
email: charts@rancher.com
|
email: submariner-dev@googlegroups.com
|
||||||
|
|||||||
@@ -8,12 +8,12 @@ questions:
|
|||||||
group: "Container Images"
|
group: "Container Images"
|
||||||
subquestions:
|
subquestions:
|
||||||
- variable: engine.image.repository
|
- variable: engine.image.repository
|
||||||
default: "oats87/submariner-engine"
|
default: "quay.io/submariner/submariner"
|
||||||
description: "Submariner Engine Image Repository"
|
description: "Submariner Engine Image Repository"
|
||||||
type: string
|
type: string
|
||||||
label: Submariner Engine Image Repository
|
label: Submariner Engine Image Repository
|
||||||
- variable: engine.image.tag
|
- variable: engine.image.tag
|
||||||
default: "dev"
|
default: "0.6.0"
|
||||||
description: "Submariner Engine Image Tag"
|
description: "Submariner Engine Image Tag"
|
||||||
type: string
|
type: string
|
||||||
label: Submariner Engine Image Tag
|
label: Submariner Engine Image Tag
|
||||||
@@ -26,12 +26,12 @@ questions:
|
|||||||
group: "Container Images"
|
group: "Container Images"
|
||||||
subquestions:
|
subquestions:
|
||||||
- variable: routeAgent.image.repository
|
- variable: routeAgent.image.repository
|
||||||
default: "oats87/submariner-route-agent"
|
default: "quay.io/submariner/submariner-route-agent"
|
||||||
description: "Submariner Route Agent Image Repository"
|
description: "Submariner Route Agent Image Repository"
|
||||||
type: string
|
type: string
|
||||||
label: Submariner Route Agent Image Repository
|
label: Submariner Route Agent Image Repository
|
||||||
- variable: routeAgent.image.tag
|
- variable: routeAgent.image.tag
|
||||||
default: "dev"
|
default: "0.6.0"
|
||||||
description: "Submariner Route Agent Image Tag"
|
description: "Submariner Route Agent Image Tag"
|
||||||
type: string
|
type: string
|
||||||
label: Submariner Route Agent Image Tag
|
label: Submariner Route Agent Image Tag
|
||||||
@@ -70,7 +70,7 @@ questions:
|
|||||||
label: "Broker Server"
|
label: "Broker Server"
|
||||||
description: "Broker server to use (without the https://)"
|
description: "Broker server to use (without the https://)"
|
||||||
- variable: broker.insecure
|
- variable: broker.insecure
|
||||||
type: bool
|
type: boolean
|
||||||
default: false
|
default: false
|
||||||
show_subquestion_if: false
|
show_subquestion_if: false
|
||||||
group: "Broker Configuration"
|
group: "Broker Configuration"
|
||||||
@@ -129,4 +129,10 @@ questions:
|
|||||||
default: false
|
default: false
|
||||||
group: "Advanced Configuration"
|
group: "Advanced Configuration"
|
||||||
description: "Enable Charon debug mode"
|
description: "Enable Charon debug mode"
|
||||||
label: "Charon Enabled"
|
label: "Charon Enabled"
|
||||||
|
- variable: submariner.cableDriver
|
||||||
|
type: string
|
||||||
|
default: ""
|
||||||
|
group: "Advanced Configuration"
|
||||||
|
description: "Cable driver implementation"
|
||||||
|
label: "Cable Driver"
|
||||||
|
|||||||
@@ -51,4 +51,33 @@ Create the name of the submariner-route-agent service account to use
|
|||||||
{{- else -}}
|
{{- else -}}
|
||||||
{{ default "default" .Values.serviceAccounts.routeAgent.name }}
|
{{ default "default" .Values.serviceAccounts.routeAgent.name }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the submariner-globalnet service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "submariner.globalnetServiceAccountName" -}}
|
||||||
|
{{- if .Values.serviceAccounts.globalnet.create -}}
|
||||||
|
{{ default (printf "%s-globalnet" (include "submariner.fullname" .)) .Values.serviceAccounts.globalnet.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccounts.globalnet.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the submariner-lighthouse service account to use
|
||||||
|
*/}}
|
||||||
|
{{- define "submariner.lighthouseServiceAccountName" -}}
|
||||||
|
{{- if .Values.submariner.serviceDiscovery -}}
|
||||||
|
{{ default (printf "%s-lighthouse" (include "submariner.fullname" .)) .Values.serviceAccounts.lighthouse.name }}
|
||||||
|
{{- else -}}
|
||||||
|
{{ default "default" .Values.serviceAccounts.lighthouse.name }}
|
||||||
|
{{- end -}}
|
||||||
|
{{- end -}}
|
||||||
|
|
||||||
|
{{/*
|
||||||
|
Create the name of the submariner-lighthouse-coredns service name to use
|
||||||
|
*/}}
|
||||||
|
{{- define "submariner.lighthouseDnsName" -}}
|
||||||
|
{{- default (printf "%s-lighthouse-coredns" (include "submariner.fullname" .)) .Values.lighthouseCoredns.name }}
|
||||||
|
{{- end -}}
|
||||||
|
|||||||
@@ -26,4 +26,85 @@ spec:
|
|||||||
kind: Endpoint
|
kind: Endpoint
|
||||||
plural: endpoints
|
plural: endpoints
|
||||||
scope: Namespaced
|
scope: Namespaced
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: gateways.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: submariner.io
|
||||||
|
version: v1
|
||||||
|
names:
|
||||||
|
kind: Gateway
|
||||||
|
plural: gateways
|
||||||
|
scope: Namespaced
|
||||||
|
additionalPrinterColumns:
|
||||||
|
- name: ha-status
|
||||||
|
type: string
|
||||||
|
description: High Availability Status of the Gateway
|
||||||
|
JSONPath: .status.haStatus
|
||||||
|
---
|
||||||
|
{{- if .Values.submariner.serviceDiscovery }}
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: multiclusterservices.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v1
|
||||||
|
names:
|
||||||
|
kind: MultiClusterService
|
||||||
|
plural: multiclusterservices
|
||||||
|
singular: multiclusterservice
|
||||||
|
scope: Namespaced
|
||||||
|
validation:
|
||||||
|
openAPIV3Schema:
|
||||||
|
properties:
|
||||||
|
spec:
|
||||||
|
properties:
|
||||||
|
clusterServiceInfo:
|
||||||
|
properties:
|
||||||
|
clusterID:
|
||||||
|
type: "string"
|
||||||
|
clusterDomain:
|
||||||
|
type: "string"
|
||||||
|
serviceIP:
|
||||||
|
type: "string"
|
||||||
|
port:
|
||||||
|
type: "integer"
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: serviceexports.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v2alpha1
|
||||||
|
names:
|
||||||
|
kind: ServiceExport
|
||||||
|
plural: serviceexports
|
||||||
|
singular: serviceexport
|
||||||
|
scope: Namespaced
|
||||||
|
---
|
||||||
|
apiVersion: apiextensions.k8s.io/v1beta1
|
||||||
|
kind: CustomResourceDefinition
|
||||||
|
metadata:
|
||||||
|
name: serviceimports.lighthouse.submariner.io
|
||||||
|
annotations:
|
||||||
|
"helm.sh/hook": crd-install
|
||||||
|
spec:
|
||||||
|
group: lighthouse.submariner.io
|
||||||
|
version: v2alpha1
|
||||||
|
names:
|
||||||
|
kind: ServiceImport
|
||||||
|
plural: serviceimports
|
||||||
|
singular: serviceimport
|
||||||
|
scope: Namespaced
|
||||||
|
{{- end }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
apiVersion: apps/v1beta2
|
apiVersion: apps/v1
|
||||||
kind: Deployment
|
kind: DaemonSet
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
labels:
|
||||||
heritage: {{ .Release.Service | quote }}
|
heritage: {{ .Release.Service | quote }}
|
||||||
@@ -7,18 +7,15 @@ metadata:
|
|||||||
chart: {{ template "submariner.chart" . }}
|
chart: {{ template "submariner.chart" . }}
|
||||||
app: {{ template "submariner.fullname" . }}-engine
|
app: {{ template "submariner.fullname" . }}-engine
|
||||||
component: engine
|
component: engine
|
||||||
name: {{ template "submariner.fullname" . }}
|
name: {{ template "submariner.fullname" . }}-gateway
|
||||||
spec:
|
spec:
|
||||||
progressDeadlineSeconds: 600
|
|
||||||
replicas: 1
|
|
||||||
revisionHistoryLimit: 5
|
revisionHistoryLimit: 5
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: {{ template "submariner.fullname" . }}-engine
|
app: {{ template "submariner.fullname" . }}-engine
|
||||||
strategy:
|
updateStrategy:
|
||||||
rollingUpdate:
|
rollingUpdate:
|
||||||
maxSurge: 1
|
maxUnavailable: 1
|
||||||
maxUnavailable: 0
|
|
||||||
type: RollingUpdate
|
type: RollingUpdate
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
@@ -60,6 +57,8 @@ spec:
|
|||||||
value: "{{ .Values.submariner.clusterCidr }}"
|
value: "{{ .Values.submariner.clusterCidr }}"
|
||||||
- name: SUBMARINER_SERVICECIDR
|
- name: SUBMARINER_SERVICECIDR
|
||||||
value: "{{ .Values.submariner.serviceCidr }}"
|
value: "{{ .Values.submariner.serviceCidr }}"
|
||||||
|
- name: SUBMARINER_GLOBALCIDR
|
||||||
|
value: "{{ .Values.submariner.globalCidr }}"
|
||||||
- name: SUBMARINER_TOKEN
|
- name: SUBMARINER_TOKEN
|
||||||
value: "{{ .Values.submariner.apiToken }}"
|
value: "{{ .Values.submariner.apiToken }}"
|
||||||
- name: SUBMARINER_CLUSTERID
|
- name: SUBMARINER_CLUSTERID
|
||||||
@@ -72,6 +71,8 @@ spec:
|
|||||||
value: "{{ .Values.submariner.natEnabled }}"
|
value: "{{ .Values.submariner.natEnabled }}"
|
||||||
- name: SUBMARINER_BROKER
|
- name: SUBMARINER_BROKER
|
||||||
value: "{{ .Values.broker.type }}"
|
value: "{{ .Values.broker.type }}"
|
||||||
|
- name: SUBMARINER_CABLEDRIVER
|
||||||
|
value: "{{ .Values.submariner.cableDriver }}"
|
||||||
{{- if eq .Values.broker.type "phpapi" }}
|
{{- if eq .Values.broker.type "phpapi" }}
|
||||||
- name: BROKER_PHPAPI_PROTO
|
- name: BROKER_PHPAPI_PROTO
|
||||||
value: "{{ .Values.broker.proto }}"
|
value: "{{ .Values.broker.proto }}"
|
||||||
@@ -97,7 +98,17 @@ spec:
|
|||||||
value: "{{ .Values.ipsec.psk }}"
|
value: "{{ .Values.ipsec.psk }}"
|
||||||
- name: CE_IPSEC_DEBUG
|
- name: CE_IPSEC_DEBUG
|
||||||
value: "{{ .Values.ipsec.debug }}"
|
value: "{{ .Values.ipsec.debug }}"
|
||||||
image: {{ .Values.engine.image.repository }}:{{ .Values.engine.image.tag }}
|
- name: CE_IPSEC_IKEPORT
|
||||||
|
value: "{{ .Values.ipsec.ikePort }}"
|
||||||
|
- name: CE_IPSEC_NATTPORT
|
||||||
|
value: "{{ .Values.ipsec.natPort }}"
|
||||||
|
- name: LEADERSHIP_LEASEDURATION
|
||||||
|
value: "{{ .Values.leadership.leaseDuration }}"
|
||||||
|
- name: LEADERSHIP_RENEWDEADLINE
|
||||||
|
value: "{{ .Values.leadership.renewDeadline }}"
|
||||||
|
- name: LEADERSHIP_RETRYPERIOD
|
||||||
|
value: "{{ .Values.leadership.retryPeriod }}"
|
||||||
|
image: {{ .Values.engine.image.repository }}:{{ default .Chart.AppVersion .Values.engine.image.tag }}
|
||||||
imagePullPolicy: {{ .Values.engine.image.pullPolicy }}
|
imagePullPolicy: {{ .Values.engine.image.pullPolicy }}
|
||||||
name: submariner
|
name: submariner
|
||||||
resources:
|
resources:
|
||||||
@@ -119,5 +130,5 @@ spec:
|
|||||||
restartPolicy: Always
|
restartPolicy: Always
|
||||||
schedulerName: default-scheduler
|
schedulerName: default-scheduler
|
||||||
securityContext: {}
|
securityContext: {}
|
||||||
terminationGracePeriodSeconds: 0
|
terminationGracePeriodSeconds: 1
|
||||||
serviceAccountName: {{ template "submariner.engineServiceAccountName" . }}
|
serviceAccountName: {{ template "submariner.engineServiceAccountName" . }}
|
||||||
|
|||||||
@@ -0,0 +1,59 @@
|
|||||||
|
{{- if ne .Values.submariner.globalCidr "" }}
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: DaemonSet
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}-globalnet
|
||||||
|
labels:
|
||||||
|
heritage: {{ .Release.Service | quote }}
|
||||||
|
release: {{ .Release.Name | quote }}
|
||||||
|
chart: {{ template "submariner.chart" . }}
|
||||||
|
app: {{ template "submariner.fullname" . }}-globalnet
|
||||||
|
component: globalnet
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: {{ template "submariner.fullname" . }}-globalnet
|
||||||
|
updateStrategy:
|
||||||
|
rollingUpdate:
|
||||||
|
maxUnavailable: 1
|
||||||
|
type: RollingUpdate
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: {{ template "submariner.fullname" . }}-globalnet
|
||||||
|
spec:
|
||||||
|
hostNetwork: true
|
||||||
|
serviceAccountName: submariner-globalnet
|
||||||
|
serviceAccount: submariner-globalnet
|
||||||
|
terminationGracePeriodSeconds: 2
|
||||||
|
nodeSelector:
|
||||||
|
submariner.io/gateway: 'true'
|
||||||
|
containers:
|
||||||
|
- name: {{ template "submariner.fullname" . }}-globalnet
|
||||||
|
image: {{ .Values.globalnet.image.repository }}:{{ default .Chart.AppVersion .Values.globalnet.image.tag }}
|
||||||
|
imagePullPolicy: {{ .Values.globalnet.image.pullPolicy }}
|
||||||
|
env:
|
||||||
|
- name: SUBMARINER_CLUSTERID
|
||||||
|
value: '{{ .Values.submariner.clusterId }}'
|
||||||
|
- name: SUBMARINER_EXCLUDENS
|
||||||
|
value: 'submariner-operator,kube-system,operators'
|
||||||
|
- name: SUBMARINER_NAMESPACE
|
||||||
|
value: '{{ .Release.Namespace }}'
|
||||||
|
securityContext:
|
||||||
|
allowPrivilegeEscalation: true
|
||||||
|
capabilities:
|
||||||
|
add:
|
||||||
|
- ALL
|
||||||
|
privileged: true
|
||||||
|
readOnlyRootFilesystem: false
|
||||||
|
runAsNonRoot: false
|
||||||
|
volumeMounts:
|
||||||
|
# Because we don't actually run iptables locally, but chroot in to the host
|
||||||
|
- mountPath: /host
|
||||||
|
name: host-slash
|
||||||
|
readOnly: true
|
||||||
|
volumes:
|
||||||
|
- name: host-slash
|
||||||
|
hostPath:
|
||||||
|
path: /
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,74 @@
|
|||||||
|
{{- if .Values.submariner.serviceDiscovery }}
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
labels:
|
||||||
|
heritage: {{ .Release.Service | quote }}
|
||||||
|
release: {{ .Release.Name | quote }}
|
||||||
|
chart: {{ template "submariner.chart" . }}
|
||||||
|
app: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
component: lighthouse-coredns
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
replicas: 2
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- args:
|
||||||
|
- -conf
|
||||||
|
- /etc/coredns/Corefile
|
||||||
|
image: {{ .Values.lighthouseCoredns.image.repository }}:{{ default .Chart.AppVersion .Values.lighthouseCoredns.image.tag }}
|
||||||
|
imagePullPolicy: {{ .Values.lighthouseCoredns.image.pullPolicy }}
|
||||||
|
name: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /etc/coredns
|
||||||
|
name: config-volume
|
||||||
|
readOnly: true
|
||||||
|
serviceAccountName: {{ template "submariner.lighthouseServiceAccountName" . }}
|
||||||
|
volumes:
|
||||||
|
- configMap:
|
||||||
|
defaultMode: 420
|
||||||
|
items:
|
||||||
|
- key: Corefile
|
||||||
|
path: Corefile
|
||||||
|
name: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
name: config-volume
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
labels:
|
||||||
|
app: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
spec:
|
||||||
|
ports:
|
||||||
|
- name: udp
|
||||||
|
port: 53
|
||||||
|
protocol: UDP
|
||||||
|
targetPort: 53
|
||||||
|
selector:
|
||||||
|
app: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
type: ClusterIP
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.lighthouseDnsName" . }}
|
||||||
|
data:
|
||||||
|
Corefile: |
|
||||||
|
clusterset.local:53 {
|
||||||
|
{{- if .Values.submariner.debug }}
|
||||||
|
log
|
||||||
|
{{- end }}
|
||||||
|
lighthouse
|
||||||
|
errors
|
||||||
|
health
|
||||||
|
ready
|
||||||
|
}
|
||||||
|
{{- end }}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
{{- if .Values.submariner.serviceDiscovery }}
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}-lighthouse-agent
|
||||||
|
labels:
|
||||||
|
heritage: {{ .Release.Service | quote }}
|
||||||
|
release: {{ .Release.Name | quote }}
|
||||||
|
chart: {{ template "submariner.chart" . }}
|
||||||
|
app: {{ template "submariner.fullname" . }}-lighthouse-agent
|
||||||
|
component: lighthouse
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app: {{ template "submariner.fullname" . }}-lighthouse-agent
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app: {{ template "submariner.fullname" . }}-lighthouse-agent
|
||||||
|
spec:
|
||||||
|
serviceAccountName: {{ template "submariner.lighthouseServiceAccountName" . }}
|
||||||
|
containers:
|
||||||
|
- command:
|
||||||
|
- lighthouse-agent.sh
|
||||||
|
env:
|
||||||
|
- name: SUBMARINER_NAMESPACE
|
||||||
|
value: "{{ .Release.Namespace }}"
|
||||||
|
- name: SUBMARINER_CLUSTERID
|
||||||
|
value: "{{ .Values.submariner.clusterId }}"
|
||||||
|
- name: SUBMARINER_DEBUG
|
||||||
|
value: "{{ .Values.submariner.debug }}"
|
||||||
|
{{- if ne .Values.submariner.globalCidr "" }}
|
||||||
|
- name: SUBMARINER_GLOBALNET_ENABLED
|
||||||
|
value: "true"
|
||||||
|
{{- end }}
|
||||||
|
- name: BROKER_K8S_APISERVER
|
||||||
|
value: "{{ .Values.broker.server }}"
|
||||||
|
- name: BROKER_K8S_APISERVERTOKEN
|
||||||
|
value: "{{ .Values.broker.token }}"
|
||||||
|
- name: BROKER_K8S_REMOTENAMESPACE
|
||||||
|
value: "{{ .Values.broker.namespace }}"
|
||||||
|
{{- if .Values.broker.insecure }}
|
||||||
|
- name: BROKER_K8S_INSECURE
|
||||||
|
value: "true"
|
||||||
|
{{- else }}
|
||||||
|
- name: BROKER_K8S_CA
|
||||||
|
value: "{{ .Values.broker.ca }}"
|
||||||
|
{{- end }}
|
||||||
|
name: {{ template "submariner.fullname" . }}-lighthouse-agent
|
||||||
|
image: {{ .Values.lighthouse.image.repository }}:{{ default .Chart.AppVersion .Values.lighthouse.image.tag }}
|
||||||
|
imagePullPolicy: {{ .Values.lighthouse.image.pullPolicy }}
|
||||||
|
restartPolicy: Always
|
||||||
|
terminationGracePeriodSeconds: 0
|
||||||
|
{{- end }}
|
||||||
@@ -13,7 +13,7 @@ rules:
|
|||||||
resources: ["configmaps"]
|
resources: ["configmaps"]
|
||||||
verbs: ["create", "get", "list", "watch", "patch", "update"]
|
verbs: ["create", "get", "list", "watch", "patch", "update"]
|
||||||
- apiGroups: ["submariner.io"]
|
- apiGroups: ["submariner.io"]
|
||||||
resources: ["clusters", "endpoints"]
|
resources: ["clusters", "endpoints", "gateways"]
|
||||||
verbs: ["create", "get", "list", "watch", "patch", "update", "delete"]
|
verbs: ["create", "get", "list", "watch", "patch", "update", "delete"]
|
||||||
- apiGroups: [""]
|
- apiGroups: [""]
|
||||||
resources: ["events"]
|
resources: ["events"]
|
||||||
@@ -30,8 +30,11 @@ metadata:
|
|||||||
app: {{ template "submariner.name" . }}
|
app: {{ template "submariner.name" . }}
|
||||||
rules:
|
rules:
|
||||||
- apiGroups: ["submariner.io"]
|
- apiGroups: ["submariner.io"]
|
||||||
resources: ["clusters", "endpoints"]
|
resources: ["clusters", "endpoints", "gateways"]
|
||||||
verbs: ["create", "get", "list", "watch", "patch", "update"]
|
verbs: ["create", "get", "list", "watch", "patch", "update"]
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["pods"]
|
||||||
|
verbs: ["get", "watch", "list"]
|
||||||
---
|
---
|
||||||
apiVersion: rbac.authorization.k8s.io/v1
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
kind: RoleBinding
|
kind: RoleBinding
|
||||||
@@ -58,4 +61,86 @@ subjects:
|
|||||||
- kind: ServiceAccount
|
- kind: ServiceAccount
|
||||||
name: {{ template "submariner.routeAgentServiceAccountName" . }}
|
name: {{ template "submariner.routeAgentServiceAccountName" . }}
|
||||||
namespace: {{ .Release.Namespace }}
|
namespace: {{ .Release.Namespace }}
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:routeagent
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["nodes"]
|
||||||
|
verbs: ["get", "update"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:routeagent
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: {{ template "submariner.fullname" . }}:routeagent
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: {{ template "submariner.routeAgentServiceAccountName" . }}
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
|
---
|
||||||
|
{{- if ne .Values.submariner.globalCidr "" }}
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:globalnet
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["services", "namespaces", "pods", "nodes"]
|
||||||
|
verbs: ["get", "list", "watch", "update"]
|
||||||
|
- apiGroups: ["submariner.io"]
|
||||||
|
resources: ["clusters", "endpoints", "gateways"]
|
||||||
|
verbs: ["get", "list", "watch"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:globalnet
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: {{ template "submariner.fullname" . }}:globalnet
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: {{ template "submariner.globalnetServiceAccountName" . }}
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
|
---
|
||||||
|
{{- end -}}
|
||||||
|
{{- if .Values.submariner.serviceDiscovery }}
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:lighthouse
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["services", "namespaces", "configmaps", "endpoints"]
|
||||||
|
verbs: ["get", "list", "watch", "update"]
|
||||||
|
- apiGroups: ["discovery.k8s.io"]
|
||||||
|
resources: ["endpointslices"]
|
||||||
|
verbs: ["create", "get", "list", "watch", "update", "delete", "deletecollection"]
|
||||||
|
- apiGroups: ["lighthouse.submariner.io"]
|
||||||
|
resources: ["*"]
|
||||||
|
verbs: ["create", "get", "list", "watch", "update", "delete"]
|
||||||
|
- apiGroups: ["submariner.io"]
|
||||||
|
resources: ["gateways"]
|
||||||
|
verbs: ["get", "list", "watch"]
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRoleBinding
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.fullname" . }}:lighthouse
|
||||||
|
roleRef:
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
kind: ClusterRole
|
||||||
|
name: {{ template "submariner.fullname" . }}:lighthouse
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: {{ template "submariner.lighthouseServiceAccountName" . }}
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
apiVersion: apps/v1beta2
|
apiVersion: apps/v1
|
||||||
kind: DaemonSet
|
kind: DaemonSet
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ template "submariner.fullname" . }}-routeagent
|
name: {{ template "submariner.fullname" . }}-routeagent
|
||||||
@@ -12,6 +12,10 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: {{ template "submariner.fullname" . }}-routeagent
|
app: {{ template "submariner.fullname" . }}-routeagent
|
||||||
|
updateStrategy:
|
||||||
|
rollingUpdate:
|
||||||
|
maxUnavailable: "100%"
|
||||||
|
type: RollingUpdate
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
labels:
|
labels:
|
||||||
@@ -22,13 +26,13 @@ spec:
|
|||||||
component: routeagent
|
component: routeagent
|
||||||
spec:
|
spec:
|
||||||
serviceAccountName: {{ template "submariner.routeAgentServiceAccountName" . }}
|
serviceAccountName: {{ template "submariner.routeAgentServiceAccountName" . }}
|
||||||
terminationGracePeriodSeconds: 0
|
terminationGracePeriodSeconds: 1
|
||||||
hostNetwork: true
|
hostNetwork: true
|
||||||
containers:
|
containers:
|
||||||
- name: routeagent
|
- name: routeagent
|
||||||
command:
|
command:
|
||||||
- submariner-route-agent.sh
|
- submariner-route-agent.sh
|
||||||
image: {{ .Values.routeAgent.image.repository }}:{{ .Values.routeAgent.image.tag }}
|
image: {{ .Values.routeAgent.image.repository }}:{{ default .Chart.AppVersion .Values.routeAgent.image.tag }}
|
||||||
imagePullPolicy: {{ .Values.routeAgent.image.pullPolicy }}
|
imagePullPolicy: {{ .Values.routeAgent.image.pullPolicy }}
|
||||||
env:
|
env:
|
||||||
- name: SUBMARINER_NAMESPACE
|
- name: SUBMARINER_NAMESPACE
|
||||||
@@ -37,6 +41,10 @@ spec:
|
|||||||
value: "{{ .Values.submariner.clusterId }}"
|
value: "{{ .Values.submariner.clusterId }}"
|
||||||
- name: SUBMARINER_DEBUG
|
- name: SUBMARINER_DEBUG
|
||||||
value: "{{ .Values.submariner.debug }}"
|
value: "{{ .Values.submariner.debug }}"
|
||||||
|
- name: SUBMARINER_CLUSTERCIDR
|
||||||
|
value: "{{ .Values.submariner.clusterCidr }}"
|
||||||
|
- name: SUBMARINER_SERVICECIDR
|
||||||
|
value: "{{ .Values.submariner.serviceCidr }}"
|
||||||
resources:
|
resources:
|
||||||
{{ toYaml .Values.routeAgent.resources | indent 10 }}
|
{{ toYaml .Values.routeAgent.resources | indent 10 }}
|
||||||
securityContext:
|
securityContext:
|
||||||
@@ -47,6 +55,11 @@ spec:
|
|||||||
privileged: true
|
privileged: true
|
||||||
readOnlyRootFilesystem: false
|
readOnlyRootFilesystem: false
|
||||||
runAsNonRoot: false
|
runAsNonRoot: false
|
||||||
|
volumeMounts:
|
||||||
|
# Because we don't actually run iptables locally, but chroot in to the host
|
||||||
|
- mountPath: /host
|
||||||
|
name: host-slash
|
||||||
|
readOnly: true
|
||||||
{{- with .Values.routeAgent.nodeSelector }}
|
{{- with .Values.routeAgent.nodeSelector }}
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
{{ toYaml . | indent 8 }}
|
{{ toYaml . | indent 8 }}
|
||||||
@@ -58,4 +71,8 @@ spec:
|
|||||||
{{- with .Values.routeAgent.affinity }}
|
{{- with .Values.routeAgent.affinity }}
|
||||||
affinity:
|
affinity:
|
||||||
{{ toYaml . | indent 8 }}
|
{{ toYaml . | indent 8 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
volumes:
|
||||||
|
- name: host-slash
|
||||||
|
hostPath:
|
||||||
|
path: /
|
||||||
|
|||||||
@@ -20,4 +20,28 @@ metadata:
|
|||||||
release: {{ .Release.Name | quote }}
|
release: {{ .Release.Name | quote }}
|
||||||
chart: {{ template "submariner.chart" . }}
|
chart: {{ template "submariner.chart" . }}
|
||||||
app: {{ template "submariner.name" . }}
|
app: {{ template "submariner.name" . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
---
|
||||||
|
{{- if .Values.serviceAccounts.globalnet.create }}
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.globalnetServiceAccountName" . }}
|
||||||
|
labels:
|
||||||
|
heritage: {{ .Release.Service | quote }}
|
||||||
|
release: {{ .Release.Name | quote }}
|
||||||
|
chart: {{ template "submariner.chart" . }}
|
||||||
|
app: {{ template "submariner.name" . }}
|
||||||
|
{{- end }}
|
||||||
|
---
|
||||||
|
{{- if .Values.serviceAccounts.lighthouse.create }}
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: {{ template "submariner.lighthouseServiceAccountName" . }}
|
||||||
|
labels:
|
||||||
|
heritage: {{ .Release.Service | quote }}
|
||||||
|
release: {{ .Release.Name | quote }}
|
||||||
|
chart: {{ template "submariner.chart" . }}
|
||||||
|
app: {{ template "submariner.name" . }}
|
||||||
|
{{- end }}
|
||||||
|
|||||||
+38
-13
@@ -1,11 +1,14 @@
|
|||||||
|
---
|
||||||
submariner:
|
submariner:
|
||||||
clusterId: ""
|
clusterId: ""
|
||||||
token: ""
|
token: ""
|
||||||
clusterCidr: "10.42.0.0/16"
|
clusterCidr: "10.42.0.0/16"
|
||||||
serviceCidr: "10.43.0.0/16"
|
serviceCidr: "10.43.0.0/16"
|
||||||
|
globalCidr: ""
|
||||||
natEnabled: false
|
natEnabled: false
|
||||||
colorCodes: blue
|
colorCodes: blue
|
||||||
debug: false
|
debug: false
|
||||||
|
serviceDiscovery: false
|
||||||
crd:
|
crd:
|
||||||
create: true
|
create: true
|
||||||
broker:
|
broker:
|
||||||
@@ -20,35 +23,57 @@ rbac:
|
|||||||
ipsec:
|
ipsec:
|
||||||
psk: ""
|
psk: ""
|
||||||
debug: false
|
debug: false
|
||||||
|
ikePort: 500
|
||||||
|
natPort: 4500
|
||||||
|
leadership:
|
||||||
|
leaseDuration: 10
|
||||||
|
renewDeadline: 5
|
||||||
|
retryPeriod: 2
|
||||||
engine:
|
engine:
|
||||||
image:
|
image:
|
||||||
repository: rancher/submariner
|
repository: quay.io/submariner/submariner
|
||||||
tag: v0.0.1
|
tag: ""
|
||||||
pullPolicy: Always
|
pullPolicy: IfNotPresent
|
||||||
resources: {}
|
resources: {}
|
||||||
# limits:
|
|
||||||
# cpu: 100m
|
|
||||||
# memory: 100Mi
|
|
||||||
nodeSelectorEnabled: true
|
nodeSelectorEnabled: true
|
||||||
nodeSelector: {}
|
nodeSelector: {}
|
||||||
tolerations: []
|
tolerations: []
|
||||||
affinity: {}
|
affinity: {}
|
||||||
routeAgent:
|
routeAgent:
|
||||||
image:
|
image:
|
||||||
repository: rancher/submariner-route-agent
|
repository: quay.io/submariner/submariner-route-agent
|
||||||
tag: v0.0.1
|
tag: ""
|
||||||
pullPolicy: Always
|
pullPolicy: IfNotPresent
|
||||||
resources: {}
|
resources: {}
|
||||||
# limits:
|
|
||||||
# cpu: 100m
|
|
||||||
# memory: 100Mi
|
|
||||||
nodeSelector: {}
|
nodeSelector: {}
|
||||||
tolerations: []
|
tolerations: []
|
||||||
affinity: {}
|
affinity: {}
|
||||||
|
globalnet:
|
||||||
|
image:
|
||||||
|
repository: quay.io/submariner/submariner-globalnet
|
||||||
|
tag: ""
|
||||||
|
pullPolicy: IfNotPresent
|
||||||
|
lighthouse:
|
||||||
|
image:
|
||||||
|
repository: quay.io/submariner/lighthouse-agent
|
||||||
|
tag: ""
|
||||||
|
pullPolicy: IfNotPresent
|
||||||
|
lighthouseCoredns:
|
||||||
|
name: ""
|
||||||
|
image:
|
||||||
|
repository: quay.io/submariner/lighthouse-coredns
|
||||||
|
tag: ""
|
||||||
|
pullPolicy: IfNotPresent
|
||||||
serviceAccounts:
|
serviceAccounts:
|
||||||
engine:
|
engine:
|
||||||
create: true
|
create: true
|
||||||
name: ""
|
name: ""
|
||||||
routeAgent:
|
routeAgent:
|
||||||
create: true
|
create: true
|
||||||
name: ""
|
name: ""
|
||||||
|
globalnet:
|
||||||
|
create: false
|
||||||
|
name: ""
|
||||||
|
lighthouse:
|
||||||
|
create: false
|
||||||
|
name: ""
|
||||||
|
|||||||
Reference in New Issue
Block a user