Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
824e44cceb | |||
f9177a912f | |||
![]() |
960cc9e72a | ||
![]() |
f5083595f0 | ||
![]() |
831f658f60 | ||
![]() |
8ce4376c87 | ||
![]() |
cc928916a5 | ||
![]() |
4249473328 |
8
.github/workflows/molecule.yml
vendored
8
.github/workflows/molecule.yml
vendored
@ -1,12 +1,10 @@
|
|||||||
---
|
---
|
||||||
name: Ansible Molecule
|
name: Ansible Molecule
|
||||||
|
on: # yamllint disable-line rule:truthy
|
||||||
on: # yamllint disable-line rule:truthy
|
|
||||||
push:
|
push:
|
||||||
tags_ignore:
|
tags_ignore:
|
||||||
- '*'
|
- '*'
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
setup:
|
setup:
|
||||||
name: Setup scenarios matrix
|
name: Setup scenarios matrix
|
||||||
@ -27,7 +25,6 @@ jobs:
|
|||||||
JSON="$JSON]"
|
JSON="$JSON]"
|
||||||
|
|
||||||
echo "::set-output name=scenarios::$(echo $JSON)"
|
echo "::set-output name=scenarios::$(echo $JSON)"
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
name: Lint
|
name: Lint
|
||||||
needs:
|
needs:
|
||||||
@ -42,7 +39,6 @@ jobs:
|
|||||||
uses: ansible/ansible-lint-action@main
|
uses: ansible/ansible-lint-action@main
|
||||||
with:
|
with:
|
||||||
path: "."
|
path: "."
|
||||||
|
|
||||||
test:
|
test:
|
||||||
name: Scenario "${{ matrix.scenario }}" on ${{ matrix.config.image }}:${{ matrix.config.tag }}
|
name: Scenario "${{ matrix.scenario }}" on ${{ matrix.config.image }}:${{ matrix.config.tag }}
|
||||||
needs:
|
needs:
|
||||||
@ -67,6 +63,8 @@ jobs:
|
|||||||
tag: "10"
|
tag: "10"
|
||||||
- image: "ubuntu"
|
- image: "ubuntu"
|
||||||
tag: "22.04"
|
tag: "22.04"
|
||||||
|
- image: ubuntu
|
||||||
|
tag: "24.04"
|
||||||
steps:
|
steps:
|
||||||
- name: checkout
|
- name: checkout
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
|
21
README.md
21
README.md
@ -1,24 +1,15 @@
|
|||||||
# Ansible role - motd
|
# Ansible role - motd
|
||||||
[](https://www.claranet.fr/)
|
|
||||||
[](LICENSE)
|
|
||||||
[](https://github.com/claranet/ansible-role-motd/releases)
|
|
||||||
[](https://github.com/claranet/ansible-role-motd/actions?query=workflow%3A%22Ansible+Molecule%22)
|
|
||||||
[](https://github.com/ansible/ansible)
|
|
||||||
[](https://galaxy.ansible.com/claranet/motd)
|
|
||||||
|
|
||||||
|
|
||||||
> :star: Star us on GitHub — it motivates us a lot!
|
|
||||||
|
|
||||||
Install and configure dynamic MOTD
|
Install and configure dynamic MOTD
|
||||||
|
|
||||||
This role uses [https://github.com/claranet/motd](https://github.com/claranet/motd) by default to get the MOTD
|
This role uses [https://gitea.tips-of-mine.com/Tips-Of-Mine/motd](https://gitea.tips-of-mine.com/Tips-Of-Mine/motd) by default to get the MOTD
|
||||||
|
|
||||||
```
|
```
|
||||||
System info:
|
System info:
|
||||||
Hostname·········: claranet_motd_ubuntu-20.04
|
Hostname·········: tips-of-mine_motd_ubuntu-20.04
|
||||||
Distro···········: Ubuntu 20.04.3 LTS
|
Distro···········: Ubuntu 20.04.3 LTS
|
||||||
Kernel···········: Linux 5.10.47-linuxkit
|
Kernel···········: Linux 5.10.47-linuxkit
|
||||||
Uptime···········: up 2 days, 23 hours, 18 minutes
|
Uptime···········: up 12 days, 23 hours, 18 minutes
|
||||||
Load·············: 1.33 (1m), 0.43 (5m), 0.20 (15m)
|
Load·············: 1.33 (1m), 0.43 (5m), 0.20 (15m)
|
||||||
Processes········: 13 (root), 3 (user), 16 (total)
|
Processes········: 13 (root), 3 (user), 16 (total)
|
||||||
CPU··············: Intel(R) Core(TM) i7-8569U CPU @ 2.80GHz (4 vCPU)
|
CPU··············: Intel(R) Core(TM) i7-8569U CPU @ 2.80GHz (4 vCPU)
|
||||||
@ -40,7 +31,7 @@ Ansible >= 2.10
|
|||||||
## :zap: Installation
|
## :zap: Installation
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
ansible-galaxy install claranet.motd
|
ansible-galaxy install tips-of-mine.motd
|
||||||
```
|
```
|
||||||
|
|
||||||
## :gear: Role variables
|
## :gear: Role variables
|
||||||
@ -48,7 +39,7 @@ ansible-galaxy install claranet.motd
|
|||||||
Variable | Default value | Description
|
Variable | Default value | Description
|
||||||
-----------------------------|------------------------------------------------------------------------|----------------------------------------------------------------
|
-----------------------------|------------------------------------------------------------------------|----------------------------------------------------------------
|
||||||
motd_disable_default_motd | true | Disable system default MOTD (/etc/motd)
|
motd_disable_default_motd | true | Disable system default MOTD (/etc/motd)
|
||||||
motd_template | https://raw.githubusercontent.com/claranet/motd/master/scripts/00-basic| Dynmaic MOTD template<br>Can be a URL or a local template
|
motd_template | https://gitea.tips-of-mine.com/Tips-Of-Mine/motd/scripts/00-basic | Dynmaic MOTD template<br>Can be a URL or a local template
|
||||||
motd_template_prepend | "" | Prepend raw content to `motd_template`
|
motd_template_prepend | "" | Prepend raw content to `motd_template`
|
||||||
motd_template_append | See [defaults/main.yml](defaults/main.yml) | Append raw content to `motd_template`
|
motd_template_append | See [defaults/main.yml](defaults/main.yml) | Append raw content to `motd_template`
|
||||||
motd_template_username | "" | Used when `motd_template` is an URL
|
motd_template_username | "" | Used when `motd_template` is an URL
|
||||||
@ -60,7 +51,7 @@ motd_template_password | ""
|
|||||||
---
|
---
|
||||||
- hosts: all
|
- hosts: all
|
||||||
roles:
|
roles:
|
||||||
- role: claranet.motd
|
- role: tips-of-mine.motd
|
||||||
motd_template: "{{ playbook_dir }}/templates/dynmotd.j2"
|
motd_template: "{{ playbook_dir }}/templates/dynmotd.j2"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
---
|
---
|
||||||
motd_disable_default_motd: true
|
motd_disable_default_motd: true
|
||||||
motd_template: https://raw.githubusercontent.com/claranet/motd/master/scripts/00-basic
|
motd_template: https://gitea.tips-of-mine.com/Tips-Of-Mine/motd/master/scripts/00-basic
|
||||||
motd_template_prepend: ""
|
motd_template_prepend: ""
|
||||||
motd_template_append: |
|
motd_template_append: |
|
||||||
|
|
||||||
|
@ -27,6 +27,9 @@ provisioner:
|
|||||||
name: ansible
|
name: ansible
|
||||||
env:
|
env:
|
||||||
ANSIBLE_FORCE_COLOR: "true"
|
ANSIBLE_FORCE_COLOR: "true"
|
||||||
|
ANSIBLE_LOAD_CALLBACK_PLUGINS: "true"
|
||||||
|
ANSIBLE_STDOUT_CALLBACK: "ansible.posix.debug"
|
||||||
|
ANSIBLE_CALLBACKS_ENABLED: "ansible.posix.profile_tasks"
|
||||||
options:
|
options:
|
||||||
v: true
|
v: true
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user