-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: temporary remove molecule tests the time to fix them
- Loading branch information
Showing
16 changed files
with
205 additions
and
183 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1 @@ | ||
templates/router.db | ||
templates/config | ||
*.swp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
--- | ||
stages: | ||
- checks | ||
- changes | ||
- push | ||
|
||
variables: | ||
GITHUB_USER: lotusnoir | ||
|
||
|
||
################################################## | ||
# SYNTAX CHECKS | ||
################################################## | ||
yamllint: | ||
stage: checks | ||
image: sdesbure/yamllint | ||
before_script: | ||
- yamllint --version | ||
script: | ||
- yamllint . | ||
|
||
ansible-lint: | ||
stage: checks | ||
image: lotusnoir/ansible_play | ||
script: | ||
- ansible-lint . | ||
|
||
|
||
###################################################### | ||
# GENERATE CHANGELOG FILE | ||
###################################################### | ||
changelog: | ||
stage: changes | ||
image: node:latest | ||
needs: | ||
- yamllint | ||
- ansible-lint | ||
artifacts: | ||
paths: | ||
- CHANGELOG.md | ||
expire_in: 1 day | ||
before_script: | ||
- npm install -g auto-changelog | ||
script: | ||
- auto-changelog -t keepachangelog --sort-commits date-desc --hide-empty-releases --hide-credit -l 10 -b 10 | ||
|
||
|
||
################################################## | ||
# PUSH CODE WHEN ALL TEST OK | ||
################################################## | ||
push_src_on_github: | ||
stage: push | ||
image: alpine:latest | ||
needs: | ||
- changelog | ||
before_script: | ||
- apk add git openssh-client | ||
- eval $(ssh-agent -s) | ||
- echo "${GITHUB_USER_PRIVATE_KEY}" | tr -d '\r' | ssh-add - | ||
- mkdir -p ~/.ssh | ||
- chmod 700 ~/.ssh | ||
- echo -e "Host *\n\tUser ansible\n\tStrictHostKeyChecking no\n\tForwardAgent yes\n\n" > ~/.ssh/config | ||
- git config --global user.email "${GITHUB_USER_EMAIL}" | ||
- git config --global user.name "${GITHUB_USER}" | ||
- git config --global init.defaultBranch main | ||
- COMMENT=$(git log -1 --pretty=%B | head -1) | ||
script: | ||
- git clone [email protected]:${GITHUB_USER}/ansible-apps_oxidized.git /tmp/ansible-apps_oxidized | ||
- rm -rf .git | ||
- cp -r . /tmp/ansible-apps_oxidized/ | ||
- cd /tmp/ansible-apps_oxidized | ||
- git add -A | ||
- git commit -m "${COMMENT}" || echo "No changes, nothing to commit!" | ||
- git push --follow-tags |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Changelog | ||
|
||
All notable changes to this project will be documented in this file. | ||
|
||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) | ||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,57 +1,36 @@ | ||
# Ansible Role: ansible-apps_oxidized | ||
# ansible-apps_oxidized | ||
|
||
## Description | ||
|
||
[![Build Status](https://travis-ci.com/lotusnoir/ansible-apps_oxidized.svg?branch=master?style=flat)](https://travis-ci.com/lotusnoir/ansible-apps_oxidized) | ||
[![License](https://img.shields.io/badge/license-Apache--2.0-brightgreen?style=flat)](https://opensource.org/licenses/Apache-2.0) | ||
[![Ansible Role](https://img.shields.io/badge/galaxy-apps_oxidized-purple?style=flat)](https://galaxy.ansible.com/lotusnoir/apps_oxidized) | ||
[![Galaxy Role](https://img.shields.io/badge/galaxy-apps_oxidized-purple?style=flat)](https://galaxy.ansible.com/lotusnoir/apps_oxidized) | ||
[![Version](https://img.shields.io/github/release/lotusnoir/ansible-apps_oxidized.svg)](https://github.com/lotusnoir/ansible-apps_oxidized/releases/latest) | ||
![GitHub repo size](https://img.shields.io/github/repo-size/lotusnoir/ansible-apps_oxidized?color=orange&style=flat) | ||
![Ansible Quality Score](https://img.shields.io/ansible/quality/52300) | ||
[![downloads](https://img.shields.io/ansible/role/d/52300)](https://galaxy.ansible.com/lotusnoir/apps_oxidized) | ||
[![Version](https://img.shields.io/github/release/lotusnoir/ansible-apps_oxidized.svg)](https://github.com/lotusnoir/ansible-apps_oxidized/releases/) | ||
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=lotusnoir_ansible-apps_oxidized&metric=alert_status)](https://sonarcloud.io/dashboard?id=lotusnoir_ansible-apps_oxidized) | ||
[![Maintainability Rating](https://sonarcloud.io/api/project_badges/measure?project=lotusnoir_ansible-apps_oxidized&metric=sqale_rating)](https://sonarcloud.io/dashboard?id=lotusnoir_ansible-apps_oxidized) | ||
[![Reliability Rating](https://sonarcloud.io/api/project_badges/measure?project=lotusnoir_ansible-apps_oxidized&metric=reliability_rating)](https://sonarcloud.io/dashboard?id=lotusnoir_ansible-apps_oxidized) | ||
[![Security Rating](https://sonarcloud.io/api/project_badges/measure?project=lotusnoir_ansible-apps_oxidized&metric=security_rating)](https://sonarcloud.io/dashboard?id=lotusnoir_ansible-apps_oxidized) | ||
![Ansible Quality Score](https://img.shields.io/ansible/quality/52300) | ||
[![License](https://img.shields.io/badge/license-Apache--2.0-brightgreen?style=flat)](https://opensource.org/licenses/Apache-2.0) | ||
|
||
Deploy [oxidized](https://github.com/ytti/oxidized) a network configuration backup tool. | ||
|
||
## Role variables | ||
## Requirements | ||
|
||
| Name | Default Value | Description | | ||
| ----------------------- | ----------------- | -----------------------------------| | ||
| `oxidized_version` | 0.28.0 | oxidized version | | ||
| `oxidized_user` | oxidized | oxidized system user | | ||
| `oxidized_group` | oxidized | oxidized system group | | ||
| `oxidized_passwd` | oxidized | oxidized system user password | | ||
| `oxidized_config_dir` | /home/oxidized | config directory | | ||
| `oxidized_storage_dir` | /data/oxidized | location for config files backup | | ||
| `oxidized_log_dir` | /var/log/oxidized | log file location | | ||
| `oxidized_log_debug` | false | debug mode | | ||
| `oxidized_web_listen` | 0.0.0.0 | web listen port | | ||
| `oxidized_web_port` | 8888 | web listen port | | ||
| `oxidized_config_files` | | location of the extra config files | | ||
| `oxidized_model_files` | | location of the model files | | ||
none | ||
|
||
## Examples | ||
## Role variables | ||
|
||
--- | ||
- hosts: apps_oxidized | ||
become: yes | ||
become_method: sudo | ||
gather_facts: yes | ||
roles: | ||
- role: ansible-apps_oxidized | ||
environment: | ||
http_proxy: "{{ http_proxy }}" | ||
https_proxy: "{{ https_proxy }}" | ||
no_proxy: "{{ no_proxy }} | ||
See [variables](/defaults/main.yml) for more details. | ||
|
||
## Monitoring | ||
## Examples | ||
|
||
Monitoring this tool can be done with a [prometheus exporter](https://github.com/lotusnoir/ansible-apps_oxidized_exporter). You will get the status for each backup. | ||
--- | ||
- hosts: apps_oxidized | ||
become: true | ||
become_method: sudo | ||
gather_facts: true | ||
roles: | ||
- role: ansible-apps_oxidized | ||
|
||
|
||
## License | ||
|
||
This project is licensed under Apache License. See [LICENSE](/LICENSE) for more details. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.