Correctly fix aliases quoting logic (#206)

We were previously incorrectly adding double quotes for the alias values.
According to the man page it's not required. However, there is a requirement if
its a command being pipe.

In addition, the man page mentions this for the alias name:

  The  name  is  a  local  address (no domain part).  Use double quotes when the
  name contains any special characters such as whitespace, `#', `:', or `@'. The
  name is folded to lowercase, in order to make database lookups case
  insensitive.

This includes logic to support this automatically.

- Add new tests for aliases testing all types
- Convert all serverspec tests to inspec
- Add Github actions
- Update platforms to test

Signed-off-by: Lance Albertson <lance@osuosl.org>
This commit is contained in:
Lance Albertson
2025-01-29 14:51:57 -08:00
committed by GitHub
parent 6cb80c3be7
commit 1cd55ab40d
30 changed files with 224 additions and 250 deletions

60
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,60 @@
---
name: ci
"on":
pull_request:
push:
branches:
- main
jobs:
lint-unit:
uses: sous-chefs/.github/.github/workflows/lint-unit.yml@3.0.0
permissions:
actions: write
checks: write
pull-requests: write
statuses: write
integration:
needs: 'lint-unit'
runs-on: ubuntu-latest
strategy:
matrix:
os:
- almalinux-8
- almalinux-9
- amazonlinux-2023
- centos-stream-9
- debian-11
- debian-12
- opensuse-leap-15
- rockylinux-8
- rockylinux-9
- ubuntu-2004
- ubuntu-2204
- ubuntu-2404
suite:
- default
- aliases
- client
- server
- canonical
- sasl-auth-none
- sasl-auth-multiple
- sasl-auth-one
fail-fast: false
steps:
- name: Check out code
uses: actions/checkout@v4 # v4
- name: Install Chef
uses: actionshub/chef-install@2.0.4
- name: Dokken
uses: actionshub/test-kitchen@2.1.0
env:
CHEF_LICENSE: accept-no-persist
KITCHEN_LOCAL_YAML: kitchen.dokken.yml
with:
suite: ${{ matrix.suite }}
os: ${{ matrix.os }}