Skip to content
Merged
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
10 changes: 10 additions & 0 deletions .fixtures.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
fixtures:
symlinks:
lldpd: "#{source_dir}"
forge_modules:
bodgitlib:
repo: "bodgit/bodgitlib"
ref: "2.0.1"
ip:
repo: "thrnio/ip"
ref: "1.0.1"
stdlib:
repo: "puppetlabs/stdlib"
ref: "4.25.0"
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
*.rb eol=lf
*.erb eol=lf
*.pp eol=lf
*.sh eol=lf
*.epp eol=lf
24 changes: 24 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: Deploy
on:
release:
types:
- published
jobs:
deploy:
name: Deploy to Forge
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
ref: ${{ github.ref }}
clean: true
- name: PDK build
uses: docker://puppet/pdk:nightly
with:
args: build
- name: Push to Forge
uses: docker://puppet/pdk:nightly
with:
args: release publish --forge-token ${{ secrets.FORGE_API_KEY }} --force
79 changes: 79 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
---
name: Test
on:
push:
branches:
- main
tags:
- 'v[0-9]*'
pull_request:
branches:
- main
schedule:
- cron: '0 0 1 * *'
jobs:
static:
name: Static tests
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Activate Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 2.7
bundler-cache: true
- name: Run static & syntax tests
run: |
bundle exec rake check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop syntax lint metadata_lint
spec:
name: 'Spec tests (Puppet: ${{ matrix.puppet_gem_version }}, Ruby: ${{ matrix.ruby }})'
strategy:
fail-fast: false
matrix:
include:
- puppet_gem_version: ~> 5.0
ruby: 2.4
- puppet_gem_version: ~> 6.0
ruby: 2.5
- puppet_gem_version: ~> 7.0
ruby: 2.7
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Activate Ruby
uses: ruby/setup-ruby@v1
env:
PUPPET_GEM_VERSION: ${{ matrix.puppet_gem_version }}
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Run parallel_spec tests
run: |
bundle exec rake parallel_spec
env:
SIMPLECOV: yes
release:
name: Create release
needs:
- static
- spec
if: github.event_name == 'push' && contains(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
ref: ${{ github.ref }}
clean: true
fetch-depth: 0
- name: Create release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false
37 changes: 26 additions & 11 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,27 @@
.librarian
.tmp
.vagrant
.git/
.*.sw[op]
.metadata
.yardoc
Gemfile.lock
Puppetfile.lock
spec/fixtures/manifests
spec/fixtures/modules
pkg
log
coverage
doc
.yardwarns
*.iml
/.bundle/
/.idea/
/.vagrant/
/coverage/
/bin/
/doc/
/Gemfile.local
/Gemfile.lock
/junit/
/log/
/pkg/
/spec/fixtures/manifests/
/spec/fixtures/modules/
/tmp/
/vendor/
/convert_report.txt
/update_report.txt
.DS_Store
.project
.envrc
/inventory.yaml
45 changes: 45 additions & 0 deletions .pdkignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
.git/
.*.sw[op]
.metadata
.yardoc
.yardwarns
*.iml
/.bundle/
/.idea/
/.vagrant/
/coverage/
/bin/
/doc/
/Gemfile.local
/Gemfile.lock
/junit/
/log/
/pkg/
/spec/fixtures/manifests/
/spec/fixtures/modules/
/tmp/
/vendor/
/convert_report.txt
/update_report.txt
.DS_Store
.project
.envrc
/inventory.yaml
/appveyor.yml
/.fixtures.yml
/Gemfile
/.gitattributes
/.gitignore
/.gitlab-ci.yml
/.pdkignore
/.puppet-lint.rc
/Rakefile
/rakelib/
/.rspec
/.rubocop.yml
/.travis.yml
/.yardopts
/spec/
/.vscode/
/.sync.yml
/.devcontainer/
2 changes: 2 additions & 0 deletions .puppet-lint.rc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
--fail-on-warnings
--relative
2 changes: 2 additions & 0 deletions .rspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
--color
--format documentation
Loading