test: use personal docker registry

This commit is contained in:
Adrien Waksberg 2024-05-07 09:05:17 +02:00
parent 24a8f7b230
commit 9624b3d53e
3 changed files with 29 additions and 28 deletions

View file

@ -13,6 +13,7 @@ Which is based on [Keep A Changelog](http://keepachangelog.com/)
- keepalived_vrrp_scripts variable is now a hash
- keepalived_vrrp_instances variable is now a hash
- test: test: use personal docker registry
### Fixed

View file

@ -1,21 +1,21 @@
# Ansible role: Keepalived
[![Version](https://img.shields.io/badge/latest_version-1.1.0-green.svg)](https://git.yaegashi.fr/nishiki/ansible-role-keepalived/releases)
[![License](https://img.shields.io/badge/license-Apache--2.0-blue.svg)](https://git.yaegashi.fr/nishiki/ansible-role-keepalived/src/branch/master/LICENSE)
[![Version](https://img.shields.io/badge/latest_version-1.1.0-green.svg)](https://code.waks.be/nishiki/ansible-role-keepalived/releases)
[![License](https://img.shields.io/badge/license-Apache--2.0-blue.svg)](https://code.waks.be/nishiki/ansible-role-keepalived/src/branch/main/LICENSE)
Install and configure Keepalived
## Requirements
* Ansible >= 2.9
* Debian
* Bullseye
* Bookworm
- Ansible >= 2.9
- Debian
- Bullseye
- Bookworm
## Role variables
| Name | Type | Required |Default | Comment |
|-------------------------------|-------|----------|-----------------------|-----------------------------------|
| Name | Type | Required | Default | Comment |
| ----------------------------- | ----- | -------- | --------------------- | --------------------------------- |
| keepalived_mail_from | str | no | keepalived@test.local | from header for notification mail |
| keepalived_smtp_server | str | no | localhost | the smtp server |
| keepalived_notification_mails | array | no | | the mail addresses to notify |
@ -26,7 +26,7 @@ Install and configure Keepalived
### keepalived_vrrp_instances
| Name | Type | Required | Default | Comment |
|---------------------|-------|----------|---------|----------------------------------------------|
| ------------------- | ----- | -------- | ------- | -------------------------------------------- |
| key | str | yes | | the instance name |
| state | str | yes | | Initial state, MASTER or BACKUP |
| interface | str | yes | | interface for inside_network, bound by vrrp |
@ -62,14 +62,14 @@ vip_ngninx:
### keepalived_vrrp_scripts
| Name | Type | Required | Default | Comment |
|----------|-------|----------|---------|---------------------------------------|
| key | str | yes | | the script name |
| script | str | yes | | path of the script to execute |
| interval | int | no | 2 | seconds between script invocations |
| fall | int | no | 2 | number of successes for KO transition |
| rise | int | no | 2 | number of successes for OK transition |
| weight | int | no | 1 | weigth of script |
| Name | Type | Required | Default | Comment |
| -------- | ---- | -------- | ------- | ------------------------------------- |
| key | str | yes | | the script name |
| script | str | yes | | path of the script to execute |
| interval | int | no | 2 | seconds between script invocations |
| fall | int | no | 2 | number of successes for KO transition |
| rise | int | no | 2 | number of successes for OK transition |
| weight | int | no | 1 | weigth of script |
Example:
@ -83,11 +83,11 @@ check_nginx:
### keepalived_track_file
| Name | Type | Required | Default | Comment |
|----------|-------|----------|---------|---------------------------------------|
| key | str | yes | | the track file name |
| file | str | yes | | path of the file to track |
| weight | int | no | 1 | weigth of file |
| Name | Type | Required | Default | Comment |
| ------ | ---- | -------- | ------- | ------------------------- |
| key | str | yes | | the track file name |
| file | str | yes | | path of the file to track |
| weight | int | no | 1 | weigth of file |
Example:
@ -126,10 +126,10 @@ master_file:
### Test with molecule and docker
* install [docker](https://docs.docker.com/engine/installation/)
* install `python3` and `python3-pip`
* install molecule and dependencies `pip3 install molecule 'molecule[docker]' docker ansible-lint testinfra yamllint`
* run `molecule test`
- install [docker](https://docs.docker.com/engine/installation/)
- install `python3` and `python3-pip`
- install molecule and dependencies `pip3 install molecule 'molecule[docker]' docker ansible-lint testinfra yamllint`
- run `molecule test`
## License

View file

@ -3,7 +3,7 @@ driver:
name: docker
platforms:
- name: debian12
image: nishiki/debian12:molecule
image: code.waks.be/nishiki/molecule:debian12
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:rw
@ -12,7 +12,7 @@ platforms:
capabilities:
- SYS_ADMIN
- name: debian11
image: nishiki/debian11:molecule
image: code.waks.be/nishiki/molecule:debian11
privileged: true
volumes:
- /sys/fs/cgroup:/sys/fs/cgroup:rw