diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a3b6452..d4f6d3a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,15 +10,21 @@ name: ci jobs: lint-unit: uses: sous-chefs/.github/.github/workflows/lint-unit.yml@2.0.6 + permissions: + actions: write + checks: write + pull-requests: write + statuses: write + issues: write integration: - needs: lint-unit + needs: "lint-unit" runs-on: ubuntu-latest strategy: matrix: os: - "almalinux-8" - - "amazonlinux-2" + - "amazonlinux-2023" - "centos-7" - "centos-stream-8" - "debian-10" diff --git a/.github/workflows/md-links.yml b/.github/workflows/md-links.yml deleted file mode 100644 index fb76314..0000000 --- a/.github/workflows/md-links.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -name: md-links - -"on": - pull_request: - push: - branches: [main] - -jobs: - md-links: - runs-on: ubuntu-latest - steps: - - name: Check out code - uses: actions/checkout@v4 - - name: markdown-link-check - uses: gaurav-nelson/github-action-markdown-link-check@1.0.15 - with: - use-verbose-mode: "yes" - folder-path: "documentation" diff --git a/CHANGELOG.md b/CHANGELOG.md index 31ca9aa..6514348 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -176,17 +176,17 @@ Locking yum dependency to '< 3' ### Bug -- **[COOK-3317](https://tickets.chef.io/browse/COOK-3317)** - Fix and make `server.up.sh` useful and customizable +- [COOK-3317] - Fix and make `server.up.sh` useful and customizable ### New Feature -- **[COOK-3315](https://tickets.chef.io/browse/COOK-3315)** - Remove hardcoded variables in configuration file +- [COOK-3315] - Remove hardcoded variables in configuration file ## v1.1.2 ### Improvement -- **[COOK-2820](https://tickets.chef.io/browse/COOK-2820)** - Update metadata.rb for all attributes and recipes +- [COOK-2820] - Update metadata.rb for all attributes and recipes ## v1.1.0 diff --git a/Dangerfile b/Dangerfile deleted file mode 100644 index bc08b7a..0000000 --- a/Dangerfile +++ /dev/null @@ -1,47 +0,0 @@ -# Reference: http://danger.systems/reference.html - -# A pull request summary is required. Add a description of the pull request purpose. -# Changelog must be updated for each pull request that changes code. -# Warnings will be issued for: -# Pull request with more than 400 lines of code changed -# Pull reqest that change more than 5 lines without test changes -# Failures will be issued for: -# Pull request without summary -# Pull requests with code changes without changelog entry - -def code_changes? - code = %w(libraries attributes recipes resources files templates) - code.each do |location| - return true unless git.modified_files.grep(/#{location}/).empty? - end - false -end - -def test_changes? - tests = %w(spec test kitchen.yml kitchen.dokken.yml) - tests.each do |location| - return true unless git.modified_files.grep(/#{location}/).empty? - end - false -end - -failure 'Please provide a summary of your Pull Request.' if github.pr_body.length < 10 - -warn 'This is a big Pull Request.' if git.lines_of_code > 400 - -warn 'This is a Table Flip.' if git.lines_of_code > 2000 - -# Require a CHANGELOG entry for non-test changes. -if !git.modified_files.include?('CHANGELOG.md') && code_changes? - failure 'Please include a CHANGELOG entry.' -end - -# Require Major Minor Patch version labels -unless github.pr_labels.grep /minor|major|patch/i - warn 'Please add a release label to this pull request' -end - -# A sanity check for tests. -if git.lines_of_code > 5 && code_changes? && !test_changes? - warn 'This Pull Request is probably missing tests.' -end diff --git a/kitchen.yml b/kitchen.yml index 71f22b4..20d1f7d 100644 --- a/kitchen.yml +++ b/kitchen.yml @@ -1,78 +1,29 @@ ---- driver: - name: dokken - privileged: true # because Docker and SystemD/Upstart - chef_version: <%= ENV['CHEF_VERSION'] || 'current' %> - -transport: - name: dokken - require_chef_omnibus: <%= ENV['CHEF_VERSION'] || 'latest' %> + name: vagrant provisioner: - name: dokken + name: chef_infra enforce_idempotency: true multiple_converge: 2 deprecations_as_errors: true - chef_log_level: <%= ENV['CHEF_LOG_LEVEL'] || 'auto' %> chef_license: accept-no-persist enforce_idempotency: true multiple_converge: 2 verifier: name: inspec - deprecations_as_errors: true -# currently only support 2 last major revs of distros (at the most) platforms: - - name: almalinux-8 - driver: - image: dokken/almalinux-8 - pid_one_command: /usr/lib/systemd/systemd - - name: amazonlinux-2 - driver: - image: dokken/amazonlinux-2 - pid_one_command: /usr/lib/systemd/systemd - - - name: debian-10 - driver: - image: dokken/debian-10 - pid_one_command: /bin/systemd - - - name: debian-11 - driver: - image: dokken/debian-11 - pid_one_command: /bin/systemd - - name: centos-7 - driver: - image: dokken/centos-7 - pid_one_command: /usr/lib/systemd/systemd - - name: centos-stream-8 - driver: - image: dokken/centos-stream-8 - pid_one_command: /usr/lib/systemd/systemd - + - name: debian-10 + - name: debian-10 + - name: freebsd-12 - name: fedora-latest - driver: - image: dokken/fedora-latest - pid_one_command: /usr/lib/systemd/systemd - + - name: opensuse-leap-15 - name: ubuntu-18.04 - driver: - image: dokken/ubuntu-18.04 - pid_one_command: /bin/systemd - - name: ubuntu-20.04 - driver: - image: dokken/ubuntu-20.04 - pid_one_command: /bin/systemd - - - name: rockylinux-8 - driver: - image: dokken/rockylinux-8 - pid_one_command: /usr/lib/systemd/systemd suites: - name: server @@ -83,15 +34,15 @@ suites: config: verb: 1 mute: 10 - route: - - '192.168.4.0 255.255.255.0' + route: ["192.168.4.0 255.255.255.0"] push_routes: - 192.168.10.0 255.255.255.0 - 10.12.10.0 255.255.255.0 push_options: dhcp-option: - - 'DOMAIN local' - - 'DOMAIN-SEARCH local' + - "DOMAIN local" + - "DOMAIN-SEARCH local" + - name: server_verification run_list: - recipe[openvpn::server] @@ -99,6 +50,7 @@ suites: attributes: openvpn: server_verification: "remote-cert-tls server" + - name: server_verify_no_databag run_list: - recipe[openvpn::server] diff --git a/metadata.rb b/metadata.rb index 25e6abe..c72c588 100644 --- a/metadata.rb +++ b/metadata.rb @@ -1,11 +1,11 @@ name 'openvpn' -version '7.0.17' maintainer 'Sous Chefs' maintainer_email 'help@sous-chefs.org' license 'Apache-2.0' description 'Installs and configures openvpn and includes rake tasks for managing certs.' source_url 'https://github.com/sous-chefs/openvpn' issues_url 'https://github.com/sous-chefs/openvpn/issues' +version '7.0.17' chef_version '>= 15.3' supports 'arch'