[docs] Fixed status badge #52
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
--- | |
name: Ansible OpenWISP InfluxDB CI Build | |
on: # yamllint disable-line rule:truthy | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
name: Build ${{ matrix.distro }} | |
runs-on: ubuntu-22.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# Below passwords are only meant for testing | |
- distro: ubuntu2404 | |
- distro: ubuntu2204 | |
influxdb_user_username: null | |
influxdb_user_password: null | |
- distro: ubuntu2004 | |
influxdb_user_username: "openwisp" | |
influxdb_user_password: "uo3ooPoeshoo1Fai6eil5goNg1ohVie" | |
- distro: debian12 | |
- distro: debian11 | |
influxdb_user_username: "openwisp" | |
influxdb_user_password: "uo3ooPoeshoo1Fai6eil5goNg1ohVie" | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.12 | |
- name: Install python dependencies | |
run: | | |
pip install molecule[docker,ansible] molecule-docker yamllint ansible-lint docker openwisp-utils[qa]~=1.0 | |
- name: Install Ansible Galaxy dependencies | |
run: ansible-galaxy collection install "community.general:>=3.6.0" | |
- name: QA checks | |
run: | | |
openwisp-qa-check --skip-isort --skip-flake8 --skip-checkmigrations --skip-black | |
- name: Tests | |
run: molecule test | |
env: | |
ROLE_NAME: ow_influxdb | |
PY_COLORS: '1' | |
ANSIBLE_FORCE_COLOR: '1' | |
MOLECULE_DISTRO: ${{ matrix.distro }} | |
INFLUXDB_USER_USERNAME: ${{ matrix.influxdb_user_username }} | |
INFLUXDB_USER_PASSWORD: ${{ matrix.influxdb_user_password }} | |
import: | |
name: Update imports on Ansible Galaxy | |
runs-on: ubuntu-20.04 | |
container: python:3-slim | |
needs: | |
- build | |
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }} | |
steps: | |
- name: Install ansible | |
run: pip install ansible | |
- name: Update imports on Ansible Galaxy | |
run: | | |
ansible-galaxy role import --api-key ${{ secrets.GALAXY_API_KEY }} --role-name influxdb openwisp ansible-ow-influxdb |