mirror of
https://github.com/mrlesmithjr/ansible-manage-lvm.git
synced 2026-09-04 22:48:17 +03:00
@@ -1,41 +1,41 @@
|
||||
---
|
||||
|
||||
# This is a basic workflow to help you get started with Actions
|
||||
|
||||
name: Molecule
|
||||
|
||||
# Controls when the action will run. Triggers the workflow on push or pull request
|
||||
# events but only for the master branch
|
||||
on:
|
||||
push:
|
||||
branches-ignore:
|
||||
- main
|
||||
- master
|
||||
pull_request:
|
||||
branches:
|
||||
- develop
|
||||
- main
|
||||
- master
|
||||
- tags/*
|
||||
|
||||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||
jobs:
|
||||
|
||||
lint:
|
||||
# The type of runner that the job will run on
|
||||
runs-on: ubuntu-latest
|
||||
runs-on: macos-10.15
|
||||
|
||||
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||
steps:
|
||||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: install lint prerequisite
|
||||
with:
|
||||
submodules: recursive
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: ~/.cache/pip
|
||||
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements*.txt') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-pip-
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt -y install python3-setuptools ansible-lint
|
||||
|
||||
- name: Install molecule
|
||||
run: |
|
||||
sudo apt update
|
||||
sudo apt -y install python3-setuptools python3 python3-pip docker vagrant
|
||||
sudo pip3 install wheel
|
||||
sudo pip3 install molecule testinfra yamllint ansible-lint flake8 molecule-vagrant
|
||||
|
||||
python -m pip install --upgrade pip
|
||||
pip install -r requirements.txt -r requirements-dev.txt
|
||||
- name: molecule lint
|
||||
run: |
|
||||
molecule lint
|
||||
|
||||
Reference in New Issue
Block a user