1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

pkgng: test with zsh not bash package

Had been using bash package, because it's not
likely to disappear from the package repository
any time soon. Turns out that bash is already
installed on the Ansible community.general
FreeBSD CI VM image, which makes the test fail.

Zsh probably isn't going away any time soon,
either, and likely won't be installed on the
CI image.
This commit is contained in:
Ross Williams 2021-10-07 19:01:39 +00:00
parent bfdaed0ce5
commit 867b7d5bee

View file

@ -7,34 +7,34 @@
##
## pkgng - example - install single package
##
- name: Verify bash binary is not present
- name: Verify zsh binary is not present
stat:
path: /usr/local/bin/bash
path: /usr/local/bin/zsh
get_attributes: no
get_checksum: no
get_mime: no
register: pkgng_example1_stat_before
- name: Install bash
- name: Install zsh
pkgng:
name: bash
name: zsh
register: pkgng_example1
- name: Remove bash (checkmode)
- name: Remove zsh (checkmode)
pkgng:
name: bash
name: zsh
state: absent
check_mode: yes
register: pkgng_example1_checkmode
- name: Install bash (idempotent)
- name: Install zsh (idempotent)
pkgng:
name: bash
name: zsh
register: pkgng_example1_idempotent
- name: Verify bash binary is present
- name: Verify zsh binary is present
stat:
path: /usr/local/bin/bash
path: /usr/local/bin/zsh
get_attributes: no
get_checksum: no
get_mime: no
@ -51,7 +51,7 @@
- pkgng_example1_stat_after.stat.executable
##
## pkgng - example - Install bash in jail
## pkgng - example - Install zsh in jail
##
- name: Test within jail
#
@ -63,37 +63,37 @@
- name: Setup testjail
include: setup-testjail.yml
- name: Verify bash binary is not present
- name: Verify zsh binary is not present
stat:
path: /usr/jails/testjail/usr/local/bin/bash
path: /usr/jails/testjail/usr/local/bin/zsh
get_attributes: no
get_checksum: no
get_mime: no
register: pkgng_example2_stat_before
- name: Install bash
- name: Install zsh
pkgng:
name: bash
name: zsh
jail: testjail
register: pkgng_example2
- name: Remove bash (checkmode)
- name: Remove zsh (checkmode)
pkgng:
name: bash
name: zsh
state: absent
jail: testjail
check_mode: yes
register: pkgng_example2_checkmode
- name: Install bash (idempotent)
- name: Install zsh (idempotent)
pkgng:
name: bash
name: zsh
jail: testjail
register: pkgng_example2_idempotent
- name: Verify bash binary is present
- name: Verify zsh binary is present
stat:
path: /usr/jails/testjail/usr/local/bin/bash
path: /usr/jails/testjail/usr/local/bin/zsh
get_attributes: no
get_checksum: no
get_mime: no