Skip to content

Commit 351f785

Browse files
author
supertarto
committed
Drop TravisCI and use GA
1 parent eb29224 commit 351f785

File tree

4 files changed

+68
-30
lines changed

4 files changed

+68
-30
lines changed

.github/workflows/main.yml

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
---
2+
name: CI
3+
'on':
4+
pull_request:
5+
push:
6+
branches:
7+
- master
8+
schedule:
9+
- cron: "0 5 * * 0"
10+
11+
defaults:
12+
run:
13+
working-directory: 'supertarto.mongodb'
14+
15+
jobs:
16+
17+
lint:
18+
name: Lint
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Check out the codebase.
22+
uses: actions/checkout@v2
23+
with:
24+
path: 'supertarto.mongodb'
25+
26+
- name: Set up Python 3.
27+
uses: actions/setup-python@v2
28+
with:
29+
python-version: '3.x'
30+
31+
- name: Install test dependencies.
32+
run: pip3 install yamllint ansible-lint
33+
34+
- name: Lint code.
35+
run: |
36+
yamllint .
37+
ansible-lint
38+
molecule:
39+
name: Molecule
40+
runs-on: ubuntu-latest
41+
strategy:
42+
matrix:
43+
distrib:
44+
- debian10:latest
45+
46+
steps:
47+
- name: Check out the codebase.
48+
uses: actions/checkout@v2
49+
with:
50+
path: 'supertarto.mongodb'
51+
52+
- name: Set up Python 3.
53+
uses: actions/setup-python@v2
54+
with:
55+
python-version: '3.x'
56+
57+
- name: Install test dependencies.
58+
run: pip3 install ansible molecule[docker] docker
59+
60+
- name: Run Molecule tests.
61+
run: molecule test
62+
env:
63+
PY_COLORS: '1'
64+
ANSIBLE_FORCE_COLOR: '1'
65+
MOLECULE_DISTRIB: ${{ matrix.distrib }}

.travis.yml

-26
This file was deleted.

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Ansible MongoDB
2-
[![Build Status](https://travis-ci.com/supertarto/ansible-mongodb.svg?branch=master)](https://travis-ci.com/supertarto/ansible-mongodb)
2+
[![CI](https://github.com/supertarto/ansible-mongodb/workflows/CI/badge.svg?event=push)](https://github.com/supertarto/ansible-mongodb/actions?query=workflow%3ACI)
33

44
Install and configure mongodb with Ansible. This role is designed for my small need, it can be improved and don't use everything Mongodb can propose. Tested only with Debian 10 and mongodb 4.2.
55

molecule/default/molecule.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@ dependency:
33
name: galaxy
44
driver:
55
name: docker
6-
lint: |
7-
yamllint .
8-
ansible-lint
96
platforms:
107
- name: instance
118
image: "thetarto/ansible-${MOLECULE_DISTRIB}"
@@ -16,3 +13,5 @@ platforms:
1613
pre_build_image: true
1714
provisioner:
1815
name: ansible
16+
playbooks:
17+
converge: ${MOLECULE_PLAYBOOK:-converge.yml}

0 commit comments

Comments
 (0)