Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use system Puppet in CI #942

Draft
wants to merge 2 commits into
base: develop
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 12 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,17 +26,23 @@ jobs:
matrix:
include:
- ruby: '2.7'
puppet: '7.0'
puppet: '7'
- ruby: '3.0'
puppet: '7.0'
puppet: '7'
- ruby: '3.2'
puppet: '8.0'
puppet: '8'
env:
PUPPET_VERSION: ${{ matrix.puppet }}
BUNDLE_WITHOUT: puppet:rubocop
steps:
- uses: actions/checkout@v4
- name: Set up Puppet repositories
run: |
. /etc/os-release
wget "https://apt.puppet.com/puppet${{ matrix.puppet }}-release-${VERSION_CODENAME}.deb"
sudo apt install "${PWD}/puppet${{ matrix.puppet }}-release-${VERSION_CODENAME}.deb"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to do ./puppet...., apt refuses local installs from things that don't look like paths

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's why I added ${PWD}. I guess ./ would have also worked.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah yes, the race between typing a comment on mobile and forgetting to hit send and you pushing more changes :)

sudo apt update
- name: Install system dependencies
run: sudo apt-get install -y --no-install-recommends asciidoc
run: sudo apt-get install -y --no-install-recommends asciidoc puppet-agent
- name: Setup ruby
uses: ruby/setup-ruby@v1
with:
Expand All @@ -51,6 +57,7 @@ jobs:
run: bundle exec rake spec
- name: Test installer configuration
run: |
. /etc/profile.d/puppet-agent.sh
bundle exec rake install PREFIX=./local --trace
bundle exec rake installation_tests PREFIX=./local --trace

Expand Down
51 changes: 0 additions & 51 deletions .packit.yaml

This file was deleted.

12 changes: 9 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,11 @@ gem 'rdoc', '< 6.4'

gem 'kafo', '>= 7.3', '< 8'
gem 'librarian-puppet', '>= 3.0'
gem 'puppet', ENV.key?('PUPPET_VERSION') ? "~> #{ENV['PUPPET_VERSION']}" : '~> 7.0'
gem 'facter', '>= 3.0', '!= 4.0.52'

group :puppet do
gem 'puppet', ENV.key?('PUPPET_VERSION') ? "~> #{ENV['PUPPET_VERSION']}" : '~> 7.0'
gem 'facter', '>= 3.0', '!= 4.0.52'
end

gem 'puppet-strings'
gem 'rake'
Expand All @@ -16,10 +19,13 @@ gem 'racc' if RUBY_VERSION >= '3.3'

gem 'semverse', groups: [:development, :test]

group :rubocop do
gem 'rubocop', '~> 0.80.0'
end

group :test do
gem 'rspec'
gem 'rspec_junit_formatter'
gem 'rubocop', '~> 0.80.0'
end

group :development do
Expand Down
Loading