From 307ef02867b6e53e7032fb569ad7de2cb7cc7207 Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:15:03 -0800 Subject: [PATCH 1/8] Moved the neo4j running check to verify.yml --- molecule/default/converge.yml | 9 --------- molecule/default/verify.yml | 10 ++++++++++ 2 files changed, 10 insertions(+), 9 deletions(-) create mode 100644 molecule/default/verify.yml diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml index ecd9c7d..521d671 100644 --- a/molecule/default/converge.yml +++ b/molecule/default/converge.yml @@ -9,12 +9,3 @@ roles: - role: ansible-role-neo4j - - post_tasks: - - name: Give the Neo4j time to start - pause: seconds=30 - - - name: Verify that Neo4j is running on port 7474 - uri: - url: http://127.0.0.1:7474/ - status_code: 200 diff --git a/molecule/default/verify.yml b/molecule/default/verify.yml new file mode 100644 index 0000000..a50df00 --- /dev/null +++ b/molecule/default/verify.yml @@ -0,0 +1,10 @@ +--- +- name: Verify + hosts: all + become: true + + tasks: + - name: Verify that Neo4j is running on port 7474 + uri: + url: http://127.0.0.1:7474/ + status_code: 200 From a070326bb126deeaaaafefb2aa1b07b8526c131c Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:15:27 -0800 Subject: [PATCH 2/8] Updated molecule config --- molecule/default/molecule.yml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml index 9b09dd7..d35ee6a 100644 --- a/molecule/default/molecule.yml +++ b/molecule/default/molecule.yml @@ -24,11 +24,10 @@ platforms: pre_build_image: true provisioner: name: ansible - lint: - name: ansible-lint + log: false + options: + vvv: false scenario: name: default verifier: - name: testinfra - lint: - name: flake8 + name: ansible From acd36df1cd73149c62bcb7a073cd57f10b6413ae Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:51:07 -0800 Subject: [PATCH 3/8] Added ansible-lint config --- molecule/ansible-lint.yml | 5 +++++ molecule/default/molecule.yml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 molecule/ansible-lint.yml diff --git a/molecule/ansible-lint.yml b/molecule/ansible-lint.yml new file mode 100644 index 0000000..8094e2a --- /dev/null +++ b/molecule/ansible-lint.yml @@ -0,0 +1,5 @@ +--- +warn_list: + - internal-error +skip_list: + - yaml diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml index d35ee6a..c520c6e 100644 --- a/molecule/default/molecule.yml +++ b/molecule/default/molecule.yml @@ -6,7 +6,7 @@ driver: lint: | set -e yamllint -c molecule/yaml-lint.yml . - ansible-lint + ansible-lint -c molecule/ansible-lint.yml . flake8 platforms: - name: instance From 64506d478aa40a712bcec607570b2447fcc9432d Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:51:57 -0800 Subject: [PATCH 4/8] Run actions on pull_request, check ubuntu2004 and install molecule-docker --- .github/workflows/molecule-test.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/molecule-test.yml b/.github/workflows/molecule-test.yml index ece80bf..c38e65e 100644 --- a/.github/workflows/molecule-test.yml +++ b/.github/workflows/molecule-test.yml @@ -1,6 +1,6 @@ --- name: Molecule Test -on: [push] +on: [push, pull_request] jobs: build: runs-on: ubuntu-latest @@ -8,7 +8,7 @@ jobs: fail-fast: false max-parallel: 4 matrix: - molecule_distro: ['centos7', 'centos8', 'ubuntu1804'] + molecule_distro: ['centos7', 'centos8', 'ubuntu1804', 'ubuntu2004'] env: ANSIBLE_CALLBACK_WHITELIST: profile_tasks @@ -21,7 +21,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install ansible-lint==4.3.7 flake8 molecule docker + pip install ansible-lint flake8 molecule molecule-docker docker - name: Test with molecule run: | molecule test --all From e0b24c774953bdc88c8e96351a26c7ef3112e000 Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:56:25 -0800 Subject: [PATCH 5/8] Added support for Ubuntu 20.04 --- README.md | 2 +- meta/main.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b10d438..dcd9096 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ ansible-role-neo4j ![](https://github.com/kevincoakley/ansible-role-neo4j/workflows/Molecule%20Test/badge.svg) -Install Neo4j - https://www.neo4j.com . Tested with Neo4j 4.0.3 on CentOS 7, CentOS 8 and Ubuntu 18.04. +Install Neo4j - https://www.neo4j.com . Tested with Neo4j 4.2.3 on CentOS 7, CentOS 8, Ubuntu 18.04 and Ubuntu 20.04. Requirements ------------ diff --git a/meta/main.yml b/meta/main.yml index 8648db1..4e40783 100644 --- a/meta/main.yml +++ b/meta/main.yml @@ -28,6 +28,7 @@ galaxy_info: - name: Ubuntu versions: - bionic + - focal galaxy_tags: - database From 182d20bac4ea805f06cc2d889efff539409aaa8b Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 10:56:37 -0800 Subject: [PATCH 6/8] Install ansible --- .github/workflows/molecule-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/molecule-test.yml b/.github/workflows/molecule-test.yml index c38e65e..cf95c06 100644 --- a/.github/workflows/molecule-test.yml +++ b/.github/workflows/molecule-test.yml @@ -21,7 +21,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install ansible-lint flake8 molecule molecule-docker docker + pip install ansible ansible-lint flake8 molecule molecule-docker docker - name: Test with molecule run: | molecule test --all From d32f9b1d940d9a2ee441a196366a41a972e02f85 Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 11:04:49 -0800 Subject: [PATCH 7/8] Print installed python modules versions numbers --- .github/workflows/molecule-test.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/molecule-test.yml b/.github/workflows/molecule-test.yml index cf95c06..6833d55 100644 --- a/.github/workflows/molecule-test.yml +++ b/.github/workflows/molecule-test.yml @@ -22,6 +22,9 @@ jobs: run: | python -m pip install --upgrade pip pip install ansible ansible-lint flake8 molecule molecule-docker docker + ansible --version + ansible-lint --version + molecule --version - name: Test with molecule run: | molecule test --all From 5e74cc7a64b67f94643360bf396213d331f0971d Mon Sep 17 00:00:00 2001 From: Kevin Coakley Date: Wed, 10 Mar 2021 12:40:53 -0800 Subject: [PATCH 8/8] Added namespace --- meta/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/meta/main.yml b/meta/main.yml index 4e40783..1708966 100644 --- a/meta/main.yml +++ b/meta/main.yml @@ -1,6 +1,7 @@ --- galaxy_info: role_name: neo4j + namespace: kevincoakley author: Kevin Coakley description: Install Neo4j (http://neo4j.com/) license: BSD