Skip to content

Commit

Permalink
Merge branch 'master' into add-network_interfaces_eni
Browse files Browse the repository at this point in the history
  • Loading branch information
xorima authored Nov 20, 2020
2 parents 191f11b + 9f145b1 commit 75ce557
Show file tree
Hide file tree
Showing 22 changed files with 285 additions and 72 deletions.
10 changes: 10 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
version: 2.1
orbs:
kitchen: sous-chefs/kitchen@2
workflows:
danger:
jobs:
- kitchen/danger:
name: danger
context: Danger-Minimal
19 changes: 19 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# https://EditorConfig.org

# top-most EditorConfig file
root=true

# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true

# 2 space indentation
indent_style = space
indent_size = 2

# Avoid issues parsing cookbook files later
charset = utf-8

# Avoid cookstyle warnings
trim_trailing_whitespace = true
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use chefworkstation
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* text=auto eol=lf
19 changes: 19 additions & 0 deletions .github/workflows/md-links.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: md-links

"on":
pull_request:
push:
branches: [master]

jobs:
md-links:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@master
- name: markdown-link-check
uses: gaurav-nelson/github-action-markdown-link-check@v1
with:
use-verbose-mode: "yes"
folder-path: "documentation"
28 changes: 28 additions & 0 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Mark stale issues and pull requests

"on":
schedule:
- cron: "0 0 * * *"

jobs:
stale:

runs-on: ubuntu-latest

steps:
- uses: actions/stale@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
close-issue-message: >
Closing due to inactivity.
If this is still an issue please reopen or open another issue.
Alternatively drop by the #sous-chefs channel on the [Chef Community Slack](http://community-slack.chef.io/) and we'll be happy to help!
Thanks, Sous-Chefs.
days-before-close: 7
days-before-stale: 365
stale-issue-message: >
Marking stale due to inactivity.
Remove stale label or comment or this will be closed in 7 days.
Alternatively drop by the #sous-chefs channel on the [Chef Community Slack](http://community-slack.chef.io/) and we'll be happy to help!
Thanks, Sous-Chefs.
48 changes: 37 additions & 11 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,23 +1,49 @@
*.rbc
.config
InstalledFiles
pkg
test/tmp
test/version_tmp
tmp
_Store
*~
*#
.#*
\#*#
.*.sw[a-z]
*.un~
*.tmp
*.bk
*.bkup
.kitchen.local.yml
Berksfile.lock

# editor files
.idea
.*.sw[a-z]

# ruby/bundler/rspec files
.ruby-version
.ruby-gemset
.rvmrc
Gemfile.lock
.bundle
*.gem
coverage
spec/reports

.bundle/
.cache/
.kitchen/
.vagrant/
.vagrant.d/
.yardoc/
bin/
# YARD / rdoc artifacts
.yardoc
_yardoc
doc/
tmp/
rdoc

# chef infra stuff
Berksfile.lock
.kitchen
kitchen.local.yml
vendor/
.coverage/
.zero-knife.rb
Policyfile.lock.json

# vagrant stuff
.vagrant/
.vagrant.d/
20 changes: 20 additions & 0 deletions .overcommit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
PreCommit:
TrailingWhitespace:
enabled: true
YamlLint:
enabled: true
Rspec:
enabled: true
required_executable: 'rspec'
Cookstyle:
enabled: true
required_executable: 'cookstyle'
command: ["cookstyle"]
Delivery:
enabled: true
required_executable: 'delivery'
flags: ['local', 'all']
CommitMsg:
HardTabs:
enabled: true
7 changes: 7 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"recommendations": [
"chef-software.chef",
"rebornix.ruby",
"editorconfig.editorconfig"
]
}
7 changes: 7 additions & 0 deletions .yamllint
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
extends: default
rules:
line-length:
max: 256
level: warning
document-start: disable
2 changes: 1 addition & 1 deletion Berksfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
source 'https://supermarket.getchef.com'
source 'https://supermarket.chef.io'

metadata

Expand Down
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
network_interface
=================
## Unreleased

- resolved cookstyle error: Berksfile:1:1 refactor: `ChefModernize/LegacyBerksfileSource`
- resolved cookstyle error: libraries/matchers.rb:1:1 refactor: `ChefModernize/DefinesChefSpecMatchers`
- resolved cookstyle error: metadata.rb:6:1 refactor: `ChefRedundantCode/LongDescriptionMetadata`
- resolved cookstyle error: providers/default.rb:1:1 refactor: `ChefModernize/WhyRunSupportedTrue`
- resolved cookstyle error: providers/default.rb:5:1 warning: `ChefDeprecations/UseInlineResourcesDefined`
- resolved cookstyle error: providers/default.rb:8:8 warning: `ChefDeprecations/NodeSet`
- resolved cookstyle error: recipes/default.rb:2:1 refactor: `ChefStyle/CommentFormat`
- resolved cookstyle error: recipes/default.rb:8:1 refactor: `ChefStyle/CommentFormat`
- resolved cookstyle error: recipes/default.rb:9:1 refactor: `ChefStyle/CommentFormat`
- resolved cookstyle error: recipes/default.rb:25:6 warning: `ChefDeprecations/NodeSet`


# Unreleased:

Expand Down
3 changes: 3 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Community Guidelines

This project follows the Chef Community Guidelines <https://docs.chef.io/community_guidelines.html>
4 changes: 4 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Contributing

Please refer to
[https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD](https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD)
47 changes: 47 additions & 0 deletions Dangerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# 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
3 changes: 3 additions & 0 deletions TESTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Testing

Please refer to [the community cookbook documentation on testing](https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/TESTING.MD).
Loading

0 comments on commit 75ce557

Please sign in to comment.