Skip to content

Commit c186a06

Browse files
committed
feat: added github related confis
1 parent 5107eed commit c186a06

14 files changed

+370
-482
lines changed

.gitattributes

+15-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,15 @@
1-
# Auto detect text files and perform LF normalization
2-
* text=auto
1+
# Needed for publishing of examples, build worker defaults to core.autocrlf=input.
2+
* text eol=autocrlf
3+
4+
*.mof text eol=crlf
5+
*.sh text eol=lf
6+
*.svg eol=lf
7+
8+
# Ensure any exe files are treated as binary
9+
*.exe binary
10+
*.jpg binary
11+
*.xl* binary
12+
*.pfx binary
13+
*.png binary
14+
*.dll binary
15+
*.so binary

.github/ISSUE_TEMPLATE/General.md

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
name: General question or documentation update
3+
about: If you have a general question or documentation update suggestion around the resource module.
4+
---
5+
6+
<!--
7+
Your feedback and support is greatly appreciated, thanks for contributing!
8+
-->
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
name: Problem with a resource
2+
description: If you have a problem, bug, or enhancement with a resource in this resource module.
3+
labels: []
4+
assignees: []
5+
body:
6+
- type: markdown
7+
attributes:
8+
value: |
9+
Please prefix the issue title (above) with the resource name, e.g. 'ResourceName: Short description of my issue'!
10+
11+
Your feedback and support is greatly appreciated, thanks for contributing!
12+
- type: textarea
13+
id: description
14+
attributes:
15+
label: Problem description
16+
description: Details of the scenario you tried and the problem that is occurring.
17+
validations:
18+
required: true
19+
- type: textarea
20+
id: logs
21+
attributes:
22+
label: Verbose logs
23+
description: |
24+
Verbose logs showing the problem. **NOTE! Sensitive information should be obfuscated.** _Will be automatically formatted as plain text._
25+
placeholder: |
26+
Paste verbose logs here
27+
render: text
28+
validations:
29+
required: true
30+
- type: textarea
31+
id: configuration
32+
attributes:
33+
label: DSC configuration
34+
description: |
35+
The DSC configuration that is used to reproduce the issue (as detailed as possible). **NOTE! Sensitive information should be obfuscated.** _Will be automatically formatted as PowerShell code._
36+
placeholder: |
37+
Paste DSC configuration here
38+
render: powershell
39+
validations:
40+
required: true
41+
- type: textarea
42+
id: suggestedSolution
43+
attributes:
44+
label: Suggested solution
45+
description: Do you have any suggestions how to solve the issue?
46+
validations:
47+
required: true
48+
- type: textarea
49+
id: targetNodeOS
50+
attributes:
51+
label: Operating system the target node is running
52+
description: |
53+
Please provide as much as possible about the target node, for example edition, version, build, and language. _Will be automatically formatted as plain text._
54+
55+
On OS with WMF 5.1 the following command can help get this information: `Get-ComputerInfo -Property @('OsName','OsOperatingSystemSKU','OSArchitecture','WindowsVersion','WindowsBuildLabEx','OsLanguage','OsMuiLanguages')`
56+
placeholder: |
57+
Add operating system information here
58+
render: text
59+
validations:
60+
required: true
61+
- type: textarea
62+
id: targetNodePS
63+
attributes:
64+
label: PowerShell version and build the target node is running
65+
description: |
66+
Please provide the version and build of PowerShell the target node is running. _Will be automatically formatted as plain text._
67+
68+
To help with this information, please run this command: `$PSVersionTable`
69+
placeholder: |
70+
Add PowerShell information here
71+
render: text
72+
validations:
73+
required: true
74+
- type: textarea
75+
id: moduleVersion
76+
attributes:
77+
label: xoap-application-packaging-dsc version
78+
description: |
79+
Please provide the version of the xoap-application-packaging-dsc module that was used. _Will be automatically formatted as plain text._
80+
81+
To help with this information, please run this command: `Get-Module -Name 'xoap-application-packaging-dsc' -ListAvailable | ft Name,Version,Path`
82+
placeholder: |
83+
Add module information here
84+
render: text
85+
validations:
86+
required: true
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: New resource proposal
2+
description: If you have a new resource proposal that you think should be added to this resource module.
3+
title: "NewResourceName: New resource proposal"
4+
labels: []
5+
assignees: []
6+
body:
7+
- type: markdown
8+
attributes:
9+
value: |
10+
Please replace `NewResourceName` in the issue title (above) with your proposed resource name.
11+
12+
Thank you for contributing and making this resource module better!
13+
- type: textarea
14+
id: description
15+
attributes:
16+
label: Resource proposal
17+
description: Provide information how this resource will/should work and how it will help users.
18+
validations:
19+
required: true
20+
- type: textarea
21+
id: proposedProperties
22+
attributes:
23+
label: Proposed properties
24+
description: |
25+
List all the proposed properties that the resource should have (key, required, write, and/or read). For each property provide a detailed description, the data type, if a default value should be used, and if the property is limited to a set of values.
26+
value: |
27+
Property | Type qualifier | Data type | Description | Default value | Allowed values
28+
--- | --- | --- | --- | --- | ---
29+
PropertyName | Key | String | Detailed description | None | None
30+
validations:
31+
required: true
32+
- type: textarea
33+
id: considerations
34+
attributes:
35+
label: Special considerations or limitations
36+
description: |
37+
Provide any considerations or limitations you can think of that a contributor should take in account when coding the proposed resource, and or what limitations a user will encounter or should consider when using the proposed resource.
38+
validations:
39+
required: true

.github/ISSUE_TEMPLATE/config.yml

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: "Virtual PowerShell User Group #DSC channel"
4+
url: https://dsccommunity.org/community/contact/
5+
about: "To talk to the community and maintainers of DSC Community, please visit the #DSC channel."

.github/PULL_REQUEST_TEMPLATE.md

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
<!--
2+
Thanks for submitting a Pull Request (PR) to this project. Your contribution to this project
3+
is greatly appreciated!
4+
5+
Please prefix the PR title with the resource name, e.g. 'ResourceName: My short description'.
6+
If this is a breaking change, then also prefix the PR title with 'BREAKING CHANGE:',
7+
e.g. 'BREAKING CHANGE: ResourceName: My short description'.
8+
9+
You may remove this comment block, and the other comment blocks, but please keep the headers
10+
and the task list.
11+
-->
12+
13+
#### Pull Request (PR) description
14+
15+
<!--
16+
Replace this comment block with a description of your PR. Also, make sure you have updated the
17+
CHANGELOG.md, see the task list below. An entry in the CHANGELOG.md is mandatory for all PRs.
18+
-->
19+
20+
#### This Pull Request (PR) fixes the following issues
21+
22+
<!--
23+
If this PR does not fix an open issue, replace this comment block with None. If this PR
24+
resolves one or more open issues, replace this comment block with a list of the issues using
25+
a GitHub closing keyword, e.g.:
26+
27+
- Fixes #123
28+
- Fixes #124
29+
-->
30+
31+
#### Task list
32+
33+
<!--
34+
To aid community reviewers in reviewing and merging your PR, please take the time to run
35+
through the below checklist and make sure your PR has everything updated as required.
36+
37+
Change to [x] for each task in the task list that applies to your PR. For those task that
38+
don't apply to you PR, leave those as is.
39+
-->
40+
41+
- [ ] Added an entry to the change log under the Unreleased section of the file CHANGELOG.md.
42+
Entry should say what was changed and how that affects users (if applicable), and
43+
reference the issue being resolved (if applicable).
44+
- [ ] Resource documentation added/updated in README.md.
45+
- [ ] Resource parameter descriptions added/updated in README.md, schema.mof and comment-based
46+
help.
47+
- [ ] Comment-based help added/updated.
48+
- [ ] Localization strings added/updated in all localization files as appropriate.
49+
- [ ] Examples appropriately added/updated.
50+
- [ ] Unit tests added/updated. See [DSC Community Testing Guidelines](https://dsccommunity.org/guidelines/testing-guidelines).
51+
- [ ] Integration tests added/updated (where possible). See [DSC Community Testing Guidelines](https://dsccommunity.org/guidelines/testing-guidelines).
52+
- [ ] New/changed code adheres to [DSC Community Style Guidelines](https://dsccommunity.org/styleguidelines).

.github/dependabot.yml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
version: 2
3+
updates:
4+
- package-ecosystem: github-actions
5+
directory: /
6+
target-branch: dev
7+
schedule:
8+
interval: daily
9+
labels:
10+
- github-actions
11+
- dependencies
12+
- package-ecosystem: terraform
13+
directory: /
14+
target-branch: dev
15+
schedule:
16+
interval: daily
17+
labels:
18+
- terraform
19+
- dependencies
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: Commit linter
2+
on:
3+
pull_request:
4+
branches: [main, master]
5+
jobs:
6+
commitlint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v3
10+
with:
11+
fetch-depth: 0
12+
- uses: wagoid/commitlint-github-action@v4

.github/workflows/dependabot.yaml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
---
2+
name: Dependabot Pull Request Approve and Merge
3+
on: pull_request_target
4+
permissions:
5+
pull-requests: write
6+
contents: write
7+
jobs:
8+
dependabot:
9+
runs-on: ubuntu-latest
10+
if: ${{ github.actor == 'dependabot[bot]' }}
11+
steps:
12+
- name: Dependabot metadata
13+
id: dependabot-metadata
14+
uses: dependabot/[email protected]
15+
with:
16+
github-token: ${{ secrets.GITHUB_TOKEN }}
17+
- name: Approve a PR
18+
run: gh pr review --approve "$PR_URL"
19+
env:
20+
PR_URL: ${{ github.event.pull_request.html_url }}
21+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
22+
- name: Enable auto-merge for Dependabot PRs
23+
if: ${{ steps.dependabot-metadata.outputs.update-type != 'version-update:semver-major' }}
24+
run: gh pr merge --auto --squash "$PR_URL"
25+
env:
26+
PR_URL: ${{ github.event.pull_request.html_url }}
27+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/megalinter.yaml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
name: Linting files
3+
on:
4+
pull_request:
5+
branches: [main, master]
6+
concurrency:
7+
group: ${{ github.ref }}-${{ github.workflow }}
8+
cancel-in-progress: true
9+
jobs:
10+
build:
11+
name: MegaLinter
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout Code
15+
uses: actions/checkout@v3
16+
with:
17+
token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }}
18+
fetch-depth: 0
19+
- name: MegaLinter
20+
id: ml
21+
uses: megalinter/megalinter/flavors/terraform@v5
22+
env:
23+
VALIDATE_ALL_CODEBASE: true
24+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
25+
DISABLE: COPYPASTE,SPELL
26+
DISABLE_LINTERS: TERRAFORM_TERRASCAN
27+
- name: Archive production artifacts
28+
if: ${{ success() }} || ${{ failure() }}
29+
uses: actions/upload-artifact@v2
30+
with:
31+
name: MegaLinter reports
32+
path: |
33+
report
34+
mega-linter.log

.github/workflows/tagging.yaml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
name: Create tag and release
3+
4+
on:
5+
push:
6+
branches:
7+
- master
8+
- main
9+
10+
jobs:
11+
tag:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v3
16+
with:
17+
token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }}
18+
fetch-depth: 0
19+
- name: Github Tag with semantic versioning
20+
# You may pin to the exact commit or the version.
21+
# uses: hennejg/github-tag-action@2cd21a8413aa58e36a69cb22e64d5ad20aeb9b99
22+
id: tag_version
23+
uses: hennejg/[email protected]
24+
with:
25+
tag_prefix: ""
26+
# Required for permission to tag the repo.
27+
github_token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }}
28+
- name: Zip Release
29+
# You may pin to the exact commit or the version.
30+
# uses: TheDoctor0/zip-release@09336613be18a8208dfa66bd57efafd9e2685657
31+
id: zip
32+
uses: TheDoctor0/[email protected]
33+
with:
34+
type: 'zip'
35+
filename: 'XOAPApplicationPackagingDSC_${{ steps.tag_version.outputs.new_tag }}.zip'
36+
exclusions: '*.git* /*License/* CONTRIBUTING.md CODEOWNERS.md CODE_OF_CONDUCT.md .pre-commit.yaml .gitignore .gitattributes .github'
37+
- name: Create a GitHub release
38+
uses: ncipollo/release-action@v1
39+
with:
40+
artifacts: 'XOAPApplicationPackagingDSC_${{ steps.tag_version.outputs.new_tag }}.zip'
41+
tag: ${{ steps.tag_version.outputs.new_tag }}
42+
name: ${{ steps.tag_version.outputs.new_tag }}
43+
body: ${{ steps.tag_version.outputs.changelog }}

0 commit comments

Comments
 (0)