Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debugging cable driver matrix addition #1

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 8 additions & 13 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,19 @@ jobs:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
cable_driver: ['libreswan', 'wireguard']
globalnet: ['', 'globalnet']
steps:
- name: Check out the repository
uses: actions/checkout@v2

- name: Reclaim free space
run: |
sudo swapoff -a
sudo rm -f /swapfile
df -h
free -h

- name: Run E2E deployment and tests
run: |
make e2e
uses: submariner-io/shipyard/gh-actions/e2e@devel
with:
cabledriver: ${{ matrix.cable_driver }}
globalnet: ${{ matrix.globalnet }}

- name: Post mortem
if: failure()
run: |
df -h
free -h
make post-mortem
uses: submariner-io/shipyard/gh-actions/post-mortem@devel
16 changes: 12 additions & 4 deletions .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,17 @@ jobs:
with:
commits: ${{ steps.get-pr-commits.outputs.commits }}

gitlint:
name: Commit Message(s)
runs-on: ubuntu-latest
steps:
- name: Check out the repository
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Run gitlint
run: make gitlint

markdown-link-check:
name: Markdown Links (modified files)
runs-on: ubuntu-latest
Expand All @@ -40,10 +51,7 @@ jobs:
- 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"
run: make markdownlint

yaml-lint:
name: YAML
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ name: Release Charts
on:
push:
branches:
- master
- devel

jobs:
release:
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
.dapper
.idea
*.tgz
.shflags
*.tgz
9 changes: 9 additions & 0 deletions .gitlint
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[general]
# body-is-missing: Allow commit messages with only a title
# body-min-length: Allow short body lines, like "Relates-to: #issue"
ignore=body-is-missing,body-min-length

[ignore-by-body]
# Dependabot doesn't follow our conventions, unfortunately
regex=^Signed-off-by: dependabot\[bot\](.*)
ignore=all
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,8 @@ e2e: E2E_ARGS=cluster1 cluster2
preload-images:
source $(SCRIPTS_DIR)/lib/debug_functions; \
source $(SCRIPTS_DIR)/lib/deploy_funcs; \
source $(SCRIPTS_DIR)/lib/version; \
set -e; \
for image in submariner submariner-route-agent submariner-operator lighthouse-agent submariner-globalnet lighthouse-coredns; do \
for image in submariner-gateway submariner-route-agent submariner-operator lighthouse-agent submariner-globalnet lighthouse-coredns; do \
import_image quay.io/submariner/$${image}; \
done

Expand Down
157 changes: 156 additions & 1 deletion submariner-operator/crds/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ spec:
type: string
colorCodes:
type: string
engineDaemonSetStatus:
gatewayDaemonSetStatus:
properties:
lastResourceVersion:
type: string
Expand Down Expand Up @@ -720,3 +720,158 @@ status:
plural: ""
conditions: []
storedVersions: []
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.3.0
creationTimestamp: null
name: servicediscoveries.submariner.io
spec:
group: submariner.io
names:
kind: ServiceDiscovery
listKind: ServiceDiscoveryList
plural: servicediscoveries
singular: servicediscovery
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: ServiceDiscovery is the Schema for the servicediscoveries API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: ServiceDiscoverySpec defines the desired state of ServiceDiscovery
properties:
brokerK8sApiServer:
type: string
brokerK8sApiServerToken:
type: string
brokerK8sCA:
type: string
brokerK8sRemoteNamespace:
type: string
clusterID:
type: string
customDomains:
items:
type: string
type: array
x-kubernetes-list-type: set
debug:
type: boolean
globalnetEnabled:
type: boolean
imageOverrides:
additionalProperties:
type: string
type: object
namespace:
type: string
repository:
type: string
version:
type: string
required:
- brokerK8sApiServer
- brokerK8sApiServerToken
- brokerK8sCA
- brokerK8sRemoteNamespace
- clusterID
- debug
- namespace
type: object
status:
description: ServiceDiscoveryStatus defines the observed state of ServiceDiscovery
type: object
type: object
served: true
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.3.0
creationTimestamp: null
name: brokers.submariner.io
spec:
group: submariner.io
names:
kind: Broker
listKind: BrokerList
plural: brokers
singular: broker
scope: Namespaced
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: Broker is the Schema for the brokers API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: BrokerSpec defines the desired state of Broker
properties:
components:
items:
type: string
type: array
defaultCustomDomains:
items:
type: string
type: array
defaultGlobalnetClusterSize:
type: integer
globalnetCIDRRange:
type: string
globalnetEnabled:
type: boolean
type: object
status:
description: BrokerStatus defines the observed state of Broker
type: object
type: object
served: true
storage: true
subresources:
status: {}
status:
acceptedNames:
kind: ""
plural: ""
conditions: []
storedVersions: []
7 changes: 7 additions & 0 deletions submariner-operator/questions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,13 @@ questions:
label: "Service CIDR"
group: "CIDR Configuration"
required: true
- variable: submariner.globalCidr
default: ""
description: "Enter the globalnet CIDR (i.e. 169.254.1.0/24) for this cluster if using globalnet"
type: string
label: "Globalnet CIDR"
group: "CIDR Configuration"
required: false
- variable: submariner.natEnabled
type: boolean
default: false
Expand Down
2 changes: 1 addition & 1 deletion submariner-operator/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Submariner is now installed.

{{- if .Values.engine.nodeSelectorEnabled }}
{{- if .Values.gateway.nodeSelectorEnabled }}
If you haven't done so yet, please label a node as `submariner.io/gateway=true` to elect it for running Submariner.
{{- end }}

Expand Down
35 changes: 23 additions & 12 deletions submariner-operator/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ Create the name of the submariner-operator service account to use
{{- end -}}

{{/*
Create the name of the submariner-engine service account to use
Create the name of the submariner-gateway service account to use
*/}}
{{- define "submariner.engineServiceAccountName" -}}
{{- if .Values.serviceAccounts.engine.create -}}
{{ default (printf "%s-engine" (include "submariner.fullname" .)) .Values.serviceAccounts.engine.name }}
{{- define "submariner.gatewayServiceAccountName" -}}
{{- if .Values.serviceAccounts.gateway.create -}}
{{ default "submariner-gateway" .Values.serviceAccounts.gateway.name }}
{{- else -}}
{{ default "default" .Values.serviceAccounts.engine.name }}
{{ default "default" .Values.serviceAccounts.gateway.name }}
{{- end -}}
{{- end -}}

Expand All @@ -58,7 +58,7 @@ Create the name of the submariner-route-agent service account to use
*/}}
{{- define "submariner.routeAgentServiceAccountName" -}}
{{- if .Values.serviceAccounts.routeAgent.create -}}
{{ default (printf "%s-routeagent" (include "submariner.fullname" .)) .Values.serviceAccounts.routeAgent.name }}
{{ default "submariner-routeagent" .Values.serviceAccounts.routeAgent.name }}
{{- else -}}
{{ default "default" .Values.serviceAccounts.routeAgent.name }}
{{- end -}}
Expand All @@ -69,20 +69,31 @@ 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 }}
{{ default "submariner-globalnet" .Values.serviceAccounts.globalnet.name }}
{{- else -}}
{{ default "default" .Values.serviceAccounts.globalnet.name }}
{{- end -}}
{{- end -}}

{{/*
Create the name of the submariner-lighthouse service account to use
Create the name of the submariner-lighthouse-agent service account to use
*/}}
{{- define "submariner.lighthouseServiceAccountName" -}}
{{- if .Values.submariner.serviceDiscovery -}}
{{ default (printf "%s-lighthouse" (include "submariner.fullname" .)) .Values.serviceAccounts.lighthouse.name }}
{{- define "submariner.lighthouseAgentServiceAccountName" -}}
{{- if and (.Values.submariner.serviceDiscovery ) (.Values.serviceAccounts.lighthouseAgent.create) -}}
{{ default "submariner-lighthouse-agent" .Values.serviceAccounts.lighthouseAgent.name }}
{{- else -}}
{{ default "default" .Values.serviceAccounts.lighthouse.name }}
{{ default "default" .Values.serviceAccounts.lighthouseAgent.name }}
{{- end -}}
{{- end -}}

{{/*
Create the name of the submariner-lighthouse-coredns service account to use
*/}}
{{- define "submariner.lighthouseCoreDnsServiceAccountName" -}}
{{- if and (.Values.submariner.serviceDiscovery ) (.Values.serviceAccounts.lighthouseCoreDns.create) -}}
{{ default "submariner-lighthouse-coredns" .Values.serviceAccounts.lighthouseCoreDns.name }}
{{- else -}}
{{ default "default" .Values.serviceAccounts.lighthouseCoreDns.name }}
{{- end -}}
{{- end -}}

Expand Down
2 changes: 1 addition & 1 deletion submariner-operator/templates/operator-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ metadata:
release: {{ .Release.Name | quote }}
chart: {{ template "submariner.chart" . }}
app: {{ template "submariner.fullname" . }}
component: engine
component: gateway
name: {{ template "submariner.fullname" . }}
spec:
progressDeadlineSeconds: 600
Expand Down
Loading