Fix lint errors
Some checks reported errors
continuous-integration/drone/push Build encountered an error

This commit is contained in:
Adrien Reslinger 2022-07-23 01:24:37 +02:00
parent 69706cd20e
commit e10bb28442
Signed by: adrien
GPG key ID: DA7B27055C66D6DE
3 changed files with 73 additions and 73 deletions

View file

@ -1,12 +1,12 @@
my_context: kubernetes
ingress_domain: "local.cluster"
#ingress_whitelist:
# - 10.96.0.0/12
# - 10.244.0.0/16
# - 192.168.140.0/24
# ingress_whitelist:
# - 10.96.0.0/12
# - 10.244.0.0/16
# - 192.168.140.0/24
basic_auth: false
#traefik_version: "2.0"
#traefik_namespace: traefik
# traefik_version: "2.0"
# traefik_namespace: traefik
weave_net_password: "SuperMotDePasseDeLaMortQuiTue4012!"
weave_scope: false

View file

@ -6,6 +6,6 @@ galaxy_info:
galaxy_tags: []
license: GPL2
platforms:
- name: kubernetes
version:
- all
- name: kubernetes
version:
- all

View file

@ -2,9 +2,9 @@
- name: Weave Net setup
block:
- name: Include Weave Net vars
include_vars: net-files.yaml
ansible.builtin.include_vars: net-files.yaml
- name: Weave Net files
k8s:
kubernetes.core.k8s:
state: present
context: "{{ my_context }}"
merge_type: merge
@ -12,7 +12,7 @@
with_items:
- "{{ weave_net_files }}"
- name: Weave Net password
k8s:
kubernetes.core.k8s:
state: present
context: "{{ my_context }}"
merge_type: merge
@ -28,72 +28,72 @@
- name: Weave Scope setup
block:
- name: namespace
k8s:
context: "{{ my_context }}"
state: present
name: weave
api_version: v1
kind: Namespace
- name: namespace
kubernetes.core.k8s:
context: "{{ my_context }}"
state: present
name: weave
api_version: v1
kind: Namespace
- name: Create a Secret object for basic authentification (traefik 1.7)
k8s:
state: present
context: "{{ my_context }}"
definition:
apiVersion: v1
kind: Secret
metadata:
name: basic-auth
namespace: weave
type: Opaque
data:
basic_auth: "{{ basic_auth_data | b64encode }}"
when:
- basic_auth|bool
- traefik_version is not defined or traefik_version | regex_search('(^1.)')
- name: Create a Secret object for basic authentification (traefik 1.7)
kubernetes.core.k8s:
state: present
context: "{{ my_context }}"
definition:
apiVersion: v1
kind: Secret
metadata:
name: basic-auth
namespace: weave
type: Opaque
data:
basic_auth: "{{ basic_auth_data | b64encode }}"
when:
- basic_auth|bool
- traefik_version is not defined or traefik_version | regex_search('(^1.)')
- name: Remove a Secret object for basic authentification (traefik 1.7)
k8s:
state: absent
context: "{{ my_context }}"
definition:
apiVersion: v1
kind: Secret
metadata:
name: basic-auth
namespace: weave
type: Opaque
data:
basic_auth: "{{ basic_auth_data | b64encode }}"
when:
- traefik_version is defined
- traefik_version | regex_search('(^2.)')
- name: Remove a Secret object for basic authentification (traefik 1.7)
kubernetes.core.k8s:
state: absent
context: "{{ my_context }}"
definition:
apiVersion: v1
kind: Secret
metadata:
name: basic-auth
namespace: weave
type: Opaque
data:
basic_auth: "{{ basic_auth_data | b64encode }}"
when:
- traefik_version is defined
- traefik_version | regex_search('(^2.)')
- name: Remove old existing Ingress object
k8s:
context: "{{ my_context }}"
state: absent
api_version: extensions/v1beta1
kind: Ingress
namespace: weave
name: weave
when:
- traefik_version is defined
- traefik_version | regex_search('(^2.)')
- name: Remove old existing Ingress object
kubernetes.core.k8s:
context: "{{ my_context }}"
state: absent
api_version: extensions/v1beta1
kind: Ingress
namespace: weave
name: weave
when:
- traefik_version is defined
- traefik_version | regex_search('(^2.)')
# file found https://github.com/weaveworks/scope/tree/master/examples/k8s/
- name: Weave Scope files
k8s:
state: "present"
context: "{{ my_context }}"
namespace: 'weave'
merge_type: merge
definition: "{{ item }}"
with_items: "{{ lookup('url', 'https://cloud.weave.works/k8s/' + weave_scope_version + '/scope.yaml', split_lines=False) | from_yaml_all | list }}"
when:
- weave_scope|bool
- item is not none
- name: Weave Scope files
kubernetes.core.k8s:
state: "present"
context: "{{ my_context }}"
namespace: 'weave'
merge_type: merge
definition: "{{ item }}"
with_items: "{{ lookup('url', 'https://cloud.weave.works/k8s/' + weave_scope_version + '/scope.yaml', split_lines=False) | from_yaml_all | list }}"
when:
- weave_scope|bool
- item is not none
tags:
- weave
- weave-scope