3 Commits

Author SHA1 Message Date
1c19708855 Increase default retries;Add healthcheck
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-23 16:51:17 +01:00
942c13dde7 Improve console healthchecks
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-23 11:42:34 +01:00
439223c56e Build n-1 version
All checks were successful
continuous-integration/drone/push Build is passing
2023-03-22 08:54:45 +01:00
5 changed files with 35 additions and 11 deletions

View File

@@ -99,7 +99,7 @@
--kubeconfig {{ kubeconfig.path }} --kubeconfig {{ kubeconfig.path }}
chdir: /opt/metacluster/cluster-api chdir: /opt/metacluster/cluster-api
- name: Ensure CAPI/CAPV controller availability - name: Ensure controller availability
kubernetes.core.k8s_info: kubernetes.core.k8s_info:
kind: Deployment kind: Deployment
name: "{{ item.name }}" name: "{{ item.name }}"
@@ -107,6 +107,8 @@
wait: true wait: true
kubeconfig: "{{ kubeconfig.path }}" kubeconfig: "{{ kubeconfig.path }}"
loop: loop:
- name: caip-in-cluster-controller-manager
namespace: caip-in-cluster-system
- name: capi-controller-manager - name: capi-controller-manager
namespace: capi-system namespace: capi-system
- name: capv-controller-manager - name: capv-controller-manager

View File

@@ -19,6 +19,25 @@
executable: /opt/firstboot/tty.sh executable: /opt/firstboot/tty.sh
workingdir: /tmp/ workingdir: /tmp/
metacluster: metacluster:
components:
- name: ArgoCD
url: https://gitops.${FQDN}
healthcheck: https://gitops.${FQDN}
- name: Gitea
url: https://git.${FQDN}
healthcheck: https://git.${FQDN}
- name: Harbor
url: https://registry.${FQDN}
healthcheck: https://registry.${FQDN}
- name: Longhorn
url: https://storage.${FQDN}
healthcheck: https://storage.${FQDN}
- name: StepCA
url: ''
healthcheck: https://ca.${FQDN}/health
- name: Traefik
url: https://ingress.${FQDN}
healthcheck: https://ingress.${FQDN}
fqdn: "{{ vapp['metacluster.fqdn'] }}" fqdn: "{{ vapp['metacluster.fqdn'] }}"
vip: "{{ vapp['metacluster.vip'] }}" vip: "{{ vapp['metacluster.vip'] }}"
loop: loop:

View File

@@ -12,11 +12,14 @@ DFLT='\033[0m' # Reset colour
LCLR='\033[K' # Clear to end of line LCLR='\033[K' # Clear to end of line
PRST='\033[0;0H' # Reset cursor position PRST='\033[0;0H' # Reset cursor position
# COMPONENTS=('ca' 'ingress' 'storage' 'registry' 'git' 'gitops')
COMPONENTS=('storage' 'registry' 'git' 'gitops')
FQDN='{{ _template.metacluster.fqdn }}' FQDN='{{ _template.metacluster.fqdn }}'
IPADDRESS='{{ _template.metacluster.vip }}' IPADDRESS='{{ _template.metacluster.vip }}'
declare -A COMPONENTS
{% for component in _template.metacluster.components %}
COMPONENTS["{{ component.name }}\t({{ component.url }})"]="{{ component.healthcheck }}"
{% endfor %}
I=0 I=0
while /bin/true; do while /bin/true; do
@@ -30,13 +33,13 @@ while /bin/true; do
echo -e "${PRST}" > /dev/tty1 echo -e "${PRST}" > /dev/tty1
echo -e "\n\n\t${DFLT}To manage this appliance, please connect to one of the following:${LCLR}\n" > /dev/tty1 echo -e "\n\n\t${DFLT}To manage this appliance, please connect to one of the following:${LCLR}\n" > /dev/tty1
for c in "${COMPONENTS[@]}"; do for c in "${!COMPONENTS[@]}"; do
STATUS=$(curl -ks "https://${c}.${FQDN}" -o /dev/null -w '%{http_code}') STATUS=$(curl -kLs "${COMPONENTS[${c}]}" -o /dev/null -w '%{http_code}')
if [[ "${STATUS}" -eq "200" ]]; then if [[ "${STATUS}" -eq "200" ]]; then
echo -e "\t [${BGRN}+${DFLT}] ${BBLU}https://${c}.${FQDN}${DFLT}${LCLR}" > /dev/tty1 echo -e "\t [${BGRN}+${DFLT}] ${BBLU}${c}${DFLT}${LCLR}" > /dev/tty1
else else
echo -e "\t [${BRED}-${DFLT}] ${BBLU}https://${c}.${FQDN}${DFLT}${LCLR}" > /dev/tty1 echo -e "\t [${BRED}-${DFLT}] ${BBLU}${c}${DFLT}${LCLR}" > /dev/tty1
fi fi
done done

View File

@@ -1,5 +1,5 @@
playbook: playbook:
retries: 5 retries: 10
delay: delay:
# These values are multiplied with the value of `storage_benchmark` # These values are multiplied with the value of `storage_benchmark`
long: 2 long: 2

View File

@@ -1,7 +1,7 @@
platform: platform:
k3s: k3s:
version: v1.26.2+k3s1 version: v1.25.7+k3s1
gitops: gitops:
repository: repository:
@@ -93,9 +93,9 @@ components:
workload: workload:
version: version:
calico: v3.25.0 calico: v3.25.0
k8s: v1.26.3 k8s: v1.25.8
node_template: node_template:
url: https://{{ repo_username }}:{{ repo_password }}@sn.itch.fyi/Repository/rel/ubuntu-2004-kube-v1.26.3.ova url: https://{{ repo_username }}:{{ repo_password }}@sn.itch.fyi/Repository/rel/ubuntu-2004-kube-v1.25.8.ova
dex: dex:
helm: helm: