Merge pull request 'Upgrade LND to 0.14.1' (#367) from chore/upgrade_lnd into master
Reviewed-on: #367
This commit is contained in:
commit
3d06300167
|
@ -52,5 +52,5 @@ cookbook 'ipfs',
|
||||||
cookbook 'elasticsearch', '= 4.2.0'
|
cookbook 'elasticsearch', '= 4.2.0'
|
||||||
cookbook 'java', '~> 4.3.0'
|
cookbook 'java', '~> 4.3.0'
|
||||||
cookbook 'ulimit', '~> 1.0.0'
|
cookbook 'ulimit', '~> 1.0.0'
|
||||||
cookbook 'golang', '~> 4.1.0'
|
cookbook 'golang', '~> 5.3.1'
|
||||||
cookbook 'zerotier', '~> 1.0.7'
|
cookbook 'zerotier', '~> 1.0.7'
|
||||||
|
|
|
@ -12,7 +12,7 @@ DEPENDENCIES
|
||||||
elasticsearch (= 4.2.0)
|
elasticsearch (= 4.2.0)
|
||||||
firewall (~> 2.6.3)
|
firewall (~> 2.6.3)
|
||||||
git (~> 10.0.0)
|
git (~> 10.0.0)
|
||||||
golang (~> 4.1.0)
|
golang (~> 5.3.1)
|
||||||
homebrew (= 3.0.0)
|
homebrew (= 3.0.0)
|
||||||
hostname (= 0.4.2)
|
hostname (= 0.4.2)
|
||||||
hostsfile (~> 3.0.1)
|
hostsfile (~> 3.0.1)
|
||||||
|
@ -69,8 +69,8 @@ GRAPH
|
||||||
poise-javascript (~> 1.0)
|
poise-javascript (~> 1.0)
|
||||||
poise-service (~> 1.0)
|
poise-service (~> 1.0)
|
||||||
apt (7.3.0)
|
apt (7.3.0)
|
||||||
ark (5.0.0)
|
ark (6.0.3)
|
||||||
seven_zip (>= 0.0.0)
|
seven_zip (>= 3.1)
|
||||||
build-essential (8.2.1)
|
build-essential (8.2.1)
|
||||||
mingw (>= 1.1)
|
mingw (>= 1.1)
|
||||||
seven_zip (>= 0.0.0)
|
seven_zip (>= 0.0.0)
|
||||||
|
@ -89,8 +89,8 @@ GRAPH
|
||||||
firewall (2.6.5)
|
firewall (2.6.5)
|
||||||
chef-sugar (>= 0.0.0)
|
chef-sugar (>= 0.0.0)
|
||||||
git (10.0.0)
|
git (10.0.0)
|
||||||
golang (4.1.0)
|
golang (5.3.1)
|
||||||
ark (~> 5.0)
|
ark (>= 6.0)
|
||||||
homebrew (3.0.0)
|
homebrew (3.0.0)
|
||||||
hostname (0.4.2)
|
hostname (0.4.2)
|
||||||
hostsfile (>= 0.0.0)
|
hostsfile (>= 0.0.0)
|
||||||
|
@ -109,20 +109,20 @@ GRAPH
|
||||||
apache2 (>= 0.0.0)
|
apache2 (>= 0.0.0)
|
||||||
nginx (>= 0.0.0)
|
nginx (>= 0.0.0)
|
||||||
php (>= 0.0.0)
|
php (>= 0.0.0)
|
||||||
mingw (2.1.0)
|
mingw (2.1.3)
|
||||||
seven_zip (>= 0.0.0)
|
seven_zip (>= 0.0.0)
|
||||||
mysql (8.7.3)
|
mysql (8.7.4)
|
||||||
nginx (9.0.0)
|
nginx (9.0.0)
|
||||||
build-essential (>= 5.0)
|
build-essential (>= 5.0)
|
||||||
ohai (>= 4.1.0)
|
ohai (>= 4.1.0)
|
||||||
yum-epel (>= 0.0.0)
|
yum-epel (>= 0.0.0)
|
||||||
nodejs (7.3.1)
|
nodejs (7.3.3)
|
||||||
ark (>= 2.0.2)
|
ark (>= 2.0.2)
|
||||||
chocolatey (>= 3.0)
|
chocolatey (>= 3.0)
|
||||||
ntp (3.4.0)
|
ntp (3.4.0)
|
||||||
ohai (5.2.5)
|
ohai (5.2.5)
|
||||||
openssl (8.5.5)
|
openssl (8.5.5)
|
||||||
php (8.0.0)
|
php (8.0.1)
|
||||||
yum-epel (>= 0.0.0)
|
yum-epel (>= 0.0.0)
|
||||||
poise (2.8.2)
|
poise (2.8.2)
|
||||||
poise-archive (1.5.0)
|
poise-archive (1.5.0)
|
||||||
|
@ -155,13 +155,12 @@ GRAPH
|
||||||
selinux_policy (>= 2.2.0)
|
selinux_policy (>= 2.2.0)
|
||||||
ulimit (>= 0.1.2)
|
ulimit (>= 0.1.2)
|
||||||
selinux_policy (2.4.3)
|
selinux_policy (2.4.3)
|
||||||
seven_zip (3.1.1)
|
seven_zip (4.2.2)
|
||||||
windows (>= 0.0.0)
|
|
||||||
timezone_iii (1.0.4)
|
timezone_iii (1.0.4)
|
||||||
ulimit (1.0.0)
|
ulimit (1.0.0)
|
||||||
users (5.3.1)
|
users (5.3.1)
|
||||||
windows (6.0.0)
|
windows (7.0.2)
|
||||||
yum (5.1.0)
|
yum (7.2.0)
|
||||||
yum-epel (3.3.0)
|
yum-epel (4.2.3)
|
||||||
zerotier (1.0.7)
|
zerotier (1.0.7)
|
||||||
ohai (>= 0.0.0)
|
ohai (>= 0.0.0)
|
||||||
|
|
|
@ -2,6 +2,40 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of the ark cookbook.
|
This file is used to list changes made in each version of the ark cookbook.
|
||||||
|
|
||||||
|
## 6.0.3 - *2021-08-30*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 6.0.2 - *2021-06-18*
|
||||||
|
|
||||||
|
- Update location of test archive fixtures
|
||||||
|
|
||||||
|
## 6.0.1 - *2021-06-01*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 6.0.0 - *2021-05-22*
|
||||||
|
|
||||||
|
- Chef 17 updates: enable `unified_mode` on all resources
|
||||||
|
- Bump required Chef Infra Client to >= 15.3
|
||||||
|
- Migrate to using `seven_zip_tool` resource directly and require `seven_zip` >= 3.1
|
||||||
|
- Various ChefSpec fixes
|
||||||
|
|
||||||
|
## 5.1.1 - *2021-04-29*
|
||||||
|
|
||||||
|
- Added a version pin on seven_zip
|
||||||
|
|
||||||
|
## 5.1.0 - *2021-01-24*
|
||||||
|
|
||||||
|
- Sous Chefs Adoption
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
- Cookstyle fixes
|
||||||
|
- Add integration testing for Windows and MacOS
|
||||||
|
- Remove testing for Amazon Linux 201x, CentOS 6 and Ubuntu 16.04
|
||||||
|
- Fix ChefSpec tests
|
||||||
|
- Fix issues with `--strip-components` with the `:cherry_pick` action on MacOS
|
||||||
|
- Ensure `/etc/profile.d` exists on MacOS if `append_env_path` is used
|
||||||
|
|
||||||
## 5.0.0 (2020-01-02)
|
## 5.0.0 (2020-01-02)
|
||||||
|
|
||||||
- Require Chef Infra Client 14+ and remove the need for the build_essential dependency - [@tas50](https://github.com/tas50)
|
- Require Chef Infra Client 14+ and remove the need for the build_essential dependency - [@tas50](https://github.com/tas50)
|
||||||
|
@ -33,8 +67,9 @@ This file is used to list changes made in each version of the ark cookbook.
|
||||||
- Rewrite of resource to custom resources.
|
- Rewrite of resource to custom resources.
|
||||||
- Remove EOL platforms from testing.
|
- Remove EOL platforms from testing.
|
||||||
- Update zlib URL
|
- Update zlib URL
|
||||||
-
|
|
||||||
## 2.2.1 (2016-12-16)
|
## 2.2.1 (2016-12-16)
|
||||||
|
|
||||||
- Use Ohai root_group attribute to avoid trying to set the group to root on BSD/macOS.
|
- Use Ohai root_group attribute to avoid trying to set the group to root on BSD/macOS.
|
||||||
- Add missing accessor for owner property
|
- Add missing accessor for owner property
|
||||||
|
|
||||||
|
|
|
@ -1,2 +0,0 @@
|
||||||
Please refer to
|
|
||||||
https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD
|
|
|
@ -0,0 +1,202 @@
|
||||||
|
Apache License
|
||||||
|
Version 2.0, January 2004
|
||||||
|
http://www.apache.org/licenses/
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||||
|
|
||||||
|
1. Definitions.
|
||||||
|
|
||||||
|
"License" shall mean the terms and conditions for use, reproduction,
|
||||||
|
and distribution as defined by Sections 1 through 9 of this document.
|
||||||
|
|
||||||
|
"Licensor" shall mean the copyright owner or entity authorized by
|
||||||
|
the copyright owner that is granting the License.
|
||||||
|
|
||||||
|
"Legal Entity" shall mean the union of the acting entity and all
|
||||||
|
other entities that control, are controlled by, or are under common
|
||||||
|
control with that entity. For the purposes of this definition,
|
||||||
|
"control" means (i) the power, direct or indirect, to cause the
|
||||||
|
direction or management of such entity, whether by contract or
|
||||||
|
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||||
|
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||||
|
|
||||||
|
"You" (or "Your") shall mean an individual or Legal Entity
|
||||||
|
exercising permissions granted by this License.
|
||||||
|
|
||||||
|
"Source" form shall mean the preferred form for making modifications,
|
||||||
|
including but not limited to software source code, documentation
|
||||||
|
source, and configuration files.
|
||||||
|
|
||||||
|
"Object" form shall mean any form resulting from mechanical
|
||||||
|
transformation or translation of a Source form, including but
|
||||||
|
not limited to compiled object code, generated documentation,
|
||||||
|
and conversions to other media types.
|
||||||
|
|
||||||
|
"Work" shall mean the work of authorship, whether in Source or
|
||||||
|
Object form, made available under the License, as indicated by a
|
||||||
|
copyright notice that is included in or attached to the work
|
||||||
|
(an example is provided in the Appendix below).
|
||||||
|
|
||||||
|
"Derivative Works" shall mean any work, whether in Source or Object
|
||||||
|
form, that is based on (or derived from) the Work and for which the
|
||||||
|
editorial revisions, annotations, elaborations, or other modifications
|
||||||
|
represent, as a whole, an original work of authorship. For the purposes
|
||||||
|
of this License, Derivative Works shall not include works that remain
|
||||||
|
separable from, or merely link (or bind by name) to the interfaces of,
|
||||||
|
the Work and Derivative Works thereof.
|
||||||
|
|
||||||
|
"Contribution" shall mean any work of authorship, including
|
||||||
|
the original version of the Work and any modifications or additions
|
||||||
|
to that Work or Derivative Works thereof, that is intentionally
|
||||||
|
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||||
|
or by an individual or Legal Entity authorized to submit on behalf of
|
||||||
|
the copyright owner. For the purposes of this definition, "submitted"
|
||||||
|
means any form of electronic, verbal, or written communication sent
|
||||||
|
to the Licensor or its representatives, including but not limited to
|
||||||
|
communication on electronic mailing lists, source code control systems,
|
||||||
|
and issue tracking systems that are managed by, or on behalf of, the
|
||||||
|
Licensor for the purpose of discussing and improving the Work, but
|
||||||
|
excluding communication that is conspicuously marked or otherwise
|
||||||
|
designated in writing by the copyright owner as "Not a Contribution."
|
||||||
|
|
||||||
|
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||||
|
on behalf of whom a Contribution has been received by Licensor and
|
||||||
|
subsequently incorporated within the Work.
|
||||||
|
|
||||||
|
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
copyright license to reproduce, prepare Derivative Works of,
|
||||||
|
publicly display, publicly perform, sublicense, and distribute the
|
||||||
|
Work and such Derivative Works in Source or Object form.
|
||||||
|
|
||||||
|
3. Grant of Patent License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
(except as stated in this section) patent license to make, have made,
|
||||||
|
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||||
|
where such license applies only to those patent claims licensable
|
||||||
|
by such Contributor that are necessarily infringed by their
|
||||||
|
Contribution(s) alone or by combination of their Contribution(s)
|
||||||
|
with the Work to which such Contribution(s) was submitted. If You
|
||||||
|
institute patent litigation against any entity (including a
|
||||||
|
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||||
|
or a Contribution incorporated within the Work constitutes direct
|
||||||
|
or contributory patent infringement, then any patent licenses
|
||||||
|
granted to You under this License for that Work shall terminate
|
||||||
|
as of the date such litigation is filed.
|
||||||
|
|
||||||
|
4. Redistribution. You may reproduce and distribute copies of the
|
||||||
|
Work or Derivative Works thereof in any medium, with or without
|
||||||
|
modifications, and in Source or Object form, provided that You
|
||||||
|
meet the following conditions:
|
||||||
|
|
||||||
|
(a) You must give any other recipients of the Work or
|
||||||
|
Derivative Works a copy of this License; and
|
||||||
|
|
||||||
|
(b) You must cause any modified files to carry prominent notices
|
||||||
|
stating that You changed the files; and
|
||||||
|
|
||||||
|
(c) You must retain, in the Source form of any Derivative Works
|
||||||
|
that You distribute, all copyright, patent, trademark, and
|
||||||
|
attribution notices from the Source form of the Work,
|
||||||
|
excluding those notices that do not pertain to any part of
|
||||||
|
the Derivative Works; and
|
||||||
|
|
||||||
|
(d) If the Work includes a "NOTICE" text file as part of its
|
||||||
|
distribution, then any Derivative Works that You distribute must
|
||||||
|
include a readable copy of the attribution notices contained
|
||||||
|
within such NOTICE file, excluding those notices that do not
|
||||||
|
pertain to any part of the Derivative Works, in at least one
|
||||||
|
of the following places: within a NOTICE text file distributed
|
||||||
|
as part of the Derivative Works; within the Source form or
|
||||||
|
documentation, if provided along with the Derivative Works; or,
|
||||||
|
within a display generated by the Derivative Works, if and
|
||||||
|
wherever such third-party notices normally appear. The contents
|
||||||
|
of the NOTICE file are for informational purposes only and
|
||||||
|
do not modify the License. You may add Your own attribution
|
||||||
|
notices within Derivative Works that You distribute, alongside
|
||||||
|
or as an addendum to the NOTICE text from the Work, provided
|
||||||
|
that such additional attribution notices cannot be construed
|
||||||
|
as modifying the License.
|
||||||
|
|
||||||
|
You may add Your own copyright statement to Your modifications and
|
||||||
|
may provide additional or different license terms and conditions
|
||||||
|
for use, reproduction, or distribution of Your modifications, or
|
||||||
|
for any such Derivative Works as a whole, provided Your use,
|
||||||
|
reproduction, and distribution of the Work otherwise complies with
|
||||||
|
the conditions stated in this License.
|
||||||
|
|
||||||
|
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||||
|
any Contribution intentionally submitted for inclusion in the Work
|
||||||
|
by You to the Licensor shall be under the terms and conditions of
|
||||||
|
this License, without any additional terms or conditions.
|
||||||
|
Notwithstanding the above, nothing herein shall supersede or modify
|
||||||
|
the terms of any separate license agreement you may have executed
|
||||||
|
with Licensor regarding such Contributions.
|
||||||
|
|
||||||
|
6. Trademarks. This License does not grant permission to use the trade
|
||||||
|
names, trademarks, service marks, or product names of the Licensor,
|
||||||
|
except as required for reasonable and customary use in describing the
|
||||||
|
origin of the Work and reproducing the content of the NOTICE file.
|
||||||
|
|
||||||
|
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||||
|
agreed to in writing, Licensor provides the Work (and each
|
||||||
|
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||||
|
implied, including, without limitation, any warranties or conditions
|
||||||
|
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||||
|
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||||
|
appropriateness of using or redistributing the Work and assume any
|
||||||
|
risks associated with Your exercise of permissions under this License.
|
||||||
|
|
||||||
|
8. Limitation of Liability. In no event and under no legal theory,
|
||||||
|
whether in tort (including negligence), contract, or otherwise,
|
||||||
|
unless required by applicable law (such as deliberate and grossly
|
||||||
|
negligent acts) or agreed to in writing, shall any Contributor be
|
||||||
|
liable to You for damages, including any direct, indirect, special,
|
||||||
|
incidental, or consequential damages of any character arising as a
|
||||||
|
result of this License or out of the use or inability to use the
|
||||||
|
Work (including but not limited to damages for loss of goodwill,
|
||||||
|
work stoppage, computer failure or malfunction, or any and all
|
||||||
|
other commercial damages or losses), even if such Contributor
|
||||||
|
has been advised of the possibility of such damages.
|
||||||
|
|
||||||
|
9. Accepting Warranty or Additional Liability. While redistributing
|
||||||
|
the Work or Derivative Works thereof, You may choose to offer,
|
||||||
|
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||||
|
or other liability obligations and/or rights consistent with this
|
||||||
|
License. However, in accepting such obligations, You may act only
|
||||||
|
on Your own behalf and on Your sole responsibility, not on behalf
|
||||||
|
of any other Contributor, and only if You agree to indemnify,
|
||||||
|
defend, and hold each Contributor harmless for any liability
|
||||||
|
incurred by, or claims asserted against, such Contributor by reason
|
||||||
|
of your accepting any such warranty or additional liability.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
APPENDIX: How to apply the Apache License to your work.
|
||||||
|
|
||||||
|
To apply the Apache License to your work, attach the following
|
||||||
|
boilerplate notice, with the fields enclosed by brackets "{}"
|
||||||
|
replaced with your own identifying information. (Don't include
|
||||||
|
the brackets!) The text should be enclosed in the appropriate
|
||||||
|
comment syntax for the file format. We also recommend that a
|
||||||
|
file or class name and description of purpose be included on the
|
||||||
|
same "printed page" as the copyright notice for easier
|
||||||
|
identification within third-party archives.
|
||||||
|
|
||||||
|
Copyright {yyyy} {name of copyright owner}
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
# ark cookbook
|
# ark cookbook
|
||||||
|
|
||||||
[![Build Status](https://travis-ci.org/chef-cookbooks/ark.svg?branch=master)](https://travis-ci.org/chef-cookbooks/ark) [![Cookbook Version](https://img.shields.io/cookbook/v/ark.svg)](https://supermarket.chef.io/cookbooks/ark)
|
[![Cookbook Version](https://img.shields.io/cookbook/v/ark.svg)](https://supermarket.chef.io/cookbooks/ark)
|
||||||
|
[![CI State](https://github.com/sous-chefs/ark/workflows/ci/badge.svg)](https://github.com/sous-chefs/ark/actions?query=workflow%3Aci)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/backers/badge.svg)](#backers)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/sponsors/badge.svg)](#sponsors)
|
||||||
|
[![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)](https://opensource.org/licenses/Apache-2.0)
|
||||||
|
|
||||||
## Overview
|
## Overview
|
||||||
|
|
||||||
|
@ -27,6 +31,10 @@ By default, the ark will not run again if the `:path` is not empty. Ark provides
|
||||||
|
|
||||||
For remote files ark supports URLs using the [remote_file](http://docs.chef.io/resource_remote_file.html) resource. Local files are accessed with the `file://` syntax.
|
For remote files ark supports URLs using the [remote_file](http://docs.chef.io/resource_remote_file.html) resource. Local files are accessed with the `file://` syntax.
|
||||||
|
|
||||||
|
## Maintainers
|
||||||
|
|
||||||
|
This cookbook is maintained by the Sous Chefs. The Sous Chefs are a community of Chef cookbook maintainers working together to maintain important cookbooks. If you’d like to know more please visit [sous-chefs.org](https://sous-chefs.org/) or come chat with us on the Chef Community Slack in [#sous-chefs](https://chefcommunity.slack.com/messages/C2V7B88SF).
|
||||||
|
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
### Platforms
|
### Platforms
|
||||||
|
@ -269,29 +277,27 @@ You can also supply the file extension in case the file extension can not be det
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
## License & Authors
|
## Contributors
|
||||||
|
|
||||||
- Author: Philip (flip) Kromer - Infochimps, Inc([coders@infochimps.com](mailto:coders@infochimps.com))
|
This project exists thanks to all the people who [contribute.](https://opencollective.com/sous-chefs/contributors.svg?width=890&button=false)
|
||||||
- Author: Bryan W. Berry ([bryan.berry@gmail.com](mailto:bryan.berry@gmail.com))
|
|
||||||
- Author: Denis Barishev ([denis.barishev@gmail.com](mailto:denis.barishev@gmail.com))
|
|
||||||
- Author: Sean OMeara ([someara@chef.io](mailto:someara@chef.io))
|
|
||||||
- Author: John Bellone ([jbellone@bloomberg.net](mailto:jbellone@bloomberg.net))
|
|
||||||
- Copyright: 2011, Philip (flip) Kromer - Infochimps, Inc
|
|
||||||
- Copyright: 2012, Bryan W. Berry
|
|
||||||
- Copyright: 2012, Denis Barishev
|
|
||||||
- Copyright: 2013-2017, Chef Software, Inc
|
|
||||||
- Copyright: 2014, Bloomberg L.P.
|
|
||||||
|
|
||||||
```
|
### Backers
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
you may not use this file except in compliance with the License.
|
|
||||||
You may obtain a copy of the License at
|
|
||||||
|
|
||||||
http://www.apache.org/licenses/LICENSE-2.0
|
Thank you to all our backers!
|
||||||
|
|
||||||
Unless required by applicable law or agreed to in writing, software
|
![https://opencollective.com/sous-chefs#backers](https://opencollective.com/sous-chefs/backers.svg?width=600&avatarHeight=40)
|
||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
### Sponsors
|
||||||
See the License for the specific language governing permissions and
|
|
||||||
limitations under the License.
|
Support this project by becoming a sponsor. Your logo will show up here with a link to your website.
|
||||||
```
|
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/0/website](https://opencollective.com/sous-chefs/sponsor/0/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/1/website](https://opencollective.com/sous-chefs/sponsor/1/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/2/website](https://opencollective.com/sous-chefs/sponsor/2/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/3/website](https://opencollective.com/sous-chefs/sponsor/3/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/4/website](https://opencollective.com/sous-chefs/sponsor/4/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/5/website](https://opencollective.com/sous-chefs/sponsor/5/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/6/website](https://opencollective.com/sous-chefs/sponsor/6/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/7/website](https://opencollective.com/sous-chefs/sponsor/7/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/8/website](https://opencollective.com/sous-chefs/sponsor/8/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/9/website](https://opencollective.com/sous-chefs/sponsor/9/avatar.svg?avatarHeight=100)
|
||||||
|
|
|
@ -31,7 +31,7 @@ pkgs = %w(libtool autoconf) unless platform_family?('mac_os_x')
|
||||||
pkgs += %w(make) unless platform_family?('mac_os_x', 'freebsd')
|
pkgs += %w(make) unless platform_family?('mac_os_x', 'freebsd')
|
||||||
pkgs += %w(unzip rsync gcc) unless platform_family?('mac_os_x')
|
pkgs += %w(unzip rsync gcc) unless platform_family?('mac_os_x')
|
||||||
pkgs += %w(autogen) unless platform_family?('rhel', 'fedora', 'mac_os_x', 'suse', 'amazon')
|
pkgs += %w(autogen) unless platform_family?('rhel', 'fedora', 'mac_os_x', 'suse', 'amazon')
|
||||||
pkgs += %w(gtar) if platform?('freebsd') || platform?('smartos')
|
pkgs += %w(gtar) if platform?('freebsd', 'smartos')
|
||||||
pkgs += %w(gmake) if platform?('freebsd')
|
pkgs += %w(gmake) if platform?('freebsd')
|
||||||
if platform_family?('rhel', 'suse', 'amazon')
|
if platform_family?('rhel', 'suse', 'amazon')
|
||||||
if node['platform_version'].to_i >= 7
|
if node['platform_version'].to_i >= 7
|
||||||
|
|
|
@ -0,0 +1,115 @@
|
||||||
|
# Put files/directories that should be ignored in this file when uploading
|
||||||
|
# to a Chef Infra Server or Supermarket.
|
||||||
|
# Lines that start with '# ' are comments.
|
||||||
|
|
||||||
|
# OS generated files #
|
||||||
|
######################
|
||||||
|
.DS_Store
|
||||||
|
ehthumbs.db
|
||||||
|
Icon?
|
||||||
|
nohup.out
|
||||||
|
Thumbs.db
|
||||||
|
.envrc
|
||||||
|
|
||||||
|
# EDITORS #
|
||||||
|
###########
|
||||||
|
.#*
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
*_flymake
|
||||||
|
*_flymake.*
|
||||||
|
*.bak
|
||||||
|
*.sw[a-z]
|
||||||
|
*.tmproj
|
||||||
|
*~
|
||||||
|
\#*
|
||||||
|
REVISION
|
||||||
|
TAGS*
|
||||||
|
tmtags
|
||||||
|
.vscode
|
||||||
|
.editorconfig
|
||||||
|
|
||||||
|
## COMPILED ##
|
||||||
|
##############
|
||||||
|
*.class
|
||||||
|
*.com
|
||||||
|
*.dll
|
||||||
|
*.exe
|
||||||
|
*.o
|
||||||
|
*.pyc
|
||||||
|
*.so
|
||||||
|
*/rdoc/
|
||||||
|
a.out
|
||||||
|
mkmf.log
|
||||||
|
|
||||||
|
# Testing #
|
||||||
|
###########
|
||||||
|
.circleci/*
|
||||||
|
.codeclimate.yml
|
||||||
|
.delivery/*
|
||||||
|
.foodcritic
|
||||||
|
.kitchen*
|
||||||
|
.mdlrc
|
||||||
|
.overcommit.yml
|
||||||
|
.rspec
|
||||||
|
.rubocop.yml
|
||||||
|
.travis.yml
|
||||||
|
.watchr
|
||||||
|
.yamllint
|
||||||
|
azure-pipelines.yml
|
||||||
|
Dangerfile
|
||||||
|
examples/*
|
||||||
|
features/*
|
||||||
|
Guardfile
|
||||||
|
kitchen.yml*
|
||||||
|
mlc_config.json
|
||||||
|
Procfile
|
||||||
|
Rakefile
|
||||||
|
spec/*
|
||||||
|
test/*
|
||||||
|
|
||||||
|
# SCM #
|
||||||
|
#######
|
||||||
|
.git
|
||||||
|
.gitattributes
|
||||||
|
.gitconfig
|
||||||
|
.github/*
|
||||||
|
.gitignore
|
||||||
|
.gitkeep
|
||||||
|
.gitmodules
|
||||||
|
.svn
|
||||||
|
*/.bzr/*
|
||||||
|
*/.git
|
||||||
|
*/.hg/*
|
||||||
|
*/.svn/*
|
||||||
|
|
||||||
|
# Berkshelf #
|
||||||
|
#############
|
||||||
|
Berksfile
|
||||||
|
Berksfile.lock
|
||||||
|
cookbooks/*
|
||||||
|
tmp
|
||||||
|
|
||||||
|
# Bundler #
|
||||||
|
###########
|
||||||
|
vendor/*
|
||||||
|
Gemfile
|
||||||
|
Gemfile.lock
|
||||||
|
|
||||||
|
# Policyfile #
|
||||||
|
##############
|
||||||
|
Policyfile.rb
|
||||||
|
Policyfile.lock.json
|
||||||
|
|
||||||
|
# Documentation #
|
||||||
|
#############
|
||||||
|
CODE_OF_CONDUCT*
|
||||||
|
CONTRIBUTING*
|
||||||
|
documentation/*
|
||||||
|
TESTING*
|
||||||
|
UPGRADING*
|
||||||
|
|
||||||
|
# Vagrant #
|
||||||
|
###########
|
||||||
|
.vagrant
|
||||||
|
Vagrantfile
|
|
@ -0,0 +1,65 @@
|
||||||
|
driver:
|
||||||
|
name: dokken
|
||||||
|
privileged: true # because Docker and SystemD
|
||||||
|
chef_version: <%= ENV['CHEF_VERSION'] || 'current' %>
|
||||||
|
chef_license: accept-no-persist
|
||||||
|
|
||||||
|
transport:
|
||||||
|
name: dokken
|
||||||
|
|
||||||
|
provisioner:
|
||||||
|
name: dokken
|
||||||
|
|
||||||
|
platforms:
|
||||||
|
- name: amazonlinux-2
|
||||||
|
driver:
|
||||||
|
image: dokken/amazonlinux-2
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: debian-9
|
||||||
|
driver:
|
||||||
|
image: dokken/debian-9
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: debian-10
|
||||||
|
driver:
|
||||||
|
image: dokken/debian-10
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: centos-7
|
||||||
|
driver:
|
||||||
|
image: dokken/centos-7
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: centos-8
|
||||||
|
driver:
|
||||||
|
image: dokken/centos-8
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: fedora-latest
|
||||||
|
driver:
|
||||||
|
image: dokken/fedora-latest
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: ubuntu-18.04
|
||||||
|
driver:
|
||||||
|
image: dokken/ubuntu-18.04
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: ubuntu-20.04
|
||||||
|
driver:
|
||||||
|
image: dokken/ubuntu-20.04
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: opensuse-leap-15
|
||||||
|
driver:
|
||||||
|
image: dokken/opensuse-leap-15
|
||||||
|
pid_one_command: /bin/systemd
|
|
@ -0,0 +1,14 @@
|
||||||
|
---
|
||||||
|
driver:
|
||||||
|
name: exec
|
||||||
|
|
||||||
|
transport:
|
||||||
|
name: exec
|
||||||
|
|
||||||
|
provisioner:
|
||||||
|
name: chef_zero
|
||||||
|
deprecations_as_errors: true
|
||||||
|
|
||||||
|
platforms:
|
||||||
|
- name: windows-latest
|
||||||
|
- name: macos-latest
|
|
@ -104,7 +104,7 @@ module Ark
|
||||||
def wmi_property_from_query(wmi_property, wmi_query)
|
def wmi_property_from_query(wmi_property, wmi_query)
|
||||||
@wmi = ::WIN32OLE.connect('winmgmts://')
|
@wmi = ::WIN32OLE.connect('winmgmts://')
|
||||||
result = @wmi.ExecQuery(wmi_query)
|
result = @wmi.ExecQuery(wmi_query)
|
||||||
return nil unless result.each.count > 0
|
return unless result.each.count > 0
|
||||||
result.each.next.send(wmi_property)
|
result.each.next.send(wmi_property)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,7 @@ module Ark
|
||||||
end
|
end
|
||||||
|
|
||||||
def sevenzip_binary
|
def sevenzip_binary
|
||||||
@tar_binary ||= "\"#{(node['ark']['sevenzip_binary'] || sevenzip_path_from_registry)}\""
|
@tar_binary ||= "\"#{node['ark']['sevenzip_binary'] || sevenzip_path_from_registry}\""
|
||||||
end
|
end
|
||||||
|
|
||||||
def sevenzip_path_from_registry
|
def sevenzip_path_from_registry
|
||||||
|
|
|
@ -9,7 +9,7 @@ module Ark
|
||||||
end
|
end
|
||||||
|
|
||||||
def cherry_pick
|
def cherry_pick
|
||||||
"#{tar_binary} #{args} #{resource.release_file} -C #{resource.path} #{resource.creates}#{strip_args}"
|
"#{tar_binary} #{args} #{resource.release_file} -C #{resource.path}#{strip_args} #{resource.creates}"
|
||||||
end
|
end
|
||||||
|
|
||||||
def initialize(resource)
|
def initialize(resource)
|
||||||
|
|
|
@ -1 +1,49 @@
|
||||||
{"name":"ark","version":"5.0.0","description":"Provides a custom resource for installing runtime artifacts in a predictable fashion","long_description":"","maintainer":"Chef Software, Inc.","maintainer_email":"cookbooks@chef.io","license":"Apache-2.0","platforms":{"ubuntu":">= 0.0.0","debian":">= 0.0.0","redhat":">= 0.0.0","centos":">= 0.0.0","suse":">= 0.0.0","opensuse":">= 0.0.0","opensuseleap":">= 0.0.0","scientific":">= 0.0.0","oracle":">= 0.0.0","amazon":">= 0.0.0","windows":">= 0.0.0","mac_os_x":">= 0.0.0","smartos":">= 0.0.0","freebsd":">= 0.0.0"},"dependencies":{"seven_zip":">= 0.0.0"},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/chef-cookbooks/ark","issues_url":"https://github.com/chef-cookbooks/ark/issues","chef_version":[[">= 14.0"]],"ohai_version":[]}
|
{
|
||||||
|
"name": "ark",
|
||||||
|
"description": "Provides a custom resource for installing runtime artifacts in a predictable fashion",
|
||||||
|
"long_description": "",
|
||||||
|
"maintainer": "Sous Chefs",
|
||||||
|
"maintainer_email": "help@sous-chefs.org",
|
||||||
|
"license": "Apache-2.0",
|
||||||
|
"platforms": {
|
||||||
|
"amazon": ">= 0.0.0",
|
||||||
|
"centos": ">= 0.0.0",
|
||||||
|
"debian": ">= 0.0.0",
|
||||||
|
"freebsd": ">= 0.0.0",
|
||||||
|
"mac_os_x": ">= 0.0.0",
|
||||||
|
"opensuse": ">= 0.0.0",
|
||||||
|
"opensuseleap": ">= 0.0.0",
|
||||||
|
"oracle": ">= 0.0.0",
|
||||||
|
"redhat": ">= 0.0.0",
|
||||||
|
"scientific": ">= 0.0.0",
|
||||||
|
"smartos": ">= 0.0.0",
|
||||||
|
"suse": ">= 0.0.0",
|
||||||
|
"ubuntu": ">= 0.0.0",
|
||||||
|
"windows": ">= 0.0.0"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"seven_zip": ">= 3.1"
|
||||||
|
},
|
||||||
|
"providing": {
|
||||||
|
|
||||||
|
},
|
||||||
|
"recipes": {
|
||||||
|
|
||||||
|
},
|
||||||
|
"version": "6.0.3",
|
||||||
|
"source_url": "https://github.com/sous-chefs/ark",
|
||||||
|
"issues_url": "https://github.com/sous-chefs/ark/issues",
|
||||||
|
"privacy": false,
|
||||||
|
"chef_versions": [
|
||||||
|
[
|
||||||
|
">= 15.3"
|
||||||
|
]
|
||||||
|
],
|
||||||
|
"ohai_versions": [
|
||||||
|
|
||||||
|
],
|
||||||
|
"gems": [
|
||||||
|
|
||||||
|
],
|
||||||
|
"eager_load_libraries": true
|
||||||
|
}
|
||||||
|
|
|
@ -1,16 +1,26 @@
|
||||||
name 'ark'
|
name 'ark'
|
||||||
maintainer 'Chef Software, Inc.'
|
maintainer 'Sous Chefs'
|
||||||
maintainer_email 'cookbooks@chef.io'
|
maintainer_email 'help@sous-chefs.org'
|
||||||
license 'Apache-2.0'
|
license 'Apache-2.0'
|
||||||
description 'Provides a custom resource for installing runtime artifacts in a predictable fashion'
|
description 'Provides a custom resource for installing runtime artifacts in a predictable fashion'
|
||||||
version '5.0.0'
|
version '6.0.3'
|
||||||
|
source_url 'https://github.com/sous-chefs/ark'
|
||||||
|
issues_url 'https://github.com/sous-chefs/ark/issues'
|
||||||
|
chef_version '>= 15.3'
|
||||||
|
|
||||||
%w(ubuntu debian redhat centos suse opensuse opensuseleap scientific oracle amazon windows mac_os_x smartos freebsd).each do |os|
|
supports 'amazon'
|
||||||
supports os
|
supports 'centos'
|
||||||
end
|
supports 'debian'
|
||||||
|
supports 'freebsd'
|
||||||
|
supports 'mac_os_x'
|
||||||
|
supports 'opensuse'
|
||||||
|
supports 'opensuseleap'
|
||||||
|
supports 'oracle'
|
||||||
|
supports 'redhat'
|
||||||
|
supports 'scientific'
|
||||||
|
supports 'smartos'
|
||||||
|
supports 'suse'
|
||||||
|
supports 'ubuntu'
|
||||||
|
supports 'windows'
|
||||||
|
|
||||||
depends 'seven_zip' # for windows os
|
depends 'seven_zip', '>= 3.1' # for windows os
|
||||||
|
|
||||||
source_url 'https://github.com/chef-cookbooks/ark'
|
|
||||||
issues_url 'https://github.com/chef-cookbooks/ark/issues'
|
|
||||||
chef_version '>= 14.0'
|
|
||||||
|
|
|
@ -20,4 +20,4 @@
|
||||||
|
|
||||||
package node['ark']['package_dependencies'] unless platform_family?('windows', 'mac_os_x')
|
package node['ark']['package_dependencies'] unless platform_family?('windows', 'mac_os_x')
|
||||||
|
|
||||||
include_recipe 'seven_zip' if platform_family?('windows')
|
seven_zip_tool 'ark' if platform_family?('windows')
|
||||||
|
|
|
@ -25,7 +25,7 @@ property :url, String, required: true
|
||||||
property :path, String
|
property :path, String
|
||||||
property :full_path, String
|
property :full_path, String
|
||||||
property :append_env_path, [true, false], default: false
|
property :append_env_path, [true, false], default: false
|
||||||
property :checksum, regex: /^[a-zA-Z0-9]{64}$/, default: nil
|
property :checksum, String, regex: /^[a-zA-Z0-9]{64}$/
|
||||||
property :has_binaries, Array, default: []
|
property :has_binaries, Array, default: []
|
||||||
property :creates, String
|
property :creates, String
|
||||||
property :release_file, String, default: ''
|
property :release_file, String, default: ''
|
||||||
|
@ -46,6 +46,8 @@ property :autoconf_opts, Array, default: []
|
||||||
property :extension, String
|
property :extension, String
|
||||||
property :backup, [FalseClass, Integer], default: 5
|
property :backup, [FalseClass, Integer], default: 5
|
||||||
|
|
||||||
|
unified_mode true
|
||||||
|
|
||||||
#################
|
#################
|
||||||
# action :install
|
# action :install
|
||||||
#################
|
#################
|
||||||
|
@ -105,6 +107,9 @@ action :install do
|
||||||
to new_resource.path
|
to new_resource.path
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# This directory doesn't exist by default on MacOS
|
||||||
|
directory '/etc/profile.d' if platform_family?('mac_os_x')
|
||||||
|
|
||||||
# Add to path for interactive bash sessions
|
# Add to path for interactive bash sessions
|
||||||
template "/etc/profile.d/#{new_resource.name}.sh" do
|
template "/etc/profile.d/#{new_resource.name}.sh" do
|
||||||
cookbook 'ark'
|
cookbook 'ark'
|
||||||
|
|
|
@ -2,6 +2,36 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of golang.
|
This file is used to list changes made in each version of golang.
|
||||||
|
|
||||||
|
## 5.3.1 - *2021-08-30*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 5.3.0 - *2021-07-15*
|
||||||
|
|
||||||
|
- Fix `unified_mode` declaration
|
||||||
|
- Bump `ark` dependency to one with `unified_mode` set
|
||||||
|
|
||||||
|
## 5.2.0 - *2021-06-04*
|
||||||
|
|
||||||
|
- Update example package to adhere with modern Go standards
|
||||||
|
|
||||||
|
## 5.1.0 - *2021-06-03*
|
||||||
|
|
||||||
|
- Fix resource to use the correct path in GOPATH profile.d template
|
||||||
|
|
||||||
|
## 5.0.1 - *2021-06-01*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 5.0.0 - *2021-05-21*
|
||||||
|
|
||||||
|
- Require chef 15.3 or greater
|
||||||
|
- Use unified_mode for chef 17 support
|
||||||
|
|
||||||
|
## 4.1.1 - *2021-02-03*
|
||||||
|
|
||||||
|
- Use `node['golang']['scm']` and `node['golang']['scm_packages']` attributes in default recipe.
|
||||||
|
|
||||||
## 4.1.0
|
## 4.1.0
|
||||||
|
|
||||||
- Create a custom resource to install Go from source or by downloading a package
|
- Create a custom resource to install Go from source or by downloading a package
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
# 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)
|
|
|
@ -0,0 +1,201 @@
|
||||||
|
Apache License
|
||||||
|
Version 2.0, January 2004
|
||||||
|
http://www.apache.org/licenses/
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||||
|
|
||||||
|
1. Definitions.
|
||||||
|
|
||||||
|
"License" shall mean the terms and conditions for use, reproduction,
|
||||||
|
and distribution as defined by Sections 1 through 9 of this document.
|
||||||
|
|
||||||
|
"Licensor" shall mean the copyright owner or entity authorized by
|
||||||
|
the copyright owner that is granting the License.
|
||||||
|
|
||||||
|
"Legal Entity" shall mean the union of the acting entity and all
|
||||||
|
other entities that control, are controlled by, or are under common
|
||||||
|
control with that entity. For the purposes of this definition,
|
||||||
|
"control" means (i) the power, direct or indirect, to cause the
|
||||||
|
direction or management of such entity, whether by contract or
|
||||||
|
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||||
|
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||||
|
|
||||||
|
"You" (or "Your") shall mean an individual or Legal Entity
|
||||||
|
exercising permissions granted by this License.
|
||||||
|
|
||||||
|
"Source" form shall mean the preferred form for making modifications,
|
||||||
|
including but not limited to software source code, documentation
|
||||||
|
source, and configuration files.
|
||||||
|
|
||||||
|
"Object" form shall mean any form resulting from mechanical
|
||||||
|
transformation or translation of a Source form, including but
|
||||||
|
not limited to compiled object code, generated documentation,
|
||||||
|
and conversions to other media types.
|
||||||
|
|
||||||
|
"Work" shall mean the work of authorship, whether in Source or
|
||||||
|
Object form, made available under the License, as indicated by a
|
||||||
|
copyright notice that is included in or attached to the work
|
||||||
|
(an example is provided in the Appendix below).
|
||||||
|
|
||||||
|
"Derivative Works" shall mean any work, whether in Source or Object
|
||||||
|
form, that is based on (or derived from) the Work and for which the
|
||||||
|
editorial revisions, annotations, elaborations, or other modifications
|
||||||
|
represent, as a whole, an original work of authorship. For the purposes
|
||||||
|
of this License, Derivative Works shall not include works that remain
|
||||||
|
separable from, or merely link (or bind by name) to the interfaces of,
|
||||||
|
the Work and Derivative Works thereof.
|
||||||
|
|
||||||
|
"Contribution" shall mean any work of authorship, including
|
||||||
|
the original version of the Work and any modifications or additions
|
||||||
|
to that Work or Derivative Works thereof, that is intentionally
|
||||||
|
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||||
|
or by an individual or Legal Entity authorized to submit on behalf of
|
||||||
|
the copyright owner. For the purposes of this definition, "submitted"
|
||||||
|
means any form of electronic, verbal, or written communication sent
|
||||||
|
to the Licensor or its representatives, including but not limited to
|
||||||
|
communication on electronic mailing lists, source code control systems,
|
||||||
|
and issue tracking systems that are managed by, or on behalf of, the
|
||||||
|
Licensor for the purpose of discussing and improving the Work, but
|
||||||
|
excluding communication that is conspicuously marked or otherwise
|
||||||
|
designated in writing by the copyright owner as "Not a Contribution."
|
||||||
|
|
||||||
|
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||||
|
on behalf of whom a Contribution has been received by Licensor and
|
||||||
|
subsequently incorporated within the Work.
|
||||||
|
|
||||||
|
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
copyright license to reproduce, prepare Derivative Works of,
|
||||||
|
publicly display, publicly perform, sublicense, and distribute the
|
||||||
|
Work and such Derivative Works in Source or Object form.
|
||||||
|
|
||||||
|
3. Grant of Patent License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
(except as stated in this section) patent license to make, have made,
|
||||||
|
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||||
|
where such license applies only to those patent claims licensable
|
||||||
|
by such Contributor that are necessarily infringed by their
|
||||||
|
Contribution(s) alone or by combination of their Contribution(s)
|
||||||
|
with the Work to which such Contribution(s) was submitted. If You
|
||||||
|
institute patent litigation against any entity (including a
|
||||||
|
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||||
|
or a Contribution incorporated within the Work constitutes direct
|
||||||
|
or contributory patent infringement, then any patent licenses
|
||||||
|
granted to You under this License for that Work shall terminate
|
||||||
|
as of the date such litigation is filed.
|
||||||
|
|
||||||
|
4. Redistribution. You may reproduce and distribute copies of the
|
||||||
|
Work or Derivative Works thereof in any medium, with or without
|
||||||
|
modifications, and in Source or Object form, provided that You
|
||||||
|
meet the following conditions:
|
||||||
|
|
||||||
|
(a) You must give any other recipients of the Work or
|
||||||
|
Derivative Works a copy of this License; and
|
||||||
|
|
||||||
|
(b) You must cause any modified files to carry prominent notices
|
||||||
|
stating that You changed the files; and
|
||||||
|
|
||||||
|
(c) You must retain, in the Source form of any Derivative Works
|
||||||
|
that You distribute, all copyright, patent, trademark, and
|
||||||
|
attribution notices from the Source form of the Work,
|
||||||
|
excluding those notices that do not pertain to any part of
|
||||||
|
the Derivative Works; and
|
||||||
|
|
||||||
|
(d) If the Work includes a "NOTICE" text file as part of its
|
||||||
|
distribution, then any Derivative Works that You distribute must
|
||||||
|
include a readable copy of the attribution notices contained
|
||||||
|
within such NOTICE file, excluding those notices that do not
|
||||||
|
pertain to any part of the Derivative Works, in at least one
|
||||||
|
of the following places: within a NOTICE text file distributed
|
||||||
|
as part of the Derivative Works; within the Source form or
|
||||||
|
documentation, if provided along with the Derivative Works; or,
|
||||||
|
within a display generated by the Derivative Works, if and
|
||||||
|
wherever such third-party notices normally appear. The contents
|
||||||
|
of the NOTICE file are for informational purposes only and
|
||||||
|
do not modify the License. You may add Your own attribution
|
||||||
|
notices within Derivative Works that You distribute, alongside
|
||||||
|
or as an addendum to the NOTICE text from the Work, provided
|
||||||
|
that such additional attribution notices cannot be construed
|
||||||
|
as modifying the License.
|
||||||
|
|
||||||
|
You may add Your own copyright statement to Your modifications and
|
||||||
|
may provide additional or different license terms and conditions
|
||||||
|
for use, reproduction, or distribution of Your modifications, or
|
||||||
|
for any such Derivative Works as a whole, provided Your use,
|
||||||
|
reproduction, and distribution of the Work otherwise complies with
|
||||||
|
the conditions stated in this License.
|
||||||
|
|
||||||
|
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||||
|
any Contribution intentionally submitted for inclusion in the Work
|
||||||
|
by You to the Licensor shall be under the terms and conditions of
|
||||||
|
this License, without any additional terms or conditions.
|
||||||
|
Notwithstanding the above, nothing herein shall supersede or modify
|
||||||
|
the terms of any separate license agreement you may have executed
|
||||||
|
with Licensor regarding such Contributions.
|
||||||
|
|
||||||
|
6. Trademarks. This License does not grant permission to use the trade
|
||||||
|
names, trademarks, service marks, or product names of the Licensor,
|
||||||
|
except as required for reasonable and customary use in describing the
|
||||||
|
origin of the Work and reproducing the content of the NOTICE file.
|
||||||
|
|
||||||
|
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||||
|
agreed to in writing, Licensor provides the Work (and each
|
||||||
|
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||||
|
implied, including, without limitation, any warranties or conditions
|
||||||
|
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||||
|
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||||
|
appropriateness of using or redistributing the Work and assume any
|
||||||
|
risks associated with Your exercise of permissions under this License.
|
||||||
|
|
||||||
|
8. Limitation of Liability. In no event and under no legal theory,
|
||||||
|
whether in tort (including negligence), contract, or otherwise,
|
||||||
|
unless required by applicable law (such as deliberate and grossly
|
||||||
|
negligent acts) or agreed to in writing, shall any Contributor be
|
||||||
|
liable to You for damages, including any direct, indirect, special,
|
||||||
|
incidental, or consequential damages of any character arising as a
|
||||||
|
result of this License or out of the use or inability to use the
|
||||||
|
Work (including but not limited to damages for loss of goodwill,
|
||||||
|
work stoppage, computer failure or malfunction, or any and all
|
||||||
|
other commercial damages or losses), even if such Contributor
|
||||||
|
has been advised of the possibility of such damages.
|
||||||
|
|
||||||
|
9. Accepting Warranty or Additional Liability. While redistributing
|
||||||
|
the Work or Derivative Works thereof, You may choose to offer,
|
||||||
|
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||||
|
or other liability obligations and/or rights consistent with this
|
||||||
|
License. However, in accepting such obligations, You may act only
|
||||||
|
on Your own behalf and on Your sole responsibility, not on behalf
|
||||||
|
of any other Contributor, and only if You agree to indemnify,
|
||||||
|
defend, and hold each Contributor harmless for any liability
|
||||||
|
incurred by, or claims asserted against, such Contributor by reason
|
||||||
|
of your accepting any such warranty or additional liability.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
APPENDIX: How to apply the Apache License to your work.
|
||||||
|
|
||||||
|
To apply the Apache License to your work, attach the following
|
||||||
|
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||||
|
replaced with your own identifying information. (Don't include
|
||||||
|
the brackets!) The text should be enclosed in the appropriate
|
||||||
|
comment syntax for the file format. We also recommend that a
|
||||||
|
file or class name and description of purpose be included on the
|
||||||
|
same "printed page" as the copyright notice for easier
|
||||||
|
identification within third-party archives.
|
||||||
|
|
||||||
|
Copyright [yyyy] [name of copyright owner]
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
|
@ -0,0 +1,115 @@
|
||||||
|
# Put files/directories that should be ignored in this file when uploading
|
||||||
|
# to a Chef Infra Server or Supermarket.
|
||||||
|
# Lines that start with '# ' are comments.
|
||||||
|
|
||||||
|
# OS generated files #
|
||||||
|
######################
|
||||||
|
.DS_Store
|
||||||
|
ehthumbs.db
|
||||||
|
Icon?
|
||||||
|
nohup.out
|
||||||
|
Thumbs.db
|
||||||
|
.envrc
|
||||||
|
|
||||||
|
# EDITORS #
|
||||||
|
###########
|
||||||
|
.#*
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
*_flymake
|
||||||
|
*_flymake.*
|
||||||
|
*.bak
|
||||||
|
*.sw[a-z]
|
||||||
|
*.tmproj
|
||||||
|
*~
|
||||||
|
\#*
|
||||||
|
REVISION
|
||||||
|
TAGS*
|
||||||
|
tmtags
|
||||||
|
.vscode
|
||||||
|
.editorconfig
|
||||||
|
|
||||||
|
## COMPILED ##
|
||||||
|
##############
|
||||||
|
*.class
|
||||||
|
*.com
|
||||||
|
*.dll
|
||||||
|
*.exe
|
||||||
|
*.o
|
||||||
|
*.pyc
|
||||||
|
*.so
|
||||||
|
*/rdoc/
|
||||||
|
a.out
|
||||||
|
mkmf.log
|
||||||
|
|
||||||
|
# Testing #
|
||||||
|
###########
|
||||||
|
.circleci/*
|
||||||
|
.codeclimate.yml
|
||||||
|
.delivery/*
|
||||||
|
.foodcritic
|
||||||
|
.kitchen*
|
||||||
|
.mdlrc
|
||||||
|
.overcommit.yml
|
||||||
|
.rspec
|
||||||
|
.rubocop.yml
|
||||||
|
.travis.yml
|
||||||
|
.watchr
|
||||||
|
.yamllint
|
||||||
|
azure-pipelines.yml
|
||||||
|
Dangerfile
|
||||||
|
examples/*
|
||||||
|
features/*
|
||||||
|
Guardfile
|
||||||
|
kitchen.yml*
|
||||||
|
mlc_config.json
|
||||||
|
Procfile
|
||||||
|
Rakefile
|
||||||
|
spec/*
|
||||||
|
test/*
|
||||||
|
|
||||||
|
# SCM #
|
||||||
|
#######
|
||||||
|
.git
|
||||||
|
.gitattributes
|
||||||
|
.gitconfig
|
||||||
|
.github/*
|
||||||
|
.gitignore
|
||||||
|
.gitkeep
|
||||||
|
.gitmodules
|
||||||
|
.svn
|
||||||
|
*/.bzr/*
|
||||||
|
*/.git
|
||||||
|
*/.hg/*
|
||||||
|
*/.svn/*
|
||||||
|
|
||||||
|
# Berkshelf #
|
||||||
|
#############
|
||||||
|
Berksfile
|
||||||
|
Berksfile.lock
|
||||||
|
cookbooks/*
|
||||||
|
tmp
|
||||||
|
|
||||||
|
# Bundler #
|
||||||
|
###########
|
||||||
|
vendor/*
|
||||||
|
Gemfile
|
||||||
|
Gemfile.lock
|
||||||
|
|
||||||
|
# Policyfile #
|
||||||
|
##############
|
||||||
|
Policyfile.rb
|
||||||
|
Policyfile.lock.json
|
||||||
|
|
||||||
|
# Documentation #
|
||||||
|
#############
|
||||||
|
CODE_OF_CONDUCT*
|
||||||
|
CONTRIBUTING*
|
||||||
|
documentation/*
|
||||||
|
TESTING*
|
||||||
|
UPGRADING*
|
||||||
|
|
||||||
|
# Vagrant #
|
||||||
|
###########
|
||||||
|
.vagrant
|
||||||
|
Vagrantfile
|
|
@ -0,0 +1,55 @@
|
||||||
|
---
|
||||||
|
driver:
|
||||||
|
name: dokken
|
||||||
|
privileged: true
|
||||||
|
|
||||||
|
transport:
|
||||||
|
name: dokken
|
||||||
|
|
||||||
|
provisioner:
|
||||||
|
name: dokken
|
||||||
|
product_name: chef
|
||||||
|
product_version: <%= ENV['CHEF_VERSION'] || 'latest' %>
|
||||||
|
chef_license: accept-no-persist
|
||||||
|
install_strategy: once
|
||||||
|
|
||||||
|
platforms:
|
||||||
|
- name: debian-9
|
||||||
|
driver:
|
||||||
|
image: dokken/debian-9
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: debian-10
|
||||||
|
driver:
|
||||||
|
image: dokken/debian-10
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: centos-7
|
||||||
|
driver:
|
||||||
|
image: dokken/centos-7
|
||||||
|
platform: rhel
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: centos-8
|
||||||
|
driver:
|
||||||
|
image: dokken/centos-8
|
||||||
|
platform: rhel
|
||||||
|
pid_one_command: /usr/lib/systemd/systemd
|
||||||
|
|
||||||
|
- name: ubuntu-18.04
|
||||||
|
driver:
|
||||||
|
image: dokken/ubuntu-18.04
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
||||||
|
|
||||||
|
- name: ubuntu-20.04
|
||||||
|
driver:
|
||||||
|
image: dokken/ubuntu-18.04
|
||||||
|
pid_one_command: /bin/systemd
|
||||||
|
intermediate_instructions:
|
||||||
|
- RUN /usr/bin/apt-get update
|
|
@ -1 +1,43 @@
|
||||||
{"name":"golang","version":"4.1.0","description":"Installs go programming language","long_description":"","maintainer":"Sous Chefs","maintainer_email":"help@sous-chefs.org","license":"Apache-2.0","platforms":{"debian":">= 0.0.0","ubuntu":">= 0.0.0","redhat":">= 0.0.0","centos":">= 0.0.0","fedora":">= 0.0.0","amazon":">= 0.0.0","scientific":">= 0.0.0","oracle":">= 0.0.0"},"dependencies":{"ark":"~> 5.0"},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/sous-chefs/golang","issues_url":"https://github.com/sous-chefs/golang/issues","chef_version":[[">= 14.0"]],"ohai_version":[]}
|
{
|
||||||
|
"name": "golang",
|
||||||
|
"description": "Installs go programming language",
|
||||||
|
"long_description": "",
|
||||||
|
"maintainer": "Sous Chefs",
|
||||||
|
"maintainer_email": "help@sous-chefs.org",
|
||||||
|
"license": "Apache-2.0",
|
||||||
|
"platforms": {
|
||||||
|
"debian": ">= 0.0.0",
|
||||||
|
"ubuntu": ">= 0.0.0",
|
||||||
|
"redhat": ">= 0.0.0",
|
||||||
|
"centos": ">= 0.0.0",
|
||||||
|
"fedora": ">= 0.0.0",
|
||||||
|
"amazon": ">= 0.0.0",
|
||||||
|
"scientific": ">= 0.0.0",
|
||||||
|
"oracle": ">= 0.0.0"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"ark": ">= 6.0"
|
||||||
|
},
|
||||||
|
"providing": {
|
||||||
|
|
||||||
|
},
|
||||||
|
"recipes": {
|
||||||
|
|
||||||
|
},
|
||||||
|
"version": "5.3.1",
|
||||||
|
"source_url": "https://github.com/sous-chefs/golang",
|
||||||
|
"issues_url": "https://github.com/sous-chefs/golang/issues",
|
||||||
|
"privacy": false,
|
||||||
|
"chef_versions": [
|
||||||
|
[
|
||||||
|
">= 15.3"
|
||||||
|
]
|
||||||
|
],
|
||||||
|
"ohai_versions": [
|
||||||
|
|
||||||
|
],
|
||||||
|
"gems": [
|
||||||
|
|
||||||
|
],
|
||||||
|
"eager_load_libraries": true
|
||||||
|
}
|
||||||
|
|
|
@ -5,8 +5,8 @@ license 'Apache-2.0'
|
||||||
description 'Installs go programming language'
|
description 'Installs go programming language'
|
||||||
source_url 'https://github.com/sous-chefs/golang'
|
source_url 'https://github.com/sous-chefs/golang'
|
||||||
issues_url 'https://github.com/sous-chefs/golang/issues'
|
issues_url 'https://github.com/sous-chefs/golang/issues'
|
||||||
chef_version '>= 14.0'
|
chef_version '>= 15.3'
|
||||||
version '4.1.0'
|
version '5.3.1'
|
||||||
|
|
||||||
supports 'debian'
|
supports 'debian'
|
||||||
supports 'ubuntu'
|
supports 'ubuntu'
|
||||||
|
@ -17,4 +17,4 @@ supports 'amazon'
|
||||||
supports 'scientific'
|
supports 'scientific'
|
||||||
supports 'oracle'
|
supports 'oracle'
|
||||||
|
|
||||||
depends 'ark', '~> 5.0'
|
depends 'ark', '>= 6.0'
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: golang
|
# Cookbook:: golang
|
||||||
# Recipe:: default
|
# Recipe:: default
|
||||||
#
|
#
|
||||||
# Copyright:: 2013, Alexander Rozhnov
|
# Copyright:: 2013-2021, Alexander Rozhnov
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
||||||
# use this file except in compliance with the License. You may obtain a copy
|
# use this file except in compliance with the License. You may obtain a copy
|
||||||
|
@ -21,6 +21,8 @@ golang 'Install go' do
|
||||||
from_source node['golang']['from_source']
|
from_source node['golang']['from_source']
|
||||||
version node['golang']['version'] if node['golang']['version'] # go version
|
version node['golang']['version'] if node['golang']['version'] # go version
|
||||||
source_version node['golang']['source_version'] if node['golang']['source_version'] # go version from source
|
source_version node['golang']['source_version'] if node['golang']['source_version'] # go version from source
|
||||||
|
scm node['golang']['scm']
|
||||||
|
scm_packages node['golang']['scm_packages']
|
||||||
owner node['golang']['owner'] if node['golang']['owner']
|
owner node['golang']['owner'] if node['golang']['owner']
|
||||||
group node['golang']['group'] if node['golang']['group']
|
group node['golang']['group'] if node['golang']['group']
|
||||||
end
|
end
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: golang
|
# Cookbook:: golang
|
||||||
# Resource:: default
|
# Resource:: default
|
||||||
#
|
#
|
||||||
# Copyright:: 2020, Sous-chefs
|
# Copyright:: 2020-2021, Sous-chefs
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
||||||
# use this file except in compliance with the License. You may obtain a copy
|
# use this file except in compliance with the License. You may obtain a copy
|
||||||
|
@ -17,6 +17,8 @@
|
||||||
# under the License.
|
# under the License.
|
||||||
#
|
#
|
||||||
|
|
||||||
|
unified_mode true
|
||||||
|
|
||||||
# Install golang by compiling from source
|
# Install golang by compiling from source
|
||||||
property :from_source, [true, false], default: false
|
property :from_source, [true, false], default: false
|
||||||
|
|
||||||
|
@ -99,7 +101,7 @@ action :install do
|
||||||
source 'golang.sh.erb'
|
source 'golang.sh.erb'
|
||||||
mode new_resource.directory_mode
|
mode new_resource.directory_mode
|
||||||
variables gobin: new_resource.gobin,
|
variables gobin: new_resource.gobin,
|
||||||
gopath: new_resource.gobin,
|
gopath: new_resource.gopath,
|
||||||
install_dir: new_resource.install_dir
|
install_dir: new_resource.install_dir
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,22 @@
|
||||||
# Cookbook:: golang
|
# Cookbook:: golang
|
||||||
# Resource:: default
|
# Resource:: default
|
||||||
#
|
#
|
||||||
|
# Copyright:: 2020-2021, Sous-chefs
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
|
||||||
|
# use this file except in compliance with the License. You may obtain a copy
|
||||||
|
# of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||||
|
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||||
|
# License for the specific language governing permissions and limitations
|
||||||
|
# under the License.
|
||||||
|
#
|
||||||
|
|
||||||
|
unified_mode true
|
||||||
|
|
||||||
default_action :install
|
default_action :install
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,19 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of the mingw cookbook.
|
This file is used to list changes made in each version of the mingw cookbook.
|
||||||
|
|
||||||
|
## 2.1.3 - *2021-08-31*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 2.1.1 (2020-06-02)
|
||||||
|
|
||||||
|
- Resolve cookstyle 5.8 warnings - [@tas50](https://github.com/tas50)
|
||||||
|
- Require Chef 12.15+ - [@tas50](https://github.com/tas50)
|
||||||
|
- Fix compatibility with Chef Infra Client 16 - [@xorimabot](https://github.com/xorimabot)
|
||||||
|
- resolved cookstyle error: resources/get.rb:26:1 warning: `ChefDeprecations/ResourceUsesOnlyResourceName`
|
||||||
|
- resolved cookstyle error: resources/msys2_package.rb:31:1 warning: `ChefDeprecations/ResourceUsesOnlyResourceName`
|
||||||
|
- resolved cookstyle error: resources/tdm_gcc.rb:26:1 warning: `ChefDeprecations/ResourceUsesOnlyResourceName`
|
||||||
|
|
||||||
## 2.1.0 (2018-07-24)
|
## 2.1.0 (2018-07-24)
|
||||||
|
|
||||||
- refactor msys2 package source and checksum to attributes
|
- refactor msys2 package source and checksum to attributes
|
||||||
|
|
|
@ -1,2 +0,0 @@
|
||||||
Please refer to
|
|
||||||
https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD
|
|
|
@ -0,0 +1,202 @@
|
||||||
|
Apache License
|
||||||
|
Version 2.0, January 2004
|
||||||
|
http://www.apache.org/licenses/
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||||
|
|
||||||
|
1. Definitions.
|
||||||
|
|
||||||
|
"License" shall mean the terms and conditions for use, reproduction,
|
||||||
|
and distribution as defined by Sections 1 through 9 of this document.
|
||||||
|
|
||||||
|
"Licensor" shall mean the copyright owner or entity authorized by
|
||||||
|
the copyright owner that is granting the License.
|
||||||
|
|
||||||
|
"Legal Entity" shall mean the union of the acting entity and all
|
||||||
|
other entities that control, are controlled by, or are under common
|
||||||
|
control with that entity. For the purposes of this definition,
|
||||||
|
"control" means (i) the power, direct or indirect, to cause the
|
||||||
|
direction or management of such entity, whether by contract or
|
||||||
|
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||||
|
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||||
|
|
||||||
|
"You" (or "Your") shall mean an individual or Legal Entity
|
||||||
|
exercising permissions granted by this License.
|
||||||
|
|
||||||
|
"Source" form shall mean the preferred form for making modifications,
|
||||||
|
including but not limited to software source code, documentation
|
||||||
|
source, and configuration files.
|
||||||
|
|
||||||
|
"Object" form shall mean any form resulting from mechanical
|
||||||
|
transformation or translation of a Source form, including but
|
||||||
|
not limited to compiled object code, generated documentation,
|
||||||
|
and conversions to other media types.
|
||||||
|
|
||||||
|
"Work" shall mean the work of authorship, whether in Source or
|
||||||
|
Object form, made available under the License, as indicated by a
|
||||||
|
copyright notice that is included in or attached to the work
|
||||||
|
(an example is provided in the Appendix below).
|
||||||
|
|
||||||
|
"Derivative Works" shall mean any work, whether in Source or Object
|
||||||
|
form, that is based on (or derived from) the Work and for which the
|
||||||
|
editorial revisions, annotations, elaborations, or other modifications
|
||||||
|
represent, as a whole, an original work of authorship. For the purposes
|
||||||
|
of this License, Derivative Works shall not include works that remain
|
||||||
|
separable from, or merely link (or bind by name) to the interfaces of,
|
||||||
|
the Work and Derivative Works thereof.
|
||||||
|
|
||||||
|
"Contribution" shall mean any work of authorship, including
|
||||||
|
the original version of the Work and any modifications or additions
|
||||||
|
to that Work or Derivative Works thereof, that is intentionally
|
||||||
|
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||||
|
or by an individual or Legal Entity authorized to submit on behalf of
|
||||||
|
the copyright owner. For the purposes of this definition, "submitted"
|
||||||
|
means any form of electronic, verbal, or written communication sent
|
||||||
|
to the Licensor or its representatives, including but not limited to
|
||||||
|
communication on electronic mailing lists, source code control systems,
|
||||||
|
and issue tracking systems that are managed by, or on behalf of, the
|
||||||
|
Licensor for the purpose of discussing and improving the Work, but
|
||||||
|
excluding communication that is conspicuously marked or otherwise
|
||||||
|
designated in writing by the copyright owner as "Not a Contribution."
|
||||||
|
|
||||||
|
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||||
|
on behalf of whom a Contribution has been received by Licensor and
|
||||||
|
subsequently incorporated within the Work.
|
||||||
|
|
||||||
|
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
copyright license to reproduce, prepare Derivative Works of,
|
||||||
|
publicly display, publicly perform, sublicense, and distribute the
|
||||||
|
Work and such Derivative Works in Source or Object form.
|
||||||
|
|
||||||
|
3. Grant of Patent License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
(except as stated in this section) patent license to make, have made,
|
||||||
|
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||||
|
where such license applies only to those patent claims licensable
|
||||||
|
by such Contributor that are necessarily infringed by their
|
||||||
|
Contribution(s) alone or by combination of their Contribution(s)
|
||||||
|
with the Work to which such Contribution(s) was submitted. If You
|
||||||
|
institute patent litigation against any entity (including a
|
||||||
|
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||||
|
or a Contribution incorporated within the Work constitutes direct
|
||||||
|
or contributory patent infringement, then any patent licenses
|
||||||
|
granted to You under this License for that Work shall terminate
|
||||||
|
as of the date such litigation is filed.
|
||||||
|
|
||||||
|
4. Redistribution. You may reproduce and distribute copies of the
|
||||||
|
Work or Derivative Works thereof in any medium, with or without
|
||||||
|
modifications, and in Source or Object form, provided that You
|
||||||
|
meet the following conditions:
|
||||||
|
|
||||||
|
(a) You must give any other recipients of the Work or
|
||||||
|
Derivative Works a copy of this License; and
|
||||||
|
|
||||||
|
(b) You must cause any modified files to carry prominent notices
|
||||||
|
stating that You changed the files; and
|
||||||
|
|
||||||
|
(c) You must retain, in the Source form of any Derivative Works
|
||||||
|
that You distribute, all copyright, patent, trademark, and
|
||||||
|
attribution notices from the Source form of the Work,
|
||||||
|
excluding those notices that do not pertain to any part of
|
||||||
|
the Derivative Works; and
|
||||||
|
|
||||||
|
(d) If the Work includes a "NOTICE" text file as part of its
|
||||||
|
distribution, then any Derivative Works that You distribute must
|
||||||
|
include a readable copy of the attribution notices contained
|
||||||
|
within such NOTICE file, excluding those notices that do not
|
||||||
|
pertain to any part of the Derivative Works, in at least one
|
||||||
|
of the following places: within a NOTICE text file distributed
|
||||||
|
as part of the Derivative Works; within the Source form or
|
||||||
|
documentation, if provided along with the Derivative Works; or,
|
||||||
|
within a display generated by the Derivative Works, if and
|
||||||
|
wherever such third-party notices normally appear. The contents
|
||||||
|
of the NOTICE file are for informational purposes only and
|
||||||
|
do not modify the License. You may add Your own attribution
|
||||||
|
notices within Derivative Works that You distribute, alongside
|
||||||
|
or as an addendum to the NOTICE text from the Work, provided
|
||||||
|
that such additional attribution notices cannot be construed
|
||||||
|
as modifying the License.
|
||||||
|
|
||||||
|
You may add Your own copyright statement to Your modifications and
|
||||||
|
may provide additional or different license terms and conditions
|
||||||
|
for use, reproduction, or distribution of Your modifications, or
|
||||||
|
for any such Derivative Works as a whole, provided Your use,
|
||||||
|
reproduction, and distribution of the Work otherwise complies with
|
||||||
|
the conditions stated in this License.
|
||||||
|
|
||||||
|
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||||
|
any Contribution intentionally submitted for inclusion in the Work
|
||||||
|
by You to the Licensor shall be under the terms and conditions of
|
||||||
|
this License, without any additional terms or conditions.
|
||||||
|
Notwithstanding the above, nothing herein shall supersede or modify
|
||||||
|
the terms of any separate license agreement you may have executed
|
||||||
|
with Licensor regarding such Contributions.
|
||||||
|
|
||||||
|
6. Trademarks. This License does not grant permission to use the trade
|
||||||
|
names, trademarks, service marks, or product names of the Licensor,
|
||||||
|
except as required for reasonable and customary use in describing the
|
||||||
|
origin of the Work and reproducing the content of the NOTICE file.
|
||||||
|
|
||||||
|
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||||
|
agreed to in writing, Licensor provides the Work (and each
|
||||||
|
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||||
|
implied, including, without limitation, any warranties or conditions
|
||||||
|
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||||
|
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||||
|
appropriateness of using or redistributing the Work and assume any
|
||||||
|
risks associated with Your exercise of permissions under this License.
|
||||||
|
|
||||||
|
8. Limitation of Liability. In no event and under no legal theory,
|
||||||
|
whether in tort (including negligence), contract, or otherwise,
|
||||||
|
unless required by applicable law (such as deliberate and grossly
|
||||||
|
negligent acts) or agreed to in writing, shall any Contributor be
|
||||||
|
liable to You for damages, including any direct, indirect, special,
|
||||||
|
incidental, or consequential damages of any character arising as a
|
||||||
|
result of this License or out of the use or inability to use the
|
||||||
|
Work (including but not limited to damages for loss of goodwill,
|
||||||
|
work stoppage, computer failure or malfunction, or any and all
|
||||||
|
other commercial damages or losses), even if such Contributor
|
||||||
|
has been advised of the possibility of such damages.
|
||||||
|
|
||||||
|
9. Accepting Warranty or Additional Liability. While redistributing
|
||||||
|
the Work or Derivative Works thereof, You may choose to offer,
|
||||||
|
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||||
|
or other liability obligations and/or rights consistent with this
|
||||||
|
License. However, in accepting such obligations, You may act only
|
||||||
|
on Your own behalf and on Your sole responsibility, not on behalf
|
||||||
|
of any other Contributor, and only if You agree to indemnify,
|
||||||
|
defend, and hold each Contributor harmless for any liability
|
||||||
|
incurred by, or claims asserted against, such Contributor by reason
|
||||||
|
of your accepting any such warranty or additional liability.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
APPENDIX: How to apply the Apache License to your work.
|
||||||
|
|
||||||
|
To apply the Apache License to your work, attach the following
|
||||||
|
boilerplate notice, with the fields enclosed by brackets "{}"
|
||||||
|
replaced with your own identifying information. (Don't include
|
||||||
|
the brackets!) The text should be enclosed in the appropriate
|
||||||
|
comment syntax for the file format. We also recommend that a
|
||||||
|
file or class name and description of purpose be included on the
|
||||||
|
same "printed page" as the copyright notice for easier
|
||||||
|
identification within third-party archives.
|
||||||
|
|
||||||
|
Copyright {yyyy} {name of copyright owner}
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
|
|
@ -12,7 +12,7 @@ Installs a mingw/msys based compiler tools chain on windows. This is required fo
|
||||||
|
|
||||||
### Chef
|
### Chef
|
||||||
|
|
||||||
- Chef 12.5+
|
- Chef 12.15+
|
||||||
|
|
||||||
### Cookbooks
|
### Cookbooks
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,115 @@
|
||||||
|
# Put files/directories that should be ignored in this file when uploading
|
||||||
|
# to a Chef Infra Server or Supermarket.
|
||||||
|
# Lines that start with '# ' are comments.
|
||||||
|
|
||||||
|
# OS generated files #
|
||||||
|
######################
|
||||||
|
.DS_Store
|
||||||
|
ehthumbs.db
|
||||||
|
Icon?
|
||||||
|
nohup.out
|
||||||
|
Thumbs.db
|
||||||
|
.envrc
|
||||||
|
|
||||||
|
# EDITORS #
|
||||||
|
###########
|
||||||
|
.#*
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
*_flymake
|
||||||
|
*_flymake.*
|
||||||
|
*.bak
|
||||||
|
*.sw[a-z]
|
||||||
|
*.tmproj
|
||||||
|
*~
|
||||||
|
\#*
|
||||||
|
REVISION
|
||||||
|
TAGS*
|
||||||
|
tmtags
|
||||||
|
.vscode
|
||||||
|
.editorconfig
|
||||||
|
|
||||||
|
## COMPILED ##
|
||||||
|
##############
|
||||||
|
*.class
|
||||||
|
*.com
|
||||||
|
*.dll
|
||||||
|
*.exe
|
||||||
|
*.o
|
||||||
|
*.pyc
|
||||||
|
*.so
|
||||||
|
*/rdoc/
|
||||||
|
a.out
|
||||||
|
mkmf.log
|
||||||
|
|
||||||
|
# Testing #
|
||||||
|
###########
|
||||||
|
.circleci/*
|
||||||
|
.codeclimate.yml
|
||||||
|
.delivery/*
|
||||||
|
.foodcritic
|
||||||
|
.kitchen*
|
||||||
|
.mdlrc
|
||||||
|
.overcommit.yml
|
||||||
|
.rspec
|
||||||
|
.rubocop.yml
|
||||||
|
.travis.yml
|
||||||
|
.watchr
|
||||||
|
.yamllint
|
||||||
|
azure-pipelines.yml
|
||||||
|
Dangerfile
|
||||||
|
examples/*
|
||||||
|
features/*
|
||||||
|
Guardfile
|
||||||
|
kitchen.yml*
|
||||||
|
mlc_config.json
|
||||||
|
Procfile
|
||||||
|
Rakefile
|
||||||
|
spec/*
|
||||||
|
test/*
|
||||||
|
|
||||||
|
# SCM #
|
||||||
|
#######
|
||||||
|
.git
|
||||||
|
.gitattributes
|
||||||
|
.gitconfig
|
||||||
|
.github/*
|
||||||
|
.gitignore
|
||||||
|
.gitkeep
|
||||||
|
.gitmodules
|
||||||
|
.svn
|
||||||
|
*/.bzr/*
|
||||||
|
*/.git
|
||||||
|
*/.hg/*
|
||||||
|
*/.svn/*
|
||||||
|
|
||||||
|
# Berkshelf #
|
||||||
|
#############
|
||||||
|
Berksfile
|
||||||
|
Berksfile.lock
|
||||||
|
cookbooks/*
|
||||||
|
tmp
|
||||||
|
|
||||||
|
# Bundler #
|
||||||
|
###########
|
||||||
|
vendor/*
|
||||||
|
Gemfile
|
||||||
|
Gemfile.lock
|
||||||
|
|
||||||
|
# Policyfile #
|
||||||
|
##############
|
||||||
|
Policyfile.rb
|
||||||
|
Policyfile.lock.json
|
||||||
|
|
||||||
|
# Documentation #
|
||||||
|
#############
|
||||||
|
CODE_OF_CONDUCT*
|
||||||
|
CONTRIBUTING*
|
||||||
|
documentation/*
|
||||||
|
TESTING*
|
||||||
|
UPGRADING*
|
||||||
|
|
||||||
|
# Vagrant #
|
||||||
|
###########
|
||||||
|
.vagrant
|
||||||
|
Vagrantfile
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: mingw
|
# Cookbook:: mingw
|
||||||
# Library:: _helper
|
# Library:: _helper
|
||||||
#
|
#
|
||||||
# Copyright:: 2016, Chef Software, Inc.
|
# Copyright:: 2016-2019, Chef Software, Inc.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -35,4 +35,4 @@ module Mingw
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
Chef::Resource.send(:include, Mingw::Helper)
|
Chef::Resource.include Mingw::Helper
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,14 @@
|
||||||
|
name 'mingw'
|
||||||
|
maintainer 'Chef Software, Inc.'
|
||||||
|
maintainer_email 'cookbooks@chef.io'
|
||||||
|
license 'Apache-2.0'
|
||||||
|
description 'Installs a mingw/msys based toolchain on windows'
|
||||||
|
version '2.1.3'
|
||||||
|
|
||||||
|
supports 'windows'
|
||||||
|
|
||||||
|
depends 'seven_zip'
|
||||||
|
|
||||||
|
source_url 'https://github.com/chef-cookbooks/mingw'
|
||||||
|
issues_url 'https://github.com/chef-cookbooks/mingw/issues'
|
||||||
|
chef_version '>= 12.15'
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: mingw
|
# Cookbook:: mingw
|
||||||
# Recipe:: default
|
# Recipe:: default
|
||||||
#
|
#
|
||||||
# Copyright:: 2016, Chef Software, Inc.
|
# Copyright:: 2016-2019, Chef Software, Inc.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: mingw
|
# Cookbook:: mingw
|
||||||
# Resource:: get
|
# Resource:: get
|
||||||
#
|
#
|
||||||
# Copyright:: 2016, Chef Software, Inc.
|
# Copyright:: 2016-2019, Chef Software, Inc.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -23,8 +23,6 @@
|
||||||
property :package, String, name_property: true
|
property :package, String, name_property: true
|
||||||
property :root, String, required: true
|
property :root, String, required: true
|
||||||
|
|
||||||
resource_name :mingw_get
|
|
||||||
|
|
||||||
action_class do
|
action_class do
|
||||||
def mingw_do_action(action_cmd)
|
def mingw_do_action(action_cmd)
|
||||||
seven_zip_archive "fetching mingw-get to #{win_friendly_path(root)}" do
|
seven_zip_archive "fetching mingw-get to #{win_friendly_path(root)}" do
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: mingw
|
# Cookbook:: mingw
|
||||||
# Resource:: msys2_package
|
# Resource:: msys2_package
|
||||||
#
|
#
|
||||||
# Copyright:: 2016, Chef Software, Inc.
|
# Copyright:: 2016-2019, Chef Software, Inc.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -19,16 +19,16 @@
|
||||||
|
|
||||||
# Installs msys2 base system and installs/upgrades packages within in.
|
# Installs msys2 base system and installs/upgrades packages within in.
|
||||||
#
|
#
|
||||||
# Where's the version flag? Where's idempotence you say? Well f*** you
|
# Where's the version flag? Where's idempotence you say? Well f*** you
|
||||||
# for trying to version your product. This is arch. They live on the edge.
|
# for trying to version your product. This is arch. They live on the edge.
|
||||||
# You never get anything but the latest version. And if that's broken...
|
# You never get anything but the latest version. And if that's broken...
|
||||||
# well that's your problem isn't it? And they don't believe in preserving
|
# well that's your problem isn't it? And they don't believe in preserving
|
||||||
# older versions. Good luck!
|
# older versions. Good luck!
|
||||||
|
|
||||||
property :package, String, name_property: true
|
property :package, String, name_property: true
|
||||||
property :root, String, required: true
|
property :root, String, required: true
|
||||||
|
|
||||||
resource_name :msys2_package
|
provides :msys2_package
|
||||||
|
|
||||||
action_class do
|
action_class do
|
||||||
#
|
#
|
||||||
|
@ -97,7 +97,7 @@ action_class do
|
||||||
cookbook 'mingw'
|
cookbook 'mingw'
|
||||||
end
|
end
|
||||||
|
|
||||||
# $HOME is using files from /etc/skel. The home-directory creation step
|
# $HOME is using files from /etc/skel. The home-directory creation step
|
||||||
# will automatically be performed if other users log in - so if you wish
|
# will automatically be performed if other users log in - so if you wish
|
||||||
# to globally modify user first time setup, edit /etc/skel or add
|
# to globally modify user first time setup, edit /etc/skel or add
|
||||||
# "post-setup" steps to /etc/post-install/
|
# "post-setup" steps to /etc/post-install/
|
||||||
|
@ -125,10 +125,10 @@ action :install do
|
||||||
msys2_do_action("installing #{package}", "pacman -S --needed --noconfirm #{package}")
|
msys2_do_action("installing #{package}", "pacman -S --needed --noconfirm #{package}")
|
||||||
end
|
end
|
||||||
|
|
||||||
# Package name is ignored. This is arch. Why would you ever upgrade a single
|
# Package name is ignored. This is arch. Why would you ever upgrade a single
|
||||||
# package and its deps? That'll just break everything else that ever depended
|
# package and its deps? That'll just break everything else that ever depended
|
||||||
# on a different version of that dep. Because arch is wonderful like that.
|
# on a different version of that dep. Because arch is wonderful like that.
|
||||||
# So you only get the choice to move everything to latest or not... it's the
|
# So you only get the choice to move everything to latest or not... it's the
|
||||||
# most agile development possible!
|
# most agile development possible!
|
||||||
action :upgrade do
|
action :upgrade do
|
||||||
msys2_do_action("upgrading #{package}", "pacman -Syu --noconfirm #{package}")
|
msys2_do_action("upgrading #{package}", "pacman -Syu --noconfirm #{package}")
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
# Cookbook:: mingw
|
# Cookbook:: mingw
|
||||||
# Resource:: tdm_gcc
|
# Resource:: tdm_gcc
|
||||||
#
|
#
|
||||||
# Copyright:: 2016, Chef Software, Inc.
|
# Copyright:: 2016-2019, Chef Software, Inc.
|
||||||
#
|
#
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
# you may not use this file except in compliance with the License.
|
# you may not use this file except in compliance with the License.
|
||||||
|
@ -23,8 +23,6 @@ property :flavor, Symbol, is: [:sjlj_32, :seh_sjlj_64], default: :seh_sjlj_64
|
||||||
property :root, String, required: true
|
property :root, String, required: true
|
||||||
property :version, String, is: ['5.1.0'], name_property: true
|
property :version, String, is: ['5.1.0'], name_property: true
|
||||||
|
|
||||||
resource_name :mingw_tdm_gcc
|
|
||||||
|
|
||||||
tdm_gcc_64 = {
|
tdm_gcc_64 = {
|
||||||
'http://iweb.dl.sourceforge.net/project/tdm-gcc/TDM-GCC%205%20series/5.1.0-tdm64-1/gcc-5.1.0-tdm64-1-core.tar.lzma' =>
|
'http://iweb.dl.sourceforge.net/project/tdm-gcc/TDM-GCC%205%20series/5.1.0-tdm64-1/gcc-5.1.0-tdm64-1-core.tar.lzma' =>
|
||||||
'29393aac890847089ad1e93f81a28f6744b1609c00b25afca818f3903e42e4bd',
|
'29393aac890847089ad1e93f81a28f6744b1609c00b25afca818f3903e42e4bd',
|
||||||
|
|
|
@ -2,6 +2,13 @@
|
||||||
|
|
||||||
All notable changes to this project will be documented in this file.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
|
## 8.7.4 - 2020-09-16
|
||||||
|
|
||||||
|
- resolved cookstyle error: spec/mysql_client_installation_package_spec.rb:4:48 warning: `ChefDeprecations/DeprecatedChefSpecPlatform`
|
||||||
|
- resolved cookstyle error: spec/mysql_server_installation_package_spec.rb:4:48 warning: `ChefDeprecations/DeprecatedChefSpecPlatform`
|
||||||
|
- Use mysql_test cookbook attributes for testing
|
||||||
|
- Cookstyle Bot Auto Corrections with Cookstyle 6.17.6
|
||||||
|
|
||||||
## 8.7.3 - 2020-07-22
|
## 8.7.3 - 2020-07-22
|
||||||
|
|
||||||
- restore resource_name in mysql_service for Chef Infra Client < 16
|
- restore resource_name in mysql_service for Chef Infra Client < 16
|
||||||
|
|
|
@ -3,48 +3,48 @@ module MysqlCookbook
|
||||||
require 'shellwords'
|
require 'shellwords'
|
||||||
|
|
||||||
def el6?
|
def el6?
|
||||||
return true if node['platform_family'] == 'rhel' && node['platform_version'].to_i == 6
|
return true if platform_family?('rhel') && node['platform_version'].to_i == 6
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def el7?
|
def el7?
|
||||||
return true if node['platform_family'] == 'rhel' && node['platform_version'].to_i == 7
|
return true if platform_family?('rhel') && node['platform_version'].to_i == 7
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def fedora?
|
def fedora?
|
||||||
return true if node['platform_family'] == 'fedora'
|
return true if platform_family?('fedora')
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def suse?
|
def suse?
|
||||||
return true if node['platform_family'] == 'suse'
|
return true if platform_family?('suse')
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def jessie?
|
def jessie?
|
||||||
return true if node['platform'] == 'debian' && node['platform_version'].to_i == 8
|
return true if platform?('debian') && node['platform_version'].to_i == 8
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def stretch?
|
def stretch?
|
||||||
return true if node['platform'] == 'debian' && node['platform_version'].to_i == 9
|
return true if platform?('debian') && node['platform_version'].to_i == 9
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def trusty?
|
def trusty?
|
||||||
return true if node['platform'] == 'ubuntu' && node['platform_version'] == '14.04'
|
return true if platform?('ubuntu') && node['platform_version'] == '14.04'
|
||||||
return true if node['platform'] == 'linuxmint' && node['platform_version'] =~ /^17\.[0-9]$/
|
return true if platform?('linuxmint') && node['platform_version'] =~ /^17\.[0-9]$/
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def xenial?
|
def xenial?
|
||||||
return true if node['platform'] == 'ubuntu' && node['platform_version'] == '16.04'
|
return true if platform?('ubuntu') && node['platform_version'] == '16.04'
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def bionic?
|
def bionic?
|
||||||
return true if node['platform'] == 'ubuntu' && node['platform_version'] == '18.04'
|
return true if platform?('ubuntu') && node['platform_version'] == '18.04'
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -70,7 +70,7 @@ module MysqlCookbook
|
||||||
# rhelish
|
# rhelish
|
||||||
return '5.6' if el6?
|
return '5.6' if el6?
|
||||||
return '5.6' if el7?
|
return '5.6' if el7?
|
||||||
return '5.6' if node['platform'] == 'amazon'
|
return '5.6' if platform?('amazon')
|
||||||
|
|
||||||
# debian
|
# debian
|
||||||
return '5.5' if jessie?
|
return '5.5' if jessie?
|
||||||
|
@ -81,7 +81,7 @@ module MysqlCookbook
|
||||||
return '5.7' if bionic?
|
return '5.7' if bionic?
|
||||||
|
|
||||||
# misc
|
# misc
|
||||||
return '5.6' if node['platform'] == 'freebsd'
|
return '5.6' if platform?('freebsd')
|
||||||
return '5.7' if fedora?
|
return '5.7' if fedora?
|
||||||
return '5.6' if suse?
|
return '5.6' if suse?
|
||||||
end
|
end
|
||||||
|
@ -105,25 +105,25 @@ module MysqlCookbook
|
||||||
def default_client_package_name
|
def default_client_package_name
|
||||||
return %w(mysql mysql-devel) if major_version == '5.1' && el6?
|
return %w(mysql mysql-devel) if major_version == '5.1' && el6?
|
||||||
return %w(mysql mysql-devel) if el7?
|
return %w(mysql mysql-devel) if el7?
|
||||||
return ['mysql55', 'mysql55-devel.x86_64'] if major_version == '5.5' && node['platform'] == 'amazon'
|
return ['mysql55', 'mysql55-devel.x86_64'] if major_version == '5.5' && platform?('amazon')
|
||||||
return ['mysql56', 'mysql56-devel.x86_64'] if major_version == '5.6' && node['platform'] == 'amazon'
|
return ['mysql56', 'mysql56-devel.x86_64'] if major_version == '5.6' && platform?('amazon')
|
||||||
return ['mysql57', 'mysql57-devel.x86_64'] if major_version == '5.7' && node['platform'] == 'amazon'
|
return ['mysql57', 'mysql57-devel.x86_64'] if major_version == '5.7' && platform?('amazon')
|
||||||
return ['mysql-client-5.5', 'libmysqlclient-dev'] if major_version == '5.5' && node['platform_family'] == 'debian'
|
return ['mysql-client-5.5', 'libmysqlclient-dev'] if major_version == '5.5' && platform_family?('debian')
|
||||||
return ['mysql-client-5.6', 'libmysqlclient-dev'] if major_version == '5.6' && node['platform_family'] == 'debian'
|
return ['mysql-client-5.6', 'libmysqlclient-dev'] if major_version == '5.6' && platform_family?('debian')
|
||||||
return ['mysql-client-5.7', 'libmysqlclient-dev'] if major_version == '5.7' && node['platform_family'] == 'debian'
|
return ['mysql-client-5.7', 'libmysqlclient-dev'] if major_version == '5.7' && platform_family?('debian')
|
||||||
return 'mysql-community-server-client' if major_version == '5.6' && node['platform_family'] == 'suse'
|
return 'mysql-community-server-client' if major_version == '5.6' && platform_family?('suse')
|
||||||
%w(mysql-community-client mysql-community-devel)
|
%w(mysql-community-client mysql-community-devel)
|
||||||
end
|
end
|
||||||
|
|
||||||
def default_server_package_name
|
def default_server_package_name
|
||||||
return 'mysql-server' if major_version == '5.1' && el6?
|
return 'mysql-server' if major_version == '5.1' && el6?
|
||||||
return 'mysql55-server' if major_version == '5.5' && node['platform'] == 'amazon'
|
return 'mysql55-server' if major_version == '5.5' && platform?('amazon')
|
||||||
return 'mysql56-server' if major_version == '5.6' && node['platform'] == 'amazon'
|
return 'mysql56-server' if major_version == '5.6' && platform?('amazon')
|
||||||
return 'mysql57-server' if major_version == '5.7' && node['platform'] == 'amazon'
|
return 'mysql57-server' if major_version == '5.7' && platform?('amazon')
|
||||||
return 'mysql-server-5.5' if major_version == '5.5' && node['platform_family'] == 'debian'
|
return 'mysql-server-5.5' if major_version == '5.5' && platform_family?('debian')
|
||||||
return 'mysql-server-5.6' if major_version == '5.6' && node['platform_family'] == 'debian'
|
return 'mysql-server-5.6' if major_version == '5.6' && platform_family?('debian')
|
||||||
return 'mysql-server-5.7' if major_version == '5.7' && node['platform_family'] == 'debian'
|
return 'mysql-server-5.7' if major_version == '5.7' && platform_family?('debian')
|
||||||
return 'mysql-community-server' if major_version == '5.6' && node['platform_family'] == 'suse'
|
return 'mysql-community-server' if major_version == '5.6' && platform_family?('suse')
|
||||||
'mysql-community-server'
|
'mysql-community-server'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -132,33 +132,33 @@ module MysqlCookbook
|
||||||
end
|
end
|
||||||
|
|
||||||
def run_dir
|
def run_dir
|
||||||
return "#{prefix_dir}/var/run/#{mysql_name}" if node['platform_family'] == 'rhel'
|
return "#{prefix_dir}/var/run/#{mysql_name}" if platform_family?('rhel')
|
||||||
return "/run/#{mysql_name}" if node['platform_family'] == 'debian'
|
return "/run/#{mysql_name}" if platform_family?('debian')
|
||||||
"/var/run/#{mysql_name}"
|
"/var/run/#{mysql_name}"
|
||||||
end
|
end
|
||||||
|
|
||||||
def prefix_dir
|
def prefix_dir
|
||||||
return "/opt/mysql#{pkg_ver_string}" if node['platform_family'] == 'omnios'
|
return "/opt/mysql#{pkg_ver_string}" if platform_family?('omnios')
|
||||||
return '/opt/local' if node['platform_family'] == 'smartos'
|
return '/opt/local' if platform_family?('smartos')
|
||||||
return "/opt/rh/#{scl_name}/root" if scl_package?
|
return "/opt/rh/#{scl_name}/root" if scl_package?
|
||||||
end
|
end
|
||||||
|
|
||||||
def scl_name
|
def scl_name
|
||||||
return unless node['platform_family'] == 'rhel'
|
return unless platform_family?('rhel')
|
||||||
return 'mysql51' if version == '5.1' && node['platform_version'].to_i == 5
|
return 'mysql51' if version == '5.1' && node['platform_version'].to_i == 5
|
||||||
return 'mysql55' if version == '5.5' && node['platform_version'].to_i == 5
|
return 'mysql55' if version == '5.5' && node['platform_version'].to_i == 5
|
||||||
end
|
end
|
||||||
|
|
||||||
def scl_package?
|
def scl_package?
|
||||||
return unless node['platform_family'] == 'rhel'
|
return unless platform_family?('rhel')
|
||||||
return true if version == '5.1' && node['platform_version'].to_i == 5
|
return true if version == '5.1' && node['platform_version'].to_i == 5
|
||||||
return true if version == '5.5' && node['platform_version'].to_i == 5
|
return true if version == '5.5' && node['platform_version'].to_i == 5
|
||||||
false
|
false
|
||||||
end
|
end
|
||||||
|
|
||||||
def etc_dir
|
def etc_dir
|
||||||
return "/opt/mysql#{pkg_ver_string}/etc/#{mysql_name}" if node['platform_family'] == 'omnios'
|
return "/opt/mysql#{pkg_ver_string}/etc/#{mysql_name}" if platform_family?('omnios')
|
||||||
return "#{prefix_dir}/etc/#{mysql_name}" if node['platform_family'] == 'smartos'
|
return "#{prefix_dir}/etc/#{mysql_name}" if platform_family?('smartos')
|
||||||
"#{prefix_dir}/etc/#{mysql_name}"
|
"#{prefix_dir}/etc/#{mysql_name}"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -167,10 +167,10 @@ module MysqlCookbook
|
||||||
end
|
end
|
||||||
|
|
||||||
def system_service_name
|
def system_service_name
|
||||||
return 'mysql51-mysqld' if node['platform_family'] == 'rhel' && scl_name == 'mysql51'
|
return 'mysql51-mysqld' if platform_family?('rhel') && scl_name == 'mysql51'
|
||||||
return 'mysql55-mysqld' if node['platform_family'] == 'rhel' && scl_name == 'mysql55'
|
return 'mysql55-mysqld' if platform_family?('rhel') && scl_name == 'mysql55'
|
||||||
return 'mysqld' if node['platform_family'] == 'rhel'
|
return 'mysqld' if platform_family?('rhel')
|
||||||
return 'mysqld' if node['platform_family'] == 'fedora'
|
return 'mysqld' if platform_family?('fedora')
|
||||||
'mysql' # not one of the above
|
'mysql' # not one of the above
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -191,7 +191,7 @@ module MysqlCookbook
|
||||||
end
|
end
|
||||||
|
|
||||||
def log_dir
|
def log_dir
|
||||||
return "/var/adm/log/#{mysql_name}" if node['platform_family'] == 'omnios'
|
return "/var/adm/log/#{mysql_name}" if platform_family?('omnios')
|
||||||
"#{prefix_dir}/var/log/#{mysql_name}"
|
"#{prefix_dir}/var/log/#{mysql_name}"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -258,8 +258,8 @@ EOSQL
|
||||||
end
|
end
|
||||||
|
|
||||||
def mysql_install_db_bin
|
def mysql_install_db_bin
|
||||||
return "#{base_dir}/scripts/mysql_install_db" if node['platform_family'] == 'omnios'
|
return "#{base_dir}/scripts/mysql_install_db" if platform_family?('omnios')
|
||||||
return "#{prefix_dir}/bin/mysql_install_db" if node['platform_family'] == 'smartos'
|
return "#{prefix_dir}/bin/mysql_install_db" if platform_family?('smartos')
|
||||||
'mysql_install_db'
|
'mysql_install_db'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -273,14 +273,14 @@ EOSQL
|
||||||
end
|
end
|
||||||
|
|
||||||
def mysqladmin_bin
|
def mysqladmin_bin
|
||||||
return "#{prefix_dir}/bin/mysqladmin" if node['platform_family'] == 'smartos'
|
return "#{prefix_dir}/bin/mysqladmin" if platform_family?('smartos')
|
||||||
return 'mysqladmin' if scl_package?
|
return 'mysqladmin' if scl_package?
|
||||||
"#{prefix_dir}/usr/bin/mysqladmin"
|
"#{prefix_dir}/usr/bin/mysqladmin"
|
||||||
end
|
end
|
||||||
|
|
||||||
def mysqld_bin
|
def mysqld_bin
|
||||||
return "#{prefix_dir}/libexec/mysqld" if node['platform_family'] == 'smartos'
|
return "#{prefix_dir}/libexec/mysqld" if platform_family?('smartos')
|
||||||
return "#{base_dir}/bin/mysqld" if node['platform_family'] == 'omnios'
|
return "#{base_dir}/bin/mysqld" if platform_family?('omnios')
|
||||||
return '/usr/sbin/mysqld' if fedora? && v56plus
|
return '/usr/sbin/mysqld' if fedora? && v56plus
|
||||||
return '/usr/libexec/mysqld' if fedora?
|
return '/usr/libexec/mysqld' if fedora?
|
||||||
return 'mysqld' if scl_package?
|
return 'mysqld' if scl_package?
|
||||||
|
@ -289,14 +289,14 @@ EOSQL
|
||||||
|
|
||||||
def mysql_systemd_start_pre
|
def mysql_systemd_start_pre
|
||||||
return '/usr/bin/mysqld_pre_systemd' if v57plus && (el7? || fedora?)
|
return '/usr/bin/mysqld_pre_systemd' if v57plus && (el7? || fedora?)
|
||||||
return '/usr/bin/mysql-systemd-start pre' if node['platform_family'] == 'rhel'
|
return '/usr/bin/mysql-systemd-start pre' if platform_family?('rhel')
|
||||||
return '/usr/lib/mysql/mysql-systemd-helper install' if suse?
|
return '/usr/lib/mysql/mysql-systemd-helper install' if suse?
|
||||||
'/usr/share/mysql/mysql-systemd-start pre'
|
'/usr/share/mysql/mysql-systemd-start pre'
|
||||||
end
|
end
|
||||||
|
|
||||||
def mysql_systemd
|
def mysql_systemd
|
||||||
return "/usr/libexec/#{mysql_name}-wait-ready $MAINPID" if v57plus && (el7? || fedora?)
|
return "/usr/libexec/#{mysql_name}-wait-ready $MAINPID" if v57plus && (el7? || fedora?)
|
||||||
return '/usr/bin/mysql-systemd-start' if node['platform_family'] == 'rhel'
|
return '/usr/bin/mysql-systemd-start' if platform_family?('rhel')
|
||||||
return '/usr/share/mysql/mysql-systemd-start' if v57plus
|
return '/usr/share/mysql/mysql-systemd-start' if v57plus
|
||||||
"/usr/libexec/#{mysql_name}-wait-ready $MAINPID"
|
"/usr/libexec/#{mysql_name}-wait-ready $MAINPID"
|
||||||
end
|
end
|
||||||
|
@ -311,8 +311,8 @@ EOSQL
|
||||||
end
|
end
|
||||||
|
|
||||||
def mysqld_safe_bin
|
def mysqld_safe_bin
|
||||||
return "#{prefix_dir}/bin/mysqld_safe" if node['platform_family'] == 'smartos'
|
return "#{prefix_dir}/bin/mysqld_safe" if platform_family?('smartos')
|
||||||
return "#{base_dir}/bin/mysqld_safe" if node['platform_family'] == 'omnios'
|
return "#{base_dir}/bin/mysqld_safe" if platform_family?('omnios')
|
||||||
return 'mysqld_safe' if scl_package?
|
return 'mysqld_safe' if scl_package?
|
||||||
"#{prefix_dir}/usr/bin/mysqld_safe"
|
"#{prefix_dir}/usr/bin/mysqld_safe"
|
||||||
end
|
end
|
||||||
|
|
|
@ -123,7 +123,7 @@ module MysqlCookbook
|
||||||
def configure_apparmor
|
def configure_apparmor
|
||||||
# Do not add these resource if inside a container
|
# Do not add these resource if inside a container
|
||||||
# Only valid on Ubuntu
|
# Only valid on Ubuntu
|
||||||
return if ::File.exist?('/.dockerenv') || ::File.exist?('/.dockerinit') || node['platform'] != 'ubuntu'
|
return if ::File.exist?('/.dockerenv') || ::File.exist?('/.dockerinit') || !platform?('ubuntu')
|
||||||
|
|
||||||
# Apparmor
|
# Apparmor
|
||||||
package 'apparmor' do
|
package 'apparmor' do
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
{"name":"mysql","version":"8.7.3","description":"Provides mysql_service, mysql_config, and mysql_client resources","long_description":"","maintainer":"Sous Chefs","maintainer_email":"help@sous-chefs.org","license":"Apache-2.0","platforms":{"redhat":">= 6.0","centos":">= 6.0","scientific":">= 6.0","oracle":">= 6.0","amazon":">= 0.0.0","fedora":">= 0.0.0","debian":">= 7.0","ubuntu":">= 14.04","opensuseleap":">= 0.0.0","suse":">= 12.0"},"dependencies":{},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/sous-chefs/mysql","issues_url":"https://github.com/sous-chefs/mysql/issues","chef_version":[[">= 12.7"]],"ohai_version":[]}
|
{"name":"mysql","version":"8.7.4","description":"Provides mysql_service, mysql_config, and mysql_client resources","long_description":"","maintainer":"Sous Chefs","maintainer_email":"help@sous-chefs.org","license":"Apache-2.0","platforms":{"redhat":">= 6.0","centos":">= 6.0","scientific":">= 6.0","oracle":">= 6.0","amazon":">= 0.0.0","fedora":">= 0.0.0","debian":">= 7.0","ubuntu":">= 14.04","opensuseleap":">= 0.0.0","suse":">= 12.0"},"dependencies":{},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/sous-chefs/mysql","issues_url":"https://github.com/sous-chefs/mysql/issues","chef_version":[[">= 12.7"]],"ohai_version":[]}
|
|
@ -6,7 +6,7 @@ description 'Provides mysql_service, mysql_config, and mysql_client resour
|
||||||
source_url 'https://github.com/sous-chefs/mysql'
|
source_url 'https://github.com/sous-chefs/mysql'
|
||||||
issues_url 'https://github.com/sous-chefs/mysql/issues'
|
issues_url 'https://github.com/sous-chefs/mysql/issues'
|
||||||
chef_version '>= 12.7'
|
chef_version '>= 12.7'
|
||||||
version '8.7.3'
|
version '8.7.4'
|
||||||
|
|
||||||
%w(redhat centos scientific oracle).each do |el|
|
%w(redhat centos scientific oracle).each do |el|
|
||||||
supports el, '>= 6.0'
|
supports el, '>= 6.0'
|
||||||
|
|
|
@ -1,5 +1,13 @@
|
||||||
# NodeJS Cookbook Changelog
|
# NodeJS Cookbook Changelog
|
||||||
|
|
||||||
|
## 7.3.3 - *2021-08-30*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 7.3.2 - *2021-06-01*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
## 7.3.1 - *2020-12-31*
|
## 7.3.1 - *2020-12-31*
|
||||||
|
|
||||||
- resolved cookstyle error: attributes/packages.rb:15:55 convention: `Layout/TrailingEmptyLines`
|
- resolved cookstyle error: attributes/packages.rb:15:55 convention: `Layout/TrailingEmptyLines`
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
"recipes": {
|
"recipes": {
|
||||||
|
|
||||||
},
|
},
|
||||||
"version": "7.3.1",
|
"version": "7.3.3",
|
||||||
"source_url": "https://github.com/redguide/nodejs",
|
"source_url": "https://github.com/redguide/nodejs",
|
||||||
"issues_url": "https://github.com/redguide/nodejs/issues",
|
"issues_url": "https://github.com/redguide/nodejs/issues",
|
||||||
"privacy": false,
|
"privacy": false,
|
||||||
|
|
|
@ -6,7 +6,7 @@ description 'Installs/Configures node.js'
|
||||||
source_url 'https://github.com/redguide/nodejs'
|
source_url 'https://github.com/redguide/nodejs'
|
||||||
issues_url 'https://github.com/redguide/nodejs/issues'
|
issues_url 'https://github.com/redguide/nodejs/issues'
|
||||||
chef_version '>= 14'
|
chef_version '>= 14'
|
||||||
version '7.3.1'
|
version '7.3.3'
|
||||||
|
|
||||||
depends 'ark', '>= 2.0.2'
|
depends 'ark', '>= 2.0.2'
|
||||||
depends 'chocolatey', '>= 3.0'
|
depends 'chocolatey', '>= 3.0'
|
||||||
|
|
|
@ -2,6 +2,10 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of the PHP cookbook.
|
This file is used to list changes made in each version of the PHP cookbook.
|
||||||
|
|
||||||
|
## 8.0.1 (2020-11-12)
|
||||||
|
|
||||||
|
- Prevent Apache from being pulled in as a dependency on Ubuntu 20.04 (#311)
|
||||||
|
|
||||||
## 8.0.0 (2020-07-09)
|
## 8.0.0 (2020-07-09)
|
||||||
|
|
||||||
- Drop support for:
|
- Drop support for:
|
||||||
|
|
|
@ -127,8 +127,7 @@ when 'debian'
|
||||||
default['php']['checksum'] = 'a554a510190e726ebe7157fb00b4aceabdb50c679430510a3b93cbf5d7546e44'
|
default['php']['checksum'] = 'a554a510190e726ebe7157fb00b4aceabdb50c679430510a3b93cbf5d7546e44'
|
||||||
default['php']['conf_dir'] = '/etc/php/7.4/cli'
|
default['php']['conf_dir'] = '/etc/php/7.4/cli'
|
||||||
default['php']['src_deps'] = %w(libbz2-dev libc-client2007e-dev libcurl4-gnutls-dev libfreetype6-dev libgmp3-dev libjpeg62-dev libkrb5-dev libmcrypt-dev libpng-dev libssl-dev pkg-config libxml2-dev libsqlite3-dev libonig-dev)
|
default['php']['src_deps'] = %w(libbz2-dev libc-client2007e-dev libcurl4-gnutls-dev libfreetype6-dev libgmp3-dev libjpeg62-dev libkrb5-dev libmcrypt-dev libpng-dev libssl-dev pkg-config libxml2-dev libsqlite3-dev libonig-dev)
|
||||||
# Ubuntu >= 20.04 drops versions from the package names
|
default['php']['packages'] = %w(php7.4-cgi php7.4 php7.4-dev php7.4-cli php-pear)
|
||||||
default['php']['packages'] = %w(php-cgi php php-dev php-cli php-pear)
|
|
||||||
default['php']['fpm_package'] = 'php7.4-fpm'
|
default['php']['fpm_package'] = 'php7.4-fpm'
|
||||||
default['php']['fpm_pooldir'] = '/etc/php/7.4/fpm/pool.d'
|
default['php']['fpm_pooldir'] = '/etc/php/7.4/fpm/pool.d'
|
||||||
default['php']['fpm_service'] = 'php7.4-fpm'
|
default['php']['fpm_service'] = 'php7.4-fpm'
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
{"name":"php","version":"8.0.0","description":"Installs and maintains php and php modules","long_description":"","maintainer":"Sous Chefs","maintainer_email":"help@sous-chefs.org","license":"Apache-2.0","platforms":{"amazon":">= 2.0","centos":">= 7.0","debian":">= 9.0","oracle":">= 7.0","redhat":">= 7.0","scientific":">= 7.0","ubuntu":">= 16.04"},"dependencies":{"yum-epel":">= 0.0.0"},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/sous-chefs/php","issues_url":"https://github.com/sous-chefs/php/issues","chef_version":[[">= 14.0"]],"ohai_version":[]}
|
{"name":"php","version":"8.0.1","description":"Installs and maintains php and php modules","long_description":"","maintainer":"Sous Chefs","maintainer_email":"help@sous-chefs.org","license":"Apache-2.0","platforms":{"amazon":">= 2.0","centos":">= 7.0","debian":">= 9.0","oracle":">= 7.0","redhat":">= 7.0","scientific":">= 7.0","ubuntu":">= 16.04"},"dependencies":{"yum-epel":">= 0.0.0"},"recommendations":{},"suggestions":{},"conflicting":{},"providing":{},"replacing":{},"attributes":{},"groupings":{},"recipes":{},"source_url":"https://github.com/sous-chefs/php","issues_url":"https://github.com/sous-chefs/php/issues","chef_version":[[">= 14.0"]],"ohai_version":[]}
|
|
@ -1,12 +1,12 @@
|
||||||
name 'php'
|
name 'php'
|
||||||
maintainer 'Sous Chefs'
|
maintainer 'Sous Chefs'
|
||||||
maintainer_email 'help@sous-chefs.org'
|
maintainer_email 'help@sous-chefs.org'
|
||||||
license 'Apache-2.0'
|
license 'Apache-2.0'
|
||||||
description 'Installs and maintains php and php modules'
|
description 'Installs and maintains php and php modules'
|
||||||
source_url 'https://github.com/sous-chefs/php'
|
source_url 'https://github.com/sous-chefs/php'
|
||||||
issues_url 'https://github.com/sous-chefs/php/issues'
|
issues_url 'https://github.com/sous-chefs/php/issues'
|
||||||
chef_version '>= 14.0'
|
chef_version '>= 14.0'
|
||||||
version '8.0.0'
|
version '8.0.1'
|
||||||
|
|
||||||
depends 'yum-epel'
|
depends 'yum-epel'
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,104 @@
|
||||||
|
# CHANGELOG for seven_zip
|
||||||
|
|
||||||
|
This file is used to list changes made in each version of seven_zip.
|
||||||
|
|
||||||
|
## 4.2.2 - *2021-08-31*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 4.2.1 - *2021-06-07*
|
||||||
|
|
||||||
|
- [CI] Change ActionsHub actions to main
|
||||||
|
- [CI] Change checkout action to v2
|
||||||
|
- [CI] Change final step to an echo for faster final step
|
||||||
|
|
||||||
|
## 4.2.0 - *2021-06-07*
|
||||||
|
|
||||||
|
- Add remove action to seven_zip_tool
|
||||||
|
|
||||||
|
## 4.1.1 - *2021-06-01*
|
||||||
|
|
||||||
|
- Update delivery configuration
|
||||||
|
|
||||||
|
## 4.1.0 - *2021-05-20*
|
||||||
|
|
||||||
|
- Reduce Chef requirement to >= 15.3
|
||||||
|
|
||||||
|
## 4.0.0 - *2021-04-29*
|
||||||
|
|
||||||
|
- Increase the supported version of Chef to Chef 16
|
||||||
|
|
||||||
|
This is inline with our support policies, allowing us to use the newest Chef features
|
||||||
|
|
||||||
|
- Remove dependency on the deprecated Windows cookbook
|
||||||
|
- Convert to modern custom resources
|
||||||
|
- Remove the default recipe
|
||||||
|
- Remove default_spec as we no longer have a default recipe
|
||||||
|
- Use the Chef `execute` and `directory` resources rather than Ruby methods
|
||||||
|
- Pull Windows helpers from the Windows cookbook and fix them to work in this cookbook
|
||||||
|
|
||||||
|
As the Windows cookbook is no longer maintained many of the methods we used were deprecated
|
||||||
|
in Ruby 2.7 but were never fixed. These methods have now been removed in Ruby 3.0
|
||||||
|
|
||||||
|
- Move resource documentation to the documentation/resource directory.
|
||||||
|
- Update README to reflect new usage
|
||||||
|
|
||||||
|
## 3.2.0 - *2021-01-24*
|
||||||
|
|
||||||
|
- Sous Chefs Adoption
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
- Various Cookstyle fixes
|
||||||
|
- Migrate from ServerSpec to InSpec for integration testing
|
||||||
|
- Update to 7-Zip 19.00
|
||||||
|
|
||||||
|
## 3.1.2
|
||||||
|
|
||||||
|
- Update nokogiri from [1.8.2 to 1.8.5](https://snyk.io/vuln/SNYK-RUBY-NOKOGIRI-72433)
|
||||||
|
|
||||||
|
## 3.1.1
|
||||||
|
|
||||||
|
- Fix deprecation warning regarding the use of `win_friendly_path` helper.
|
||||||
|
|
||||||
|
## 3.1.0
|
||||||
|
|
||||||
|
- Having a simple resource to setup 7-zip allows other resources (since including a recipe inside a resource is not a good pattern) to use it to ensure that their prerequisites are installed before-hand.
|
||||||
|
- This resource leverage existing attributes as default values to keep backward compatibility.
|
||||||
|
- The `seven_zip::default` recipe's code has been refactored to just use this resource.
|
||||||
|
|
||||||
|
## 3.0.0
|
||||||
|
|
||||||
|
- Support Chef 13, drop support for Chef 12.
|
||||||
|
- Upgrade to 7-Zip 18.05.
|
||||||
|
- Standardize testing environment across repos. (AppVeyor, Kitchen, Rake, etc.)
|
||||||
|
- Upgrade development dependencies.
|
||||||
|
|
||||||
|
## 2.0.2
|
||||||
|
|
||||||
|
- Add timeout to extract action on `seven_zip` resource and configurable `default_extract_timeout` attribute.
|
||||||
|
|
||||||
|
## 2.0.1
|
||||||
|
|
||||||
|
- [GH Issue 21 - NoMethodError: Undefined method or attribute kernel on node](https://github.com/daptiv/seven_zip/issues/21).
|
||||||
|
|
||||||
|
## 2.0.0
|
||||||
|
|
||||||
|
- [Upgrade to 7-Zip 15.14](https://github.com/daptiv/seven_zip/pull/9).
|
||||||
|
- [7-Zip now installed to the default MSI location by default](https://github.com/daptiv/seven_zip/pull/11).
|
||||||
|
- [7z.exe is located using the Windows registry unless the home attribute is explicitly set](https://github.com/daptiv/seven_zip/pull/10).
|
||||||
|
- [7-Zip is only added to the Windows PATH if the syspath attribute is set](https://github.com/daptiv/seven_zip/pull/11).
|
||||||
|
- [Installation idempotence check was fixed](https://github.com/daptiv/seven_zip/pull/14), package name was corrected.
|
||||||
|
- [TravisCI build added](https://github.com/daptiv/seven_zip/pull/12).
|
||||||
|
- [ServerSpec tests added](https://github.com/daptiv/seven_zip/pull/9)
|
||||||
|
- [Document Archive LRWP](https://github.com/daptiv/seven_zip/pull/6)
|
||||||
|
|
||||||
|
## 1.0.2
|
||||||
|
|
||||||
|
- [COOK-3476 - Upgrade to 7-zip 9.22](https://tickets.opscode.com/browse/COOK-3476)
|
||||||
|
|
||||||
|
## 1.0.0
|
||||||
|
|
||||||
|
- initial release
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
Refer to the [Markdown Syntax Guide](https://daringfireball.net/projects/markdown/syntax) for help with standard Markdown, and [Writing on GitHub](https://help.github.com/categories/writing-on-github/) for help with the GitHub dialect of Markdown.
|
|
@ -1,8 +0,0 @@
|
||||||
source 'http://rubygems.org'
|
|
||||||
|
|
||||||
gem 'cookstyle'
|
|
||||||
gem 'foodcritic'
|
|
||||||
gem 'rspec-expectations'
|
|
||||||
gem 'rspec-mocks'
|
|
||||||
gem 'rubocop'
|
|
||||||
gem 'stove'
|
|
|
@ -1,79 +0,0 @@
|
||||||
GEM
|
|
||||||
remote: http://rubygems.org/
|
|
||||||
specs:
|
|
||||||
ast (2.4.0)
|
|
||||||
backports (3.11.3)
|
|
||||||
chef-api (0.8.0)
|
|
||||||
logify (~> 0.1)
|
|
||||||
mime-types
|
|
||||||
cookstyle (3.0.0)
|
|
||||||
rubocop (= 0.55.0)
|
|
||||||
cucumber-core (3.1.0)
|
|
||||||
backports (>= 3.8.0)
|
|
||||||
cucumber-tag_expressions (~> 1.1.0)
|
|
||||||
gherkin (>= 5.0.0)
|
|
||||||
cucumber-tag_expressions (1.1.1)
|
|
||||||
diff-lcs (1.3)
|
|
||||||
erubis (2.7.0)
|
|
||||||
ffi-yajl (2.3.1)
|
|
||||||
libyajl2 (~> 1.2)
|
|
||||||
foodcritic (13.1.1)
|
|
||||||
cucumber-core (>= 1.3)
|
|
||||||
erubis
|
|
||||||
ffi-yajl (~> 2.0)
|
|
||||||
nokogiri (>= 1.5, < 2.0)
|
|
||||||
rake
|
|
||||||
rufus-lru (~> 1.0)
|
|
||||||
treetop (~> 1.4)
|
|
||||||
gherkin (5.0.0)
|
|
||||||
libyajl2 (1.2.0)
|
|
||||||
logify (0.2.0)
|
|
||||||
mime-types (3.1)
|
|
||||||
mime-types-data (~> 3.2015)
|
|
||||||
mime-types-data (3.2016.0521)
|
|
||||||
mini_portile2 (2.3.0)
|
|
||||||
nokogiri (1.8.2)
|
|
||||||
mini_portile2 (~> 2.3.0)
|
|
||||||
parallel (1.12.1)
|
|
||||||
parser (2.5.1.0)
|
|
||||||
ast (~> 2.4.0)
|
|
||||||
polyglot (0.3.5)
|
|
||||||
powerpack (0.1.1)
|
|
||||||
rainbow (3.0.0)
|
|
||||||
rake (12.3.1)
|
|
||||||
rspec-expectations (3.7.0)
|
|
||||||
diff-lcs (>= 1.2.0, < 2.0)
|
|
||||||
rspec-support (~> 3.7.0)
|
|
||||||
rspec-mocks (3.7.0)
|
|
||||||
diff-lcs (>= 1.2.0, < 2.0)
|
|
||||||
rspec-support (~> 3.7.0)
|
|
||||||
rspec-support (3.7.1)
|
|
||||||
rubocop (0.55.0)
|
|
||||||
parallel (~> 1.10)
|
|
||||||
parser (>= 2.5)
|
|
||||||
powerpack (~> 0.1)
|
|
||||||
rainbow (>= 2.2.2, < 4.0)
|
|
||||||
ruby-progressbar (~> 1.7)
|
|
||||||
unicode-display_width (~> 1.0, >= 1.0.1)
|
|
||||||
ruby-progressbar (1.9.0)
|
|
||||||
rufus-lru (1.1.0)
|
|
||||||
stove (6.0.0)
|
|
||||||
chef-api (~> 0.5)
|
|
||||||
logify (~> 0.2)
|
|
||||||
treetop (1.6.10)
|
|
||||||
polyglot (~> 0.3)
|
|
||||||
unicode-display_width (1.3.2)
|
|
||||||
|
|
||||||
PLATFORMS
|
|
||||||
ruby
|
|
||||||
|
|
||||||
DEPENDENCIES
|
|
||||||
cookstyle
|
|
||||||
foodcritic
|
|
||||||
rspec-expectations
|
|
||||||
rspec-mocks
|
|
||||||
rubocop
|
|
||||||
stove
|
|
||||||
|
|
||||||
BUNDLED WITH
|
|
||||||
1.16.1
|
|
|
@ -1,11 +1,21 @@
|
||||||
[![Cookbook Version](http://img.shields.io/cookbook/v/seven_zip.svg)](https://supermarket.chef.io/cookbooks/seven_zip)
|
|
||||||
[![Build status](https://ci.appveyor.com/api/projects/status/y1lsnlkd2b3q6gfd/branch/master?svg=true)](https://ci.appveyor.com/project/ChefWindowsCookbooks65871/seven-zip/branch/master)
|
|
||||||
|
|
||||||
# seven_zip Cookbook
|
# seven_zip Cookbook
|
||||||
|
|
||||||
|
[![Cookbook Version](https://img.shields.io/cookbook/v/seven_zip.svg)](https://supermarket.chef.io/cookbooks/seven_zip)
|
||||||
|
[![CI State](https://github.com/sous-chefs/seven_zip/workflows/ci/badge.svg)](https://github.com/sous-chefs/seven_zip/actions?query=workflow%3Aci)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/backers/badge.svg)](#backers)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/sponsors/badge.svg)](#sponsors)
|
||||||
|
[![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)](https://opensource.org/licenses/Apache-2.0)
|
||||||
|
|
||||||
[7-Zip](http://www.7-zip.org/) is a file archiver with a high compression ratio. This cookbook installs the full 7-Zip suite of tools (GUI and CLI). This cookbook replaces the older [7-Zip cookbook](https://github.com/sneal/7-zip).
|
[7-Zip](http://www.7-zip.org/) is a file archiver with a high compression ratio. This cookbook installs the full 7-Zip suite of tools (GUI and CLI). This cookbook replaces the older [7-Zip cookbook](https://github.com/sneal/7-zip).
|
||||||
|
|
||||||
# Requirements
|
## Maintainers
|
||||||
|
|
||||||
|
This cookbook is maintained by the Sous Chefs. The Sous Chefs are a community of Chef cookbook maintainers working together to maintain important cookbooks. If you’d like to know more please visit [sous-chefs.org](https://sous-chefs.org/) or come chat with us on the Chef Community Slack in [#sous-chefs](https://chefcommunity.slack.com/messages/C2V7B88SF).
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
## Platforms
|
## Platforms
|
||||||
|
|
||||||
- Windows XP
|
- Windows XP
|
||||||
- Windows Vista
|
- Windows Vista
|
||||||
- Windows 7
|
- Windows 7
|
||||||
|
@ -16,99 +26,37 @@
|
||||||
- Windows Server 2012 (R1, R2)
|
- Windows Server 2012 (R1, R2)
|
||||||
|
|
||||||
## Chef
|
## Chef
|
||||||
- Chef >= 13.0
|
|
||||||
|
|
||||||
## Cookbooks
|
- Chef >= 16.0
|
||||||
- windows
|
|
||||||
|
|
||||||
# Attributes
|
## Usage
|
||||||
## Optional
|
|
||||||
|
|
||||||
| Key | Type | Description | Default |
|
## Resources
|
||||||
|-----|------|-------------|---------|
|
|
||||||
| `['seven_zip']['home']` | String | 7-Zip installation directory. | |
|
|
||||||
| `['seven_zip']['syspath']` | Boolean | If true, adds 7-Zip directory to system PATH environment variable. | |
|
|
||||||
| `['seven_zip']['default_extract_timeout']` | Integer | The default timeout for an extract operation in seconds. This can be overridden by a resource attribute. | `600` |
|
|
||||||
|
|
||||||
# Usage
|
- [seven_zip_tool](https://github.com/sous-chefs/seven_zip/blob/master/documentation/resources/seven_zip_tool.md)
|
||||||
## default
|
- [seven_zip_archive](https://github.com/sous-chefs/seven_zip/blob/master/documentation/resources/seven_zip_archive.md)
|
||||||
|
|
||||||
Add `seven_zip::default` to your run\_list which will download and install 7-Zip for the current Windows platform.
|
## Contributors
|
||||||
|
|
||||||
# Resource/Provider
|
This project exists thanks to all the people who [contribute.](https://opencollective.com/sous-chefs/contributors.svg?width=890&button=false)
|
||||||
## seven_zip_archive
|
|
||||||
Extracts a 7-Zip compatible archive (iso, zip, 7z, etc.) to the specified destination directory.
|
|
||||||
|
|
||||||
#### Actions
|
### Backers
|
||||||
- `:extract` - Extract a 7-Zip compatible archive.
|
|
||||||
|
|
||||||
#### Attribute Parameters
|
Thank you to all our backers!
|
||||||
- `path` - Name attribute. The destination to extract to.
|
|
||||||
- `source` - The file path to the archive to extract.
|
|
||||||
- `overwrite` - Defaults to false. If true, the destination files will be overwritten.
|
|
||||||
- `checksum` - The archive file checksum.
|
|
||||||
- `timeout` - The extract action timeout in seconds, defaults to `node['seven_zip']['default_extract_timeout']`.
|
|
||||||
|
|
||||||
#### Examples
|
![https://opencollective.com/sous-chefs#backers](https://opencollective.com/sous-chefs/backers.svg?width=600&avatarHeight=40)
|
||||||
Extract 7-Zip source files to `C:\seven_zip_source`.
|
|
||||||
|
|
||||||
```ruby
|
### Sponsors
|
||||||
seven_zip_archive 'seven_zip_source' do
|
|
||||||
path 'C:\seven_zip_source'
|
|
||||||
source 'https://www.7-zip.org/a/7z1805-src.7z'
|
|
||||||
overwrite true
|
|
||||||
checksum 'd9acfcbbdcad078435586e00f73909358ed8d714d106e064dcba52fa73e75d83'
|
|
||||||
timeout 30
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
## seven_zip_tool
|
Support this project by becoming a sponsor. Your logo will show up here with a link to your website.
|
||||||
Download and install 7-zip for the current Windows platform.
|
|
||||||
|
|
||||||
#### Actions
|
![https://opencollective.com/sous-chefs/sponsor/0/website](https://opencollective.com/sous-chefs/sponsor/0/avatar.svg?avatarHeight=100)
|
||||||
- `:install` - Installs 7-zip
|
![https://opencollective.com/sous-chefs/sponsor/1/website](https://opencollective.com/sous-chefs/sponsor/1/avatar.svg?avatarHeight=100)
|
||||||
- `:add_to_path` - Add 7-zip to the PATH
|
![https://opencollective.com/sous-chefs/sponsor/2/website](https://opencollective.com/sous-chefs/sponsor/2/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/3/website](https://opencollective.com/sous-chefs/sponsor/3/avatar.svg?avatarHeight=100)
|
||||||
#### Attribute Parameters
|
![https://opencollective.com/sous-chefs/sponsor/4/website](https://opencollective.com/sous-chefs/sponsor/4/avatar.svg?avatarHeight=100)
|
||||||
- `package` - The name of the package.
|
![https://opencollective.com/sous-chefs/sponsor/5/website](https://opencollective.com/sous-chefs/sponsor/5/avatar.svg?avatarHeight=100)
|
||||||
- `path` - The install directory of 7-zip.
|
![https://opencollective.com/sous-chefs/sponsor/6/website](https://opencollective.com/sous-chefs/sponsor/6/avatar.svg?avatarHeight=100)
|
||||||
- `source` - The source URL of the 7-zip package.
|
![https://opencollective.com/sous-chefs/sponsor/7/website](https://opencollective.com/sous-chefs/sponsor/7/avatar.svg?avatarHeight=100)
|
||||||
- `checksum` - The 7-zip package checksum.
|
![https://opencollective.com/sous-chefs/sponsor/8/website](https://opencollective.com/sous-chefs/sponsor/8/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/9/website](https://opencollective.com/sous-chefs/sponsor/9/avatar.svg?avatarHeight=100)
|
||||||
#### Examples
|
|
||||||
Install 7-zip in `C:\7z` and add it to the path.
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
seven_zip_tool '7z 15.14 install' do
|
|
||||||
action [:install, :add_to_path]
|
|
||||||
package '7-Zip 15.14'
|
|
||||||
path 'C:\7z'
|
|
||||||
source 'http://www.7-zip.org/a/7z1514.msi'
|
|
||||||
checksum 'eaf58e29941d8ca95045946949d75d9b5455fac167df979a7f8e4a6bf2d39680'
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
# Recipes
|
|
||||||
## default
|
|
||||||
|
|
||||||
Installs 7-Zip and adds it to your system PATH.
|
|
||||||
|
|
||||||
# License & Authors
|
|
||||||
- Author:: Seth Chisamore (<schisamo@chef.io>)
|
|
||||||
- Author:: Shawn Neal (<sneal@sneal.net>)
|
|
||||||
|
|
||||||
```text
|
|
||||||
Copyright:: 2011-2016, Chef Software, Inc.
|
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
you may not use this file except in compliance with the License.
|
|
||||||
You may obtain a copy of the License at
|
|
||||||
|
|
||||||
http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
|
|
||||||
Unless required by applicable law or agreed to in writing, software
|
|
||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
See the License for the specific language governing permissions and
|
|
||||||
limitations under the License.
|
|
||||||
```
|
|
||||||
|
|
|
@ -1,42 +0,0 @@
|
||||||
version: "3.1.1.{build}-{branch}"
|
|
||||||
|
|
||||||
image: Visual Studio 2013
|
|
||||||
platform: x64
|
|
||||||
|
|
||||||
environment:
|
|
||||||
machine_user: vagrant
|
|
||||||
machine_pass: vagrant
|
|
||||||
KITCHEN_YAML: .kitchen.appveyor.yml
|
|
||||||
|
|
||||||
branches:
|
|
||||||
only:
|
|
||||||
- master
|
|
||||||
|
|
||||||
# Do not build on tags (GitHub only)
|
|
||||||
skip_tags: true
|
|
||||||
|
|
||||||
#faster cloning
|
|
||||||
clone_depth: 1
|
|
||||||
|
|
||||||
install:
|
|
||||||
- ps: (& cmd /c); iex (irm https://omnitruck.chef.io/install.ps1); Install-Project -Project chefdk -channel stable -version 3.10.1
|
|
||||||
- ps: 'Get-CimInstance win32_operatingsystem -Property Caption, OSArchitecture, Version | fl Caption, OSArchitecture, Version'
|
|
||||||
- ps: $PSVersionTable
|
|
||||||
- c:\opscode\chefdk\bin\chef.bat exec ruby --version
|
|
||||||
- ps: secedit /export /cfg $env:temp/export.cfg
|
|
||||||
- ps: ((get-content $env:temp/export.cfg) -replace ('PasswordComplexity = 1', 'PasswordComplexity = 0')) | Out-File $env:temp/export.cfg
|
|
||||||
- ps: ((get-content $env:temp/export.cfg) -replace ('MinimumPasswordLength = 8', 'MinimumPasswordLength = 0')) | Out-File $env:temp/export.cfg
|
|
||||||
- ps: secedit /configure /db $env:windir/security/new.sdb /cfg $env:temp/export.cfg /areas SECURITYPOLICY
|
|
||||||
- ps: net user /add $env:machine_user $env:machine_pass
|
|
||||||
- ps: net localgroup administrators $env:machine_user /add
|
|
||||||
|
|
||||||
build_script:
|
|
||||||
- ps: c:\opscode\chefdk\bin\chef.bat shell-init powershell | iex; cmd /c c:\opscode\chefdk\bin\chef.bat --version
|
|
||||||
|
|
||||||
test_script:
|
|
||||||
- c:\opscode\chefdk\bin\cookstyle --version
|
|
||||||
- c:\opscode\chefdk\bin\chef.bat exec foodcritic --version
|
|
||||||
- c:\opscode\chefdk\bin\chef.bat exec rake
|
|
||||||
- c:\opscode\chefdk\bin\chef.bat exec kitchen verify
|
|
||||||
|
|
||||||
deploy: off
|
|
|
@ -1,31 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Seth Chisamore (<schisamo@chef.io>)
|
|
||||||
# Cookbook:: seven_zip
|
|
||||||
# Attribute:: default
|
|
||||||
#
|
|
||||||
# Copyright:: 2011-2017, Chef Software, Inc.
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
if node['kernel']['machine'] == 'x86_64'
|
|
||||||
default['seven_zip']['url'] = 'https://www.7-zip.org/a/7z1805-x64.msi'
|
|
||||||
default['seven_zip']['checksum'] = '898c1ca0015183fe2ba7d55cacf0a1dea35e873bf3f8090f362a6288c6ef08d7'
|
|
||||||
default['seven_zip']['package_name'] = '7-Zip 18.05 (x64 edition)'
|
|
||||||
else
|
|
||||||
default['seven_zip']['url'] = 'https://www.7-zip.org/a/7z1805.msi'
|
|
||||||
default['seven_zip']['checksum'] = 'c554238bee18a03d736525e06d9258c9ecf7f64ead7c6b0d1eb04db2c0de30d0'
|
|
||||||
default['seven_zip']['package_name'] = '7-Zip 18.05'
|
|
||||||
end
|
|
||||||
|
|
||||||
default['seven_zip']['default_extract_timeout'] = 600
|
|
|
@ -1,73 +1,85 @@
|
||||||
|
# Put files/directories that should be ignored in this file when uploading
|
||||||
|
# to a Chef Infra Server or Supermarket.
|
||||||
|
# Lines that start with '# ' are comments.
|
||||||
|
|
||||||
# OS generated files #
|
# OS generated files #
|
||||||
######################
|
######################
|
||||||
.DS_Store
|
.DS_Store
|
||||||
|
ehthumbs.db
|
||||||
Icon?
|
Icon?
|
||||||
nohup.out
|
nohup.out
|
||||||
ehthumbs.db
|
|
||||||
Thumbs.db
|
Thumbs.db
|
||||||
|
.envrc
|
||||||
# SASS #
|
|
||||||
########
|
|
||||||
.sass-cache
|
|
||||||
|
|
||||||
# EDITORS #
|
# EDITORS #
|
||||||
###########
|
###########
|
||||||
\#*
|
|
||||||
.#*
|
.#*
|
||||||
*~
|
.project
|
||||||
*.sw[a-z]
|
.settings
|
||||||
|
*_flymake
|
||||||
|
*_flymake.*
|
||||||
*.bak
|
*.bak
|
||||||
|
*.sw[a-z]
|
||||||
|
*.tmproj
|
||||||
|
*~
|
||||||
|
\#*
|
||||||
REVISION
|
REVISION
|
||||||
TAGS*
|
TAGS*
|
||||||
tmtags
|
tmtags
|
||||||
*_flymake.*
|
.vscode
|
||||||
*_flymake
|
.editorconfig
|
||||||
*.tmproj
|
|
||||||
.project
|
|
||||||
.settings
|
|
||||||
mkmf.log
|
|
||||||
|
|
||||||
## COMPILED ##
|
## COMPILED ##
|
||||||
##############
|
##############
|
||||||
a.out
|
*.class
|
||||||
|
*.com
|
||||||
|
*.dll
|
||||||
|
*.exe
|
||||||
*.o
|
*.o
|
||||||
*.pyc
|
*.pyc
|
||||||
*.so
|
*.so
|
||||||
*.com
|
|
||||||
*.class
|
|
||||||
*.dll
|
|
||||||
*.exe
|
|
||||||
*/rdoc/
|
*/rdoc/
|
||||||
|
a.out
|
||||||
|
mkmf.log
|
||||||
|
|
||||||
# Testing #
|
# Testing #
|
||||||
###########
|
###########
|
||||||
.watchr
|
.circleci/*
|
||||||
.rspec
|
|
||||||
spec/*
|
|
||||||
spec/fixtures/*
|
|
||||||
test/*
|
|
||||||
features/*
|
|
||||||
examples/*
|
|
||||||
Guardfile
|
|
||||||
Procfile
|
|
||||||
.kitchen*
|
|
||||||
.rubocop.yml
|
|
||||||
spec/*
|
|
||||||
Rakefile
|
|
||||||
.travis.yml
|
|
||||||
.foodcritic
|
|
||||||
.codeclimate.yml
|
.codeclimate.yml
|
||||||
|
.delivery/*
|
||||||
|
.foodcritic
|
||||||
|
.kitchen*
|
||||||
|
.mdlrc
|
||||||
|
.overcommit.yml
|
||||||
|
.rspec
|
||||||
|
.rubocop.yml
|
||||||
|
.travis.yml
|
||||||
|
.watchr
|
||||||
|
.yamllint
|
||||||
|
azure-pipelines.yml
|
||||||
|
Dangerfile
|
||||||
|
examples/*
|
||||||
|
features/*
|
||||||
|
Guardfile
|
||||||
|
kitchen.yml*
|
||||||
|
mlc_config.json
|
||||||
|
Procfile
|
||||||
|
Rakefile
|
||||||
|
spec/*
|
||||||
|
test/*
|
||||||
|
|
||||||
# SCM #
|
# SCM #
|
||||||
#######
|
#######
|
||||||
.git
|
.git
|
||||||
*/.git
|
|
||||||
.gitignore
|
|
||||||
.gitmodules
|
|
||||||
.gitconfig
|
|
||||||
.gitattributes
|
.gitattributes
|
||||||
|
.gitconfig
|
||||||
|
.github/*
|
||||||
|
.gitignore
|
||||||
|
.gitkeep
|
||||||
|
.gitmodules
|
||||||
.svn
|
.svn
|
||||||
*/.bzr/*
|
*/.bzr/*
|
||||||
|
*/.git
|
||||||
*/.hg/*
|
*/.hg/*
|
||||||
*/.svn/*
|
*/.svn/*
|
||||||
|
|
||||||
|
@ -78,19 +90,24 @@ Berksfile.lock
|
||||||
cookbooks/*
|
cookbooks/*
|
||||||
tmp
|
tmp
|
||||||
|
|
||||||
# Cookbooks #
|
# Bundler #
|
||||||
#############
|
###########
|
||||||
CONTRIBUTING*
|
vendor/*
|
||||||
CHANGELOG*
|
Gemfile
|
||||||
TESTING*
|
Gemfile.lock
|
||||||
MAINTAINERS.toml
|
|
||||||
|
|
||||||
# Strainer #
|
# Policyfile #
|
||||||
############
|
##############
|
||||||
Colanderfile
|
Policyfile.rb
|
||||||
Strainerfile
|
Policyfile.lock.json
|
||||||
.colander
|
|
||||||
.strainer
|
# Documentation #
|
||||||
|
#############
|
||||||
|
CODE_OF_CONDUCT*
|
||||||
|
CONTRIBUTING*
|
||||||
|
documentation/*
|
||||||
|
TESTING*
|
||||||
|
UPGRADING*
|
||||||
|
|
||||||
# Vagrant #
|
# Vagrant #
|
||||||
###########
|
###########
|
||||||
|
|
|
@ -0,0 +1,15 @@
|
||||||
|
---
|
||||||
|
driver:
|
||||||
|
name: exec
|
||||||
|
|
||||||
|
transport:
|
||||||
|
name: exec
|
||||||
|
|
||||||
|
provisioner:
|
||||||
|
name: chef_zero
|
||||||
|
enforce_idempotency: true
|
||||||
|
multiple_converge: 2
|
||||||
|
deprecations_as_errors: true
|
||||||
|
|
||||||
|
platforms:
|
||||||
|
- name: windows-latest
|
|
@ -1,33 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Shawn Neal (<sneal@sneal.net>)
|
|
||||||
# Cookbook:: visualstudio
|
|
||||||
#
|
|
||||||
# Copyright:: 2015-2017, Shawn Neal
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
if defined?(ChefSpec)
|
|
||||||
chefspec_version = Gem.loaded_specs['chefspec'].version
|
|
||||||
define_method = if chefspec_version < Gem::Version.new('4.1.0')
|
|
||||||
ChefSpec::Runner.method(:define_runner_method)
|
|
||||||
else
|
|
||||||
ChefSpec.method(:define_matcher)
|
|
||||||
end
|
|
||||||
|
|
||||||
define_method.call :seven_zip_archive
|
|
||||||
|
|
||||||
def extract_seven_zip_archive(resource_name)
|
|
||||||
ChefSpec::Matchers::ResourceMatcher.new(:seven_zip_archive, :extract, resource_name)
|
|
||||||
end
|
|
||||||
end
|
|
|
@ -1,32 +1,29 @@
|
||||||
{
|
{
|
||||||
"name": "seven_zip",
|
"name": "seven_zip",
|
||||||
"description": "Installs/Configures 7-Zip",
|
"description": "Installs/Configures 7-Zip",
|
||||||
"long_description": "[![Cookbook Version](http://img.shields.io/cookbook/v/seven_zip.svg)](https://supermarket.chef.io/cookbooks/seven_zip)\n[![Build status](https://ci.appveyor.com/api/projects/status/y1lsnlkd2b3q6gfd/branch/master?svg=true)](https://ci.appveyor.com/project/ChefWindowsCookbooks65871/seven-zip/branch/master)\n\n# seven_zip Cookbook\n[7-Zip](http://www.7-zip.org/) is a file archiver with a high compression ratio. This cookbook installs the full 7-Zip suite of tools (GUI and CLI). This cookbook replaces the older [7-Zip cookbook](https://github.com/sneal/7-zip).\n\n# Requirements\n## Platforms\n- Windows XP\n- Windows Vista\n- Windows 7\n- Windows 8, 8.1\n- Windows 10\n- Windows Server 2003 R2\n- Windows Server 2008 (R1, R2)\n- Windows Server 2012 (R1, R2)\n\n## Chef\n- Chef >= 13.0\n\n## Cookbooks\n- windows\n\n# Attributes\n## Optional\n\n| Key | Type | Description | Default |\n|-----|------|-------------|---------|\n| `['seven_zip']['home']` | String | 7-Zip installation directory. | |\n| `['seven_zip']['syspath']` | Boolean | If true, adds 7-Zip directory to system PATH environment variable. | |\n| `['seven_zip']['default_extract_timeout']` | Integer | The default timeout for an extract operation in seconds. This can be overridden by a resource attribute. | `600` |\n\n# Usage\n## default\n\nAdd `seven_zip::default` to your run\\_list which will download and install 7-Zip for the current Windows platform.\n\n# Resource/Provider\n## seven_zip_archive\nExtracts a 7-Zip compatible archive (iso, zip, 7z, etc.) to the specified destination directory.\n\n#### Actions\n- `:extract` - Extract a 7-Zip compatible archive.\n\n#### Attribute Parameters\n- `path` - Name attribute. The destination to extract to.\n- `source` - The file path to the archive to extract.\n- `overwrite` - Defaults to false. If true, the destination files will be overwritten.\n- `checksum` - The archive file checksum.\n- `timeout` - The extract action timeout in seconds, defaults to `node['seven_zip']['default_extract_timeout']`.\n\n#### Examples\nExtract 7-Zip source files to `C:\\seven_zip_source`.\n\n```ruby\nseven_zip_archive 'seven_zip_source' do\n path 'C:\\seven_zip_source'\n source 'https://www.7-zip.org/a/7z1805-src.7z'\n overwrite true\n checksum 'd9acfcbbdcad078435586e00f73909358ed8d714d106e064dcba52fa73e75d83'\n timeout 30\nend\n```\n\n## seven_zip_tool\nDownload and install 7-zip for the current Windows platform.\n\n#### Actions\n- `:install` - Installs 7-zip\n- `:add_to_path` - Add 7-zip to the PATH\n\n#### Attribute Parameters\n- `package` - The name of the package.\n- `path` - The install directory of 7-zip.\n- `source` - The source URL of the 7-zip package.\n- `checksum` - The 7-zip package checksum.\n\n#### Examples\nInstall 7-zip in `C:\\7z` and add it to the path.\n\n```ruby\nseven_zip_tool '7z 15.14 install' do\n action [:install, :add_to_path]\n package '7-Zip 15.14'\n path 'C:\\7z'\n source 'http://www.7-zip.org/a/7z1514.msi'\n checksum 'eaf58e29941d8ca95045946949d75d9b5455fac167df979a7f8e4a6bf2d39680'\nend\n```\n\n# Recipes\n## default\n\nInstalls 7-Zip and adds it to your system PATH.\n\n# License & Authors\n- Author:: Seth Chisamore (<schisamo@chef.io>)\n- Author:: Shawn Neal (<sneal@sneal.net>)\n\n```text\nCopyright:: 2011-2016, Chef Software, Inc.\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n",
|
"long_description": "",
|
||||||
"maintainer": "Shawn Neal",
|
"maintainer": "Sous Chefs",
|
||||||
"maintainer_email": "sneal@sneal.net",
|
"maintainer_email": "help@sous-chefs.org",
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"platforms": {
|
"platforms": {
|
||||||
"windows": ">= 0.0.0"
|
"windows": ">= 0.0.0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"windows": ">= 0.0.0"
|
|
||||||
},
|
|
||||||
"providing": {
|
|
||||||
|
|
||||||
},
|
},
|
||||||
"attributes": {
|
"providing": {
|
||||||
|
|
||||||
},
|
},
|
||||||
"recipes": {
|
"recipes": {
|
||||||
|
|
||||||
},
|
},
|
||||||
"version": "3.1.1",
|
"version": "4.2.2",
|
||||||
"source_url": "https://github.com/windowschefcookbooks/seven_zip",
|
"source_url": "https://github.com/sous-chefs/seven_zip",
|
||||||
"issues_url": "https://github.com/windowschefcookbooks/seven_zip/issues",
|
"issues_url": "https://github.com/sous-chefs/seven_zip/issues",
|
||||||
"privacy": false,
|
"privacy": false,
|
||||||
"chef_versions": [
|
"chef_versions": [
|
||||||
[
|
[
|
||||||
">= 13.0"
|
">= 15.3"
|
||||||
]
|
]
|
||||||
],
|
],
|
||||||
"ohai_versions": [
|
"ohai_versions": [
|
||||||
|
@ -34,5 +31,6 @@
|
||||||
],
|
],
|
||||||
"gems": [
|
"gems": [
|
||||||
|
|
||||||
]
|
],
|
||||||
|
"eager_load_libraries": true
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,11 @@
|
||||||
name 'seven_zip'
|
name 'seven_zip'
|
||||||
maintainer 'Shawn Neal'
|
maintainer 'Sous Chefs'
|
||||||
maintainer_email 'sneal@sneal.net'
|
maintainer_email 'help@sous-chefs.org'
|
||||||
source_url 'https://github.com/windowschefcookbooks/seven_zip'
|
|
||||||
issues_url 'https://github.com/windowschefcookbooks/seven_zip/issues'
|
|
||||||
chef_version '>= 13.0' if respond_to?(:chef_version)
|
|
||||||
license 'Apache-2.0'
|
license 'Apache-2.0'
|
||||||
description 'Installs/Configures 7-Zip'
|
description 'Installs/Configures 7-Zip'
|
||||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
version '4.2.2'
|
||||||
version '3.1.1'
|
source_url 'https://github.com/sous-chefs/seven_zip'
|
||||||
|
issues_url 'https://github.com/sous-chefs/seven_zip/issues'
|
||||||
|
chef_version '>= 15.3'
|
||||||
|
|
||||||
supports 'windows'
|
supports 'windows'
|
||||||
depends 'windows'
|
|
||||||
|
|
|
@ -1,64 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Shawn Neal (<sneal@sneal.net>)
|
|
||||||
# Cookbook:: seven_zip
|
|
||||||
# Provider:: archive
|
|
||||||
#
|
|
||||||
# Copyright:: 2013-2017, Daptiv Solutions LLC
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
require 'fileutils'
|
|
||||||
require 'chef/mixin/shell_out'
|
|
||||||
require 'chef/util/path_helper'
|
|
||||||
|
|
||||||
include Chef::Mixin::ShellOut
|
|
||||||
include Windows::Helper
|
|
||||||
|
|
||||||
def whyrun_supported?
|
|
||||||
true
|
|
||||||
end
|
|
||||||
|
|
||||||
action :extract do
|
|
||||||
converge_by("Extract #{@new_resource.source} => #{@new_resource.path} (overwrite=#{@new_resource.overwrite})") do
|
|
||||||
FileUtils.mkdir_p(@new_resource.path) unless Dir.exist?(@new_resource.path)
|
|
||||||
local_source = cached_file(@new_resource.source, @new_resource.checksum)
|
|
||||||
overwrite_file = @new_resource.overwrite ? ' -y' : ' -aos'
|
|
||||||
cmd = "\"#{seven_zip_exe}\" x"
|
|
||||||
cmd << overwrite_file
|
|
||||||
cmd << " -o\"#{Chef::Util::PathHelper.cleanpath(@new_resource.path)}\""
|
|
||||||
cmd << " \"#{local_source}\""
|
|
||||||
Chef::Log.debug(cmd)
|
|
||||||
shell_out!(cmd, timeout: extract_timeout)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
def seven_zip_exe
|
|
||||||
path = node['seven_zip']['home'] || seven_zip_exe_from_registry
|
|
||||||
Chef::Log.debug("Using 7-zip home: #{path}")
|
|
||||||
Chef::Util::PathHelper.cleanpath(::File.join(path, '7z.exe'))
|
|
||||||
end
|
|
||||||
|
|
||||||
def seven_zip_exe_from_registry
|
|
||||||
require 'win32/registry'
|
|
||||||
# Read path from recommended Windows App Paths registry location
|
|
||||||
# docs: https://msdn.microsoft.com/en-us/library/windows/desktop/ee872121
|
|
||||||
::Win32::Registry::HKEY_LOCAL_MACHINE.open(
|
|
||||||
'SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\7zFM.exe',
|
|
||||||
::Win32::Registry::KEY_READ
|
|
||||||
).read_s('Path')
|
|
||||||
end
|
|
||||||
|
|
||||||
def extract_timeout
|
|
||||||
@new_resource.timeout || node['seven_zip']['default_extract_timeout']
|
|
||||||
end
|
|
|
@ -1,24 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Seth Chisamore (<schisamo@chef.io>)
|
|
||||||
# Cookbook:: seven_zip
|
|
||||||
# Recipe:: default
|
|
||||||
#
|
|
||||||
# Copyright:: 2011-2017, Chef Software, Inc.
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
# Install 7z and optionally add it to path
|
|
||||||
seven_zip_tool 'install seven_zip' do
|
|
||||||
action [:install, :add_to_path] if node['seven_zip']['syspath']
|
|
||||||
end
|
|
|
@ -1,29 +1,92 @@
|
||||||
#
|
unified_mode true
|
||||||
# Author:: Shawn Neal (<sneal@sneal.net>)
|
|
||||||
# Cookbook:: seven_zip
|
|
||||||
# Resource:: archive
|
|
||||||
#
|
|
||||||
# Copyright:: 2013-2017, Daptiv Solutions LLC
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
default_action :extract
|
property :path,
|
||||||
|
String,
|
||||||
|
name_property: true,
|
||||||
|
description: 'Path to extract the archive.'
|
||||||
|
|
||||||
actions :extract
|
property :source,
|
||||||
|
String,
|
||||||
|
description: 'Source archive location.'
|
||||||
|
|
||||||
attribute :path, kind_of: String, name_attribute: true
|
property :overwrite,
|
||||||
attribute :source, kind_of: String
|
[true, false],
|
||||||
attribute :overwrite, kind_of: [TrueClass, FalseClass], default: false
|
default: false,
|
||||||
attribute :checksum, kind_of: String
|
description: 'Whether to overwrite the destination files.'
|
||||||
attribute :timeout, kind_of: Integer
|
|
||||||
|
property :checksum,
|
||||||
|
String,
|
||||||
|
description: 'The checksum for the downloaded file.'
|
||||||
|
|
||||||
|
property :timeout,
|
||||||
|
Integer,
|
||||||
|
default: 600,
|
||||||
|
description: 'Extract timeout in seconds.'
|
||||||
|
|
||||||
|
action :extract do
|
||||||
|
directory new_resource.path
|
||||||
|
|
||||||
|
local_source = cached_file(new_resource.source, new_resource.checksum)
|
||||||
|
|
||||||
|
overwrite_file = new_resource.overwrite ? ' -y' : ' -aos'
|
||||||
|
|
||||||
|
cmd = "\"#{seven_zip_exe}\" x"
|
||||||
|
cmd << overwrite_file
|
||||||
|
cmd << " -o\"#{Chef::Util::PathHelper.cleanpath(new_resource.path)}\""
|
||||||
|
cmd << " \"#{local_source}\""
|
||||||
|
|
||||||
|
Chef::Log.debug(cmd)
|
||||||
|
|
||||||
|
execute "extracting #{new_resource.source}" do
|
||||||
|
command cmd
|
||||||
|
timeout new_resource.timeout
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
action_class do
|
||||||
|
# require 'chef/mixin/shell_out'
|
||||||
|
# include Chef::Mixin::ShellOut
|
||||||
|
|
||||||
|
def seven_zip_exe
|
||||||
|
path = seven_zip_exe_from_registry
|
||||||
|
Chef::Log.debug("Using 7-zip home: #{path}")
|
||||||
|
Chef::Util::PathHelper.cleanpath(::File.join(path, '7z.exe'))
|
||||||
|
end
|
||||||
|
|
||||||
|
def seven_zip_exe_from_registry
|
||||||
|
require 'win32/registry'
|
||||||
|
# Read path from recommended Windows App Paths registry location
|
||||||
|
# docs: https://msdn.microsoft.com/en-us/library/windows/desktop/ee872121
|
||||||
|
::Win32::Registry::HKEY_LOCAL_MACHINE.open(
|
||||||
|
'SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\7zFM.exe',
|
||||||
|
::Win32::Registry::KEY_READ
|
||||||
|
).read_s('Path')
|
||||||
|
end
|
||||||
|
|
||||||
|
# if a file is local it returns a windows friendly path version
|
||||||
|
# if a file is remote it caches it locally
|
||||||
|
def cached_file(source, checksum = nil)
|
||||||
|
if source =~ %r{^(file|ftp|http|https):\/\/}
|
||||||
|
uri = as_uri(source)
|
||||||
|
cache_file_path = "#{Chef::Config[:file_cache_path]}/#{::File.basename(::CGI.unescape(uri.path))}"
|
||||||
|
Chef::Log.debug("Caching a copy of file #{source} at #{cache_file_path}")
|
||||||
|
|
||||||
|
remote_file cache_file_path do
|
||||||
|
source source
|
||||||
|
backup false
|
||||||
|
checksum checksum unless checksum.nil?
|
||||||
|
end
|
||||||
|
else
|
||||||
|
cache_file_path = source
|
||||||
|
end
|
||||||
|
|
||||||
|
Chef::Util::PathHelper.cleanpath(cache_file_path)
|
||||||
|
end
|
||||||
|
|
||||||
|
def as_uri(source)
|
||||||
|
URI.parse(source)
|
||||||
|
rescue URI::InvalidURIError
|
||||||
|
Chef::Log.warn("#{source} was an invalid URI. Trying to escape invalid characters")
|
||||||
|
URI.parse(URI.escape(source))
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
|
@ -1,26 +1,23 @@
|
||||||
#
|
unified_mode true
|
||||||
# Author:: Annih (<b.courtois@criteo.com>)
|
|
||||||
# Cookbook:: seven_zip
|
property :package,
|
||||||
# Resource:: tool
|
String,
|
||||||
#
|
description: 'Name of the package to install.',
|
||||||
# Copyright:: 2018, Baptiste Courtois
|
default: node['kernel']['machine'] == 'x86_64' ? '7-Zip 19.00 (x64 edition)' : '7-Zip 19.00'
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
property :source,
|
||||||
# you may not use this file except in compliance with the License.
|
String,
|
||||||
# You may obtain a copy of the License at
|
description: 'Source URL of the package to install.',
|
||||||
#
|
default: node['kernel']['machine'] == 'x86_64' ? 'https://www.7-zip.org/a/7z1900-x64.msi' : 'https://www.7-zip.org/a/7z1900.msi'
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
property :checksum,
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
String,
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
description: 'Checksum for the downloaded pacakge.',
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
default: node['kernel']['machine'] == 'x86_64' ? 'a7803233eedb6a4b59b3024ccf9292a6fffb94507dc998aa67c5b745d197a5dc' : 'b49d55a52bc0eab14947c8982c413d9be141c337da1368a24aa0484cbb5e89cd'
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
property :path,
|
||||||
#
|
String,
|
||||||
property :package, ::String, default: lazy { node['seven_zip']['package_name'] }
|
description: 'Optional: path to install 7zip to.'
|
||||||
property :source, ::String, default: lazy { node['seven_zip']['url'] }
|
|
||||||
property :checksum, [::NilClass, ::String], default: lazy { node['seven_zip']['checksum'] }
|
|
||||||
property :path, [::NilClass, ::String], default: lazy { node['seven_zip']['home'] }
|
|
||||||
|
|
||||||
action :install do
|
action :install do
|
||||||
windows_package new_resource.package do
|
windows_package new_resource.package do
|
||||||
|
@ -38,6 +35,12 @@ action :add_to_path do
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
action :remove do
|
||||||
|
windows_package new_resource.package do
|
||||||
|
action :remove
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
action_class do
|
action_class do
|
||||||
REG_PATH = 'SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\7zFM.exe'.freeze
|
REG_PATH = 'SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\7zFM.exe'.freeze
|
||||||
|
|
||||||
|
|
|
@ -2,6 +2,49 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of the windows cookbook.
|
This file is used to list changes made in each version of the windows cookbook.
|
||||||
|
|
||||||
|
## 7.0.2 (2020-09-10)
|
||||||
|
|
||||||
|
- Resolve a typo in the user_privilege resource - [@tas50](https://github.com/tas50)
|
||||||
|
- Don't run delivery in Appveyor - [@tas50](https://github.com/tas50)
|
||||||
|
|
||||||
|
## 7.0.1 (2020-09-10)
|
||||||
|
|
||||||
|
- Remove testing of Windows 2008 R2 - [@tas50](https://github.com/tas50)
|
||||||
|
- Cookstyle 6.2.9 Fixes - [@xorimabot](https://github.com/xorimabot)
|
||||||
|
- Avoid deprcation warnings when using user_privilege resource on Chef >= - [@tas50](https://github.com/tas50)
|
||||||
|
|
||||||
|
## Unreleased
|
||||||
|
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:69:9 refactor: `ChefCorrectness/ChefApplicationFatal`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:232:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:234:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:244:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:245:7 convention: `Style/EmptyElse`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:246:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:272:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/registry_helper.rb:274:9 convention: `Style/RedundantReturn`
|
||||||
|
- resolved cookstyle error: libraries/windows_helper.rb:165:14 warning: `Lint/SendWithMixinArgument`
|
||||||
|
|
||||||
|
## 7.0.0 (2020-03-26)
|
||||||
|
|
||||||
|
### Breaking Changes
|
||||||
|
|
||||||
|
- This cookbook now requires Chef Infra Client 14.7 and later as it no longer includes the `windows_share` and `windows_certificate` resources that are now built into Chef Infra Client.
|
||||||
|
|
||||||
|
### Other Changes
|
||||||
|
|
||||||
|
- Remove list of actions in the dns resource - [@tas50](https://github.com/tas50)
|
||||||
|
- Don't set the guard_interpreter in powershell_script - [@tas50](https://github.com/tas50)
|
||||||
|
- Add windows_schannel resource (#619) - [@Xorima](https://github.com/Xorima)
|
||||||
|
- Remove desired_state: true from resources - [@tas50](https://github.com/tas50)
|
||||||
|
- The host_name property in the dns resource doesn't need to be a name property - [@tas50](https://github.com/tas50)
|
||||||
|
- Remove unnecessary include of the powershell mixin - [@tas50](https://github.com/tas50)
|
||||||
|
|
||||||
|
## 6.0.1 (2019-10-01)
|
||||||
|
|
||||||
|
- Update README.md for Windows cookbook suggesting core dns resources (#616) - [@NAshwini](https://github.com/NAshwini)
|
||||||
|
- Add a warning when using windows_zipfile resource as users should migrate to archive_file (#617) - [@NAshwini](https://github.com/NAshwini)
|
||||||
|
|
||||||
## 6.0.0 (2019-04-25)
|
## 6.0.0 (2019-04-25)
|
||||||
|
|
||||||
### Breaking Changes
|
### Breaking Changes
|
||||||
|
|
|
@ -8,83 +8,21 @@ Provides a set of Windows-specific resources to aid in the creation of cookbooks
|
||||||
|
|
||||||
### Platforms
|
### Platforms
|
||||||
|
|
||||||
- Windows 7
|
- Windows 7 (EOL)
|
||||||
- Windows Server 2008 R2
|
- Windows Server 2008 R2 (EOL)
|
||||||
- Windows 8, 8.1
|
- Windows 8, 8.1
|
||||||
- Windows Server 2012 (R1, R2)
|
- Windows Server 2012 (R1, R2)
|
||||||
- Windows Server 2016
|
- Windows Server 2016
|
||||||
|
|
||||||
### Chef
|
### Chef
|
||||||
|
|
||||||
- Chef 14+
|
- Chef 14.7+
|
||||||
|
|
||||||
## Resources
|
## Resources
|
||||||
|
|
||||||
### Deprecated Resources Note
|
|
||||||
|
|
||||||
As of Chef 14.7+ the windows_share and windows_certificate resources are now included in the Chef Client. If you are running Chef 14.7+ the resources in Chef client will take precedence over the resources in this cookbook. In November 2019 we will release a new major version of this cookbook that removes these resources.
|
|
||||||
|
|
||||||
### windows_certificate
|
|
||||||
|
|
||||||
`Note`: This resource is now included in Chef 14.7 and later. There is no need to depend on the Windows cookbook for this resource.
|
|
||||||
|
|
||||||
Installs a certificate into the Windows certificate store from a file, and grants read-only access to the private key for designated accounts. Due to current limitations in WinRM, installing certificated remotely may not work if the operation requires a user profile. Operations on the local machine store should still work.
|
|
||||||
|
|
||||||
#### Actions
|
|
||||||
|
|
||||||
- `:create` - creates or updates a certificate.
|
|
||||||
- `:delete` - deletes a certificate.
|
|
||||||
- `:acl_add` - adds read-only entries to a certificate's private key ACL.
|
|
||||||
- `:verify` - logs whether or not a certificate is valid
|
|
||||||
|
|
||||||
#### Properties
|
|
||||||
|
|
||||||
- `source` - name attribute. The source file (for create and acl_add), thumbprint (for delete and acl_add) or subject (for delete).
|
|
||||||
- `pfx_password` - the password to access the source if it is a pfx file.
|
|
||||||
- `private_key_acl` - array of 'domain\account' entries to be granted read-only access to the certificate's private key. This is not idempotent.
|
|
||||||
- `store_name` - the certificate store to manipulate. One of:
|
|
||||||
- MY (Personal)
|
|
||||||
- CA (Intermediate Certification Authorities)
|
|
||||||
- ROOT (Trusted Root Certification Authorities)
|
|
||||||
- TRUSTEDPUBLISHER (Trusted Publishers)
|
|
||||||
- CLIENTAUTHISSUER (Client Authentication Issuers)
|
|
||||||
- REMOTE DESKTOP (Remote Desktop)
|
|
||||||
- TRUSTEDDEVICES (Trusted Devices)
|
|
||||||
- WEBHOSTING (Web Hosting)
|
|
||||||
- AUTHROOT (Third-Party Root Certification Authorities)
|
|
||||||
- TRUSTEDPEOPLE (Trusted People)
|
|
||||||
- SMARTCARDROOT (Smart Card Trusted Roots)
|
|
||||||
- TRUST (Enterprise Trust)
|
|
||||||
- DISALLOWED (Untrusted Certificates)
|
|
||||||
- `user_store` - if false (default) then use the local machine store; if true then use the current user's store.
|
|
||||||
|
|
||||||
#### Examples
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
# Add PFX cert to local machine personal store and grant accounts read-only access to private key
|
|
||||||
windows_certificate "c:/test/mycert.pfx" do
|
|
||||||
pfx_password "password"
|
|
||||||
private_key_acl ["acme\fred", "pc\jane"]
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
# Add cert to trusted intermediate store
|
|
||||||
windows_certificate "c:/test/mycert.cer" do
|
|
||||||
store_name "CA"
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
# Remove all certificates matching the subject
|
|
||||||
windows_certificate "me.acme.com" do
|
|
||||||
action :delete
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
### windows_certificate_binding
|
### windows_certificate_binding
|
||||||
|
|
||||||
Binds a certificate to an HTTP port in order to enable TLS communication.
|
Binds a certificate to an HTTP port to enable TLS communication.
|
||||||
|
|
||||||
#### Actions
|
#### Actions
|
||||||
|
|
||||||
|
@ -135,6 +73,8 @@ end
|
||||||
|
|
||||||
### windows_dns
|
### windows_dns
|
||||||
|
|
||||||
|
`Note`: This resource is now included in Chef 15 and later. If you are using newer versions of [windows](https://devblogs.microsoft.com/powershell/configuration-in-a-devops-world-windows-powershell-desired-state-configuration/) then should use the core [resource](https://github.com/chef/chef/blob/master/RELEASE_NOTES.md#windows_dns_record-resource) instead of windows_dns.
|
||||||
|
|
||||||
Configures A and CNAME records in Windows DNS. This requires the DNSCMD to be installed, which is done by adding the DNS role to the server or installing the Remote Server Admin Tools.
|
Configures A and CNAME records in Windows DNS. This requires the DNSCMD to be installed, which is done by adding the DNS role to the server or installing the Remote Server Admin Tools.
|
||||||
|
|
||||||
#### Actions
|
#### Actions
|
||||||
|
@ -213,52 +153,19 @@ windows_http_acl 'http://+:50051/' do
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
### windows_share
|
### windows_schannel
|
||||||
|
|
||||||
`Note`: This resource is now included in Chef 14.7 and later. There is no need to depend on the Windows cookbook for this resource.
|
Used to configure the schannel security settings in windows, this is used by dotnet apps and PowerShell to be able to speak to tls 1.2 endpoints
|
||||||
|
|
||||||
Creates, modifies and removes Windows shares. All properties are idempotent.
|
|
||||||
|
|
||||||
`Note`: This resource uses PowerShell cmdlets introduced in Windows 2012/8.
|
|
||||||
|
|
||||||
#### Actions
|
#### Actions
|
||||||
|
|
||||||
- `:create`: creates/modifies a share
|
- `configure`: Configures the setting
|
||||||
- `:delete`: deletes a share
|
|
||||||
|
|
||||||
#### Properties
|
#### Properties
|
||||||
|
|
||||||
property | type | default | description
|
property | type | default | description
|
||||||
------------------------ | ---------- | ------------- | -----------------------------------------------------------------------------------------------------------------------------------------------------------
|
------------------------ | ---------- | ------------- | -----------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||||
`share_name` | String | resource name | the share to assign to the share
|
`use_strong_crypto` | True, False | true | Enables or disables the setting
|
||||||
`path` | String | | The path of the location of the folder to share. Required when creating. If the share already exists on a different path then it is deleted and re-created.
|
|
||||||
`description` | String | | description to be applied to the share
|
|
||||||
`full_users` | Array | [] | users which should have "Full control" permissions
|
|
||||||
`change_users` | Array | [] | Users are granted modify permission to access the share.
|
|
||||||
`read_users` | Array | [] | users which should have "Read" permissions
|
|
||||||
`temporary` | True/False | false | The lifetime of the new SMB share. A temporary share does not persist beyond the next restart of the computer
|
|
||||||
`scope_name` | String | '*' | The scope name of the share.
|
|
||||||
`ca_timeout` | Integer | 0 | The continuous availability time-out for the share.
|
|
||||||
`continuously_available` | True/False | false | Indicates that the share is continuously available.
|
|
||||||
`concurrent_user_limit` | Integer | 0 (unlimited) | The maximum number of concurrently connected users the share can accommodate
|
|
||||||
`encrypt_data` | True/False | false | Indicates that the share is encrypted.
|
|
||||||
|
|
||||||
#### Examples
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
windows_share "foo" do
|
|
||||||
action :create
|
|
||||||
path "C:\\foo"
|
|
||||||
full_users ["DOMAIN_A\\some_user", "DOMAIN_B\\some_other_user"]
|
|
||||||
read_users ["DOMAIN_C\\Domain users"]
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
windows_share "foo" do
|
|
||||||
action :delete
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
### windows_user_privilege
|
### windows_user_privilege
|
||||||
|
|
||||||
|
@ -345,7 +252,9 @@ SeTakeOwnershipPrivilege Take ownership of files or other objects
|
||||||
|
|
||||||
### windows_zipfile
|
### windows_zipfile
|
||||||
|
|
||||||
Most version of Windows do not ship with native cli utility for managing compressed files. This resource provides a pure-ruby implementation for managing zip files. Be sure to use the `not_if` or `only_if` meta parameters to guard the resource for idempotence or action will be taken every Chef run.
|
`Note`: This resource has been deprecated as Chef Infra Client 15.0 shipped with a new archive_file resource, which natively handles multiple archive formats. Please update any cookbooks using this resource to instead use the `archive_file` resource: https://docs.chef.io/resource_archive_file.html
|
||||||
|
|
||||||
|
Most versions of Windows do not ship with native cli utility for managing compressed files. This resource provides a pure-ruby implementation for managing zip files. Be sure to use the `not_if` or `only_if` meta parameters to guard the resource for idempotence or action will be taken every Chef run.
|
||||||
|
|
||||||
#### Actions
|
#### Actions
|
||||||
|
|
||||||
|
@ -401,7 +310,7 @@ Returns a hash of all DisplayNames installed
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
# usage in a recipe
|
# usage in a recipe
|
||||||
::Chef::Recipe.send(:include, Windows::Helper)
|
::Chef::DSL::Recipe.send(:include, Windows::Helper)
|
||||||
hash_of_installed_packages = installed_packages
|
hash_of_installed_packages = installed_packages
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -414,7 +323,7 @@ Download a file if a package isn't installed
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
# usage in a recipe to not download a file if package is already installed
|
# usage in a recipe to not download a file if package is already installed
|
||||||
::Chef::Recipe.send(:include, Windows::Helper)
|
::Chef::DSL::Recipe.send(:include, Windows::Helper)
|
||||||
is_win_sdk_installed = is_package_installed?('Windows Software Development Kit')
|
is_win_sdk_installed = is_package_installed?('Windows Software Development Kit')
|
||||||
|
|
||||||
remote_file 'C:\windows\temp\windows_sdk.zip' do
|
remote_file 'C:\windows\temp\windows_sdk.zip' do
|
||||||
|
@ -436,11 +345,11 @@ end
|
||||||
|
|
||||||
### Windows::VersionHelper
|
### Windows::VersionHelper
|
||||||
|
|
||||||
Helper that allows you to get information of the windows version running on your node. It leverages windows ohai from kernel.os_info, easy to mock and to use even on linux.
|
Helper that allows you to get information on the windows version running on your node. It leverages windows ohai from kernel.os_info, easy to mock and to use even on Linux.
|
||||||
|
|
||||||
#### core_version?
|
#### core_version?
|
||||||
|
|
||||||
Determines whether given node is running on a windows Core.
|
Determines whether the given node is running on a Windows Core.
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
if ::Windows::VersionHelper.core_version? node
|
if ::Windows::VersionHelper.core_version? node
|
||||||
|
@ -450,7 +359,7 @@ end
|
||||||
|
|
||||||
#### workstation_version?
|
#### workstation_version?
|
||||||
|
|
||||||
Determines whether given node is a windows workstation version (XP, Vista, 7, 8, 8.1, 10)
|
Determines whether the given node is a windows workstation version (XP, Vista, 7, 8, 8.1, 10)
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
if ::Windows::VersionHelper.workstation_version? node
|
if ::Windows::VersionHelper.workstation_version? node
|
||||||
|
@ -460,7 +369,7 @@ end
|
||||||
|
|
||||||
#### server_version?
|
#### server_version?
|
||||||
|
|
||||||
Determines whether given node is a windows server version (Server 2003, Server 2008, Server 2012, Server 2016)
|
Determines whether the given node is a windows server version (Server 2003, Server 2008, Server 2012, Server 2016)
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
if ::Windows::VersionHelper.server_version? node
|
if ::Windows::VersionHelper.server_version? node
|
||||||
|
|
|
@ -66,7 +66,7 @@ module Windows
|
||||||
}[hkey]
|
}[hkey]
|
||||||
|
|
||||||
unless hive
|
unless hive
|
||||||
Chef::Application.fatal!("Unsupported registry hive '#{hive_name}'")
|
raise("Unsupported registry hive '#{hive_name}'")
|
||||||
end
|
end
|
||||||
|
|
||||||
Chef::Log.debug("Registry hive resolved to #{hkey}")
|
Chef::Log.debug("Registry hive resolved to #{hkey}")
|
||||||
|
@ -229,9 +229,9 @@ module Windows
|
||||||
|
|
||||||
begin
|
begin
|
||||||
hive.open(key, ::Win32::Registry::Constants::KEY_READ | @@native_registry_constant)
|
hive.open(key, ::Win32::Registry::Constants::KEY_READ | @@native_registry_constant)
|
||||||
return true
|
true
|
||||||
rescue
|
rescue
|
||||||
return false
|
false
|
||||||
ensure
|
ensure
|
||||||
ensure_hive_unloaded(hive_loaded)
|
ensure_hive_unloaded(hive_loaded)
|
||||||
end
|
end
|
||||||
|
@ -241,9 +241,7 @@ module Windows
|
||||||
reg_key = "HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\ProfileList\\#{sid}"
|
reg_key = "HKLM\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\ProfileList\\#{sid}"
|
||||||
Chef::Log.debug("Looking for profile at #{reg_key}")
|
Chef::Log.debug("Looking for profile at #{reg_key}")
|
||||||
if key_exists?(reg_key)
|
if key_exists?(reg_key)
|
||||||
return get_value(reg_key, 'ProfileImagePath')
|
get_value(reg_key, 'ProfileImagePath')
|
||||||
else
|
|
||||||
return nil
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -269,9 +267,9 @@ module Windows
|
||||||
user_hive = path[0]
|
user_hive = path[0]
|
||||||
|
|
||||||
if user_hive?(hive)
|
if user_hive?(hive)
|
||||||
return key_exists?("#{hive_name}\\#{user_hive}")
|
key_exists?("#{hive_name}\\#{user_hive}")
|
||||||
else
|
else
|
||||||
return true
|
true
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -162,4 +162,4 @@ module Windows
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
Chef::Recipe.send(:include, Windows::Helper)
|
Chef::Recipe.include Windows::Helper
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -3,9 +3,8 @@ maintainer 'Chef Software, Inc.'
|
||||||
maintainer_email 'cookbooks@chef.io'
|
maintainer_email 'cookbooks@chef.io'
|
||||||
license 'Apache-2.0'
|
license 'Apache-2.0'
|
||||||
description 'Provides a set of useful Windows-specific primitives.'
|
description 'Provides a set of useful Windows-specific primitives.'
|
||||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
version '7.0.2'
|
||||||
version '6.0.0'
|
|
||||||
supports 'windows'
|
supports 'windows'
|
||||||
source_url 'https://github.com/chef-cookbooks/windows'
|
source_url 'https://github.com/chef-cookbooks/windows'
|
||||||
issues_url 'https://github.com/chef-cookbooks/windows/issues'
|
issues_url 'https://github.com/chef-cookbooks/windows/issues'
|
||||||
chef_version '>= 14'
|
chef_version '>= 14.7'
|
||||||
|
|
|
@ -23,11 +23,6 @@
|
||||||
|
|
||||||
include Windows::Helper
|
include Windows::Helper
|
||||||
|
|
||||||
# Support whyrun
|
|
||||||
def whyrun_supported?
|
|
||||||
true
|
|
||||||
end
|
|
||||||
|
|
||||||
action :create do
|
action :create do
|
||||||
if @current_resource.exists
|
if @current_resource.exists
|
||||||
needs_change = (@new_resource.record_type != @current_resource.record_type) ||
|
needs_change = (@new_resource.record_type != @current_resource.record_type) ||
|
||||||
|
|
|
@ -1,301 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Richard Lavey (richard.lavey@calastone.com)
|
|
||||||
# Cookbook:: windows
|
|
||||||
# Resource:: certificate
|
|
||||||
#
|
|
||||||
# Copyright:: 2015-2017, Calastone Ltd.
|
|
||||||
# Copyright:: 2018-2019, Chef Software, Inc.
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
require 'chef/util/path_helper'
|
|
||||||
|
|
||||||
chef_version_for_provides '< 14.7' if respond_to?(:chef_version_for_provides)
|
|
||||||
resource_name :windows_certificate
|
|
||||||
|
|
||||||
property :source, String, name_property: true
|
|
||||||
property :pfx_password, String
|
|
||||||
property :private_key_acl, Array
|
|
||||||
property :store_name, String, default: 'MY', equal_to: ['TRUSTEDPUBLISHER', 'TrustedPublisher', 'CLIENTAUTHISSUER', 'REMOTE DESKTOP', 'ROOT', 'TRUSTEDDEVICES', 'WEBHOSTING', 'CA', 'AUTHROOT', 'TRUSTEDPEOPLE', 'MY', 'SMARTCARDROOT', 'TRUST', 'DISALLOWED']
|
|
||||||
property :user_store, [TrueClass, FalseClass], default: false
|
|
||||||
property :cert_path, String
|
|
||||||
property :sensitive, [ TrueClass, FalseClass ], default: lazy { |r| r.pfx_password ? true : false }
|
|
||||||
|
|
||||||
action :create do
|
|
||||||
load_gem
|
|
||||||
|
|
||||||
# Extension of the certificate
|
|
||||||
ext = ::File.extname(new_resource.source)
|
|
||||||
cert_obj = fetch_cert_object(ext) # Fetch OpenSSL::X509::Certificate object
|
|
||||||
thumbprint = OpenSSL::Digest::SHA1.new(cert_obj.to_der).to_s # Fetch its thumbprint
|
|
||||||
|
|
||||||
# Need to check if return value is Boolean:true
|
|
||||||
# If not then the given certificate should be added in certstore
|
|
||||||
if verify_cert(thumbprint) == true
|
|
||||||
Chef::Log.debug('Certificate is already present')
|
|
||||||
else
|
|
||||||
converge_by("Adding certificate #{new_resource.source} into Store #{new_resource.store_name}") do
|
|
||||||
if ext == '.pfx'
|
|
||||||
add_pfx_cert
|
|
||||||
else
|
|
||||||
add_cert(cert_obj)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# acl_add is a modify-if-exists operation : not idempotent
|
|
||||||
action :acl_add do
|
|
||||||
if ::File.exist?(new_resource.source)
|
|
||||||
hash = '$cert.GetCertHashString()'
|
|
||||||
code_script = cert_script(false)
|
|
||||||
guard_script = cert_script(false)
|
|
||||||
else
|
|
||||||
# make sure we have no spaces in the hash string
|
|
||||||
hash = "\"#{new_resource.source.gsub(/\s/, '')}\""
|
|
||||||
code_script = ''
|
|
||||||
guard_script = ''
|
|
||||||
end
|
|
||||||
code_script << acl_script(hash)
|
|
||||||
guard_script << cert_exists_script(hash)
|
|
||||||
|
|
||||||
powershell_script "setting the acls on #{new_resource.source} in #{cert_location}\\#{new_resource.store_name}" do
|
|
||||||
guard_interpreter :powershell_script
|
|
||||||
convert_boolean_return true
|
|
||||||
code code_script
|
|
||||||
only_if guard_script
|
|
||||||
sensitive if new_resource.sensitive
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
action :delete do
|
|
||||||
load_gem
|
|
||||||
|
|
||||||
cert_obj = fetch_cert
|
|
||||||
if cert_obj
|
|
||||||
converge_by("Deleting certificate #{new_resource.source} from Store #{new_resource.store_name}") do
|
|
||||||
delete_cert
|
|
||||||
end
|
|
||||||
else
|
|
||||||
Chef::Log.debug('Certificate not found')
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
action :fetch do
|
|
||||||
load_gem
|
|
||||||
|
|
||||||
cert_obj = fetch_cert
|
|
||||||
if cert_obj
|
|
||||||
show_or_store_cert(cert_obj)
|
|
||||||
else
|
|
||||||
Chef::Log.debug('Certificate not found')
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
action :verify do
|
|
||||||
load_gem
|
|
||||||
|
|
||||||
out = verify_cert
|
|
||||||
if !!out == out
|
|
||||||
out = out ? 'Certificate is valid' : 'Certificate not valid'
|
|
||||||
end
|
|
||||||
Chef::Log.info(out.to_s)
|
|
||||||
end
|
|
||||||
|
|
||||||
action_class do
|
|
||||||
require 'openssl'
|
|
||||||
|
|
||||||
# load the gem and rescue a gem install if it fails to load
|
|
||||||
def load_gem
|
|
||||||
gem 'win32-certstore', '>= 0.2.4'
|
|
||||||
require 'win32-certstore' # until this is in core chef
|
|
||||||
rescue LoadError
|
|
||||||
Chef::Log.debug('Did not find win32-certstore >= 0.2.4 gem installed. Installing now')
|
|
||||||
chef_gem 'win32-certstore' do
|
|
||||||
compile_time true
|
|
||||||
action :upgrade
|
|
||||||
end
|
|
||||||
|
|
||||||
require 'win32-certstore'
|
|
||||||
end
|
|
||||||
|
|
||||||
def add_cert(cert_obj)
|
|
||||||
store = ::Win32::Certstore.open(new_resource.store_name)
|
|
||||||
store.add(cert_obj)
|
|
||||||
end
|
|
||||||
|
|
||||||
def add_pfx_cert
|
|
||||||
store = ::Win32::Certstore.open(new_resource.store_name)
|
|
||||||
store.add_pfx(new_resource.source, new_resource.pfx_password)
|
|
||||||
end
|
|
||||||
|
|
||||||
def delete_cert
|
|
||||||
store = ::Win32::Certstore.open(new_resource.store_name)
|
|
||||||
store.delete(new_resource.source)
|
|
||||||
end
|
|
||||||
|
|
||||||
def fetch_cert
|
|
||||||
store = ::Win32::Certstore.open(new_resource.store_name)
|
|
||||||
store.get(new_resource.source)
|
|
||||||
end
|
|
||||||
|
|
||||||
# Checks whether a certificate with the given thumbprint
|
|
||||||
# is already present and valid in certificate store
|
|
||||||
# If the certificate is not present, verify_cert returns a String: "Certificate not found"
|
|
||||||
# But if it is present but expired, it returns a Boolean: false
|
|
||||||
# Otherwise, it returns a Boolean: true
|
|
||||||
def verify_cert(thumbprint = new_resource.source)
|
|
||||||
store = ::Win32::Certstore.open(new_resource.store_name)
|
|
||||||
store.valid?(thumbprint)
|
|
||||||
end
|
|
||||||
|
|
||||||
def show_or_store_cert(cert_obj)
|
|
||||||
if new_resource.cert_path
|
|
||||||
export_cert(cert_obj, new_resource.cert_path)
|
|
||||||
if ::File.size(new_resource.cert_path) > 0
|
|
||||||
Chef::Log.info("Certificate export in #{new_resource.cert_path}")
|
|
||||||
else
|
|
||||||
::File.delete(new_resource.cert_path)
|
|
||||||
end
|
|
||||||
else
|
|
||||||
Chef::Log.info(cert_obj.display)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
def export_cert(cert_obj, cert_path)
|
|
||||||
out_file = ::File.new(cert_path, 'w+')
|
|
||||||
case ::File.extname(cert_path)
|
|
||||||
when '.pem'
|
|
||||||
out_file.puts(cert_obj.to_pem)
|
|
||||||
when '.der'
|
|
||||||
out_file.puts(cert_obj.to_der)
|
|
||||||
when '.cer'
|
|
||||||
cert_out = powershell_out("openssl x509 -text -inform DER -in #{cert_obj.to_pem} -outform CER").stdout
|
|
||||||
out_file.puts(cert_out)
|
|
||||||
when '.crt'
|
|
||||||
cert_out = powershell_out("openssl x509 -text -inform DER -in #{cert_obj.to_pem} -outform CRT").stdout
|
|
||||||
out_file.puts(cert_out)
|
|
||||||
when '.pfx'
|
|
||||||
cert_out = powershell_out("openssl pkcs12 -export -nokeys -in #{cert_obj.to_pem} -outform PFX").stdout
|
|
||||||
out_file.puts(cert_out)
|
|
||||||
when '.p7b'
|
|
||||||
cert_out = powershell_out("openssl pkcs7 -export -nokeys -in #{cert_obj.to_pem} -outform P7B").stdout
|
|
||||||
out_file.puts(cert_out)
|
|
||||||
else
|
|
||||||
Chef::Log.info('Supported certificate format .pem, .der, .cer, .crt, .pfx and .p7b')
|
|
||||||
end
|
|
||||||
out_file.close
|
|
||||||
end
|
|
||||||
|
|
||||||
def cert_location
|
|
||||||
@location ||= new_resource.user_store ? 'CurrentUser' : 'LocalMachine'
|
|
||||||
end
|
|
||||||
|
|
||||||
def cert_script(persist)
|
|
||||||
cert_script = '$cert = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2'
|
|
||||||
file = Chef::Util::PathHelper.cleanpath(new_resource.source)
|
|
||||||
cert_script << " \"#{file}\""
|
|
||||||
if ::File.extname(file.downcase) == '.pfx'
|
|
||||||
cert_script << ", \"#{new_resource.pfx_password}\""
|
|
||||||
if persist && new_resource.user_store
|
|
||||||
cert_script << ', ([System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::PersistKeySet)'
|
|
||||||
elsif persist
|
|
||||||
cert_script << ', ([System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::PersistKeySet -bor [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::MachineKeyset)'
|
|
||||||
end
|
|
||||||
end
|
|
||||||
cert_script << "\n"
|
|
||||||
end
|
|
||||||
|
|
||||||
def cert_exists_script(hash)
|
|
||||||
<<-EOH
|
|
||||||
$hash = #{hash}
|
|
||||||
Test-Path "Cert:\\#{cert_location}\\#{new_resource.store_name}\\$hash"
|
|
||||||
EOH
|
|
||||||
end
|
|
||||||
|
|
||||||
def within_store_script
|
|
||||||
inner_script = yield '$store'
|
|
||||||
<<-EOH
|
|
||||||
$store = New-Object System.Security.Cryptography.X509Certificates.X509Store "#{new_resource.store_name}", ([System.Security.Cryptography.X509Certificates.StoreLocation]::#{cert_location})
|
|
||||||
$store.Open([System.Security.Cryptography.X509Certificates.OpenFlags]::ReadWrite)
|
|
||||||
#{inner_script}
|
|
||||||
$store.Close()
|
|
||||||
EOH
|
|
||||||
end
|
|
||||||
|
|
||||||
def acl_script(hash)
|
|
||||||
return '' if new_resource.private_key_acl.nil? || new_resource.private_key_acl.empty?
|
|
||||||
|
|
||||||
# this PS came from http://blogs.technet.com/b/operationsguy/archive/2010/11/29/provide-access-to-private-keys-commandline-vs-powershell.aspx
|
|
||||||
# and from https://msdn.microsoft.com/en-us/library/windows/desktop/bb204778(v=vs.85).aspx
|
|
||||||
set_acl_script = <<-EOH
|
|
||||||
$hash = #{hash}
|
|
||||||
$storeCert = Get-ChildItem "cert:\\#{cert_location}\\#{new_resource.store_name}\\$hash"
|
|
||||||
if ($storeCert -eq $null) { throw 'no key exists.' }
|
|
||||||
$keyname = $storeCert.PrivateKey.CspKeyContainerInfo.UniqueKeyContainerName
|
|
||||||
if ($keyname -eq $null) { throw 'no private key exists.' }
|
|
||||||
if ($storeCert.PrivateKey.CspKeyContainerInfo.MachineKeyStore)
|
|
||||||
{
|
|
||||||
$fullpath = "$Env:ProgramData\\Microsoft\\Crypto\\RSA\\MachineKeys\\$keyname"
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$currentUser = New-Object System.Security.Principal.NTAccount($Env:UserDomain, $Env:UserName)
|
|
||||||
$userSID = $currentUser.Translate([System.Security.Principal.SecurityIdentifier]).Value
|
|
||||||
$fullpath = "$Env:ProgramData\\Microsoft\\Crypto\\RSA\\$userSID\\$keyname"
|
|
||||||
}
|
|
||||||
EOH
|
|
||||||
new_resource.private_key_acl.each do |name|
|
|
||||||
set_acl_script << "$uname='#{name}'; icacls $fullpath /grant $uname`:RX\n"
|
|
||||||
end
|
|
||||||
set_acl_script
|
|
||||||
end
|
|
||||||
|
|
||||||
# Method returns an OpenSSL::X509::Certificate object
|
|
||||||
#
|
|
||||||
# Based on its extension, the certificate contents are used to initialize
|
|
||||||
# PKCS12 (PFX), PKCS7 (P7B) objects which contains OpenSSL::X509::Certificate.
|
|
||||||
#
|
|
||||||
# @note Other then PEM, all the certificates are usually in binary format, and hence
|
|
||||||
# their contents are loaded by using File.binread
|
|
||||||
#
|
|
||||||
# @param ext [String] Extension of the certificate
|
|
||||||
#
|
|
||||||
# @return [OpenSSL::X509::Certificate] Object containing certificate's attributes
|
|
||||||
#
|
|
||||||
# @raise [OpenSSL::PKCS12::PKCS12Error] When incorrect password is provided for PFX certificate
|
|
||||||
#
|
|
||||||
def fetch_cert_object(ext)
|
|
||||||
contents = if binary_cert?
|
|
||||||
::File.binread(new_resource.source)
|
|
||||||
else
|
|
||||||
::File.read(new_resource.source)
|
|
||||||
end
|
|
||||||
|
|
||||||
case ext
|
|
||||||
when '.pfx'
|
|
||||||
OpenSSL::PKCS12.new(contents, new_resource.pfx_password).certificate
|
|
||||||
when '.p7b'
|
|
||||||
OpenSSL::PKCS7.new(contents).certificates.first
|
|
||||||
else
|
|
||||||
OpenSSL::X509::Certificate.new(contents)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# @return [Boolean] Whether the certificate file is binary encoded or not
|
|
||||||
#
|
|
||||||
def binary_cert?
|
|
||||||
powershell_out!("file -b --mime-encoding #{new_resource.source}").stdout.strip == 'binary'
|
|
||||||
end
|
|
||||||
end
|
|
|
@ -19,7 +19,6 @@
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
#
|
#
|
||||||
|
|
||||||
include Chef::Mixin::PowershellOut
|
|
||||||
include Windows::Helper
|
include Windows::Helper
|
||||||
|
|
||||||
property :cert_name, String, name_property: true
|
property :cert_name, String, name_property: true
|
||||||
|
@ -28,7 +27,7 @@ property :address, String, default: '0.0.0.0'
|
||||||
property :port, Integer, default: 443
|
property :port, Integer, default: 443
|
||||||
property :app_id, String, default: '{4dc3e181-e14b-4a21-b022-59fc669b0914}'
|
property :app_id, String, default: '{4dc3e181-e14b-4a21-b022-59fc669b0914}'
|
||||||
property :store_name, String, default: 'MY', equal_to: ['TRUSTEDPUBLISHER', 'CLIENTAUTHISSUER', 'REMOTE DESKTOP', 'ROOT', 'TRUSTEDDEVICES', 'WEBHOSTING', 'CA', 'AUTHROOT', 'TRUSTEDPEOPLE', 'MY', 'SMARTCARDROOT', 'TRUST']
|
property :store_name, String, default: 'MY', equal_to: ['TRUSTEDPUBLISHER', 'CLIENTAUTHISSUER', 'REMOTE DESKTOP', 'ROOT', 'TRUSTEDDEVICES', 'WEBHOSTING', 'CA', 'AUTHROOT', 'TRUSTEDPEOPLE', 'MY', 'SMARTCARDROOT', 'TRUST']
|
||||||
property :exists, [true, false], desired_state: true
|
property :exists, [true, false]
|
||||||
|
|
||||||
load_current_value do |desired|
|
load_current_value do |desired|
|
||||||
mode = desired.address.match(/(\d+\.){3}\d+|\[.+\]/).nil? ? 'hostnameport' : 'ipport'
|
mode = desired.address.match(/(\d+\.){3}\d+|\[.+\]/).nil? ? 'hostnameport' : 'ipport'
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#
|
#
|
||||||
# Author:: Richard Lavey (richard.lavey@calastone.com)
|
# Author:: Richard Lavey (richard.lavey@calastone.com)
|
||||||
# Cookbook Name:: windows
|
# Cookbook:: windows
|
||||||
# Resource:: dns
|
# Resource:: dns
|
||||||
#
|
#
|
||||||
# Copyright:: 2015, Calastone Ltd.
|
# Copyright:: 2015, Calastone Ltd.
|
||||||
|
@ -18,10 +18,9 @@
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
#
|
#
|
||||||
|
|
||||||
actions :create, :delete
|
|
||||||
default_action :create
|
default_action :create
|
||||||
|
|
||||||
attribute :host_name, kind_of: String, name_property: true, required: true
|
attribute :host_name, kind_of: String, required: true
|
||||||
attribute :record_type, kind_of: String, default: 'A', regex: /^(?:A|CNAME)$/
|
attribute :record_type, kind_of: String, default: 'A', regex: /^(?:A|CNAME)$/
|
||||||
attribute :dns_server, kind_of: String, default: '.'
|
attribute :dns_server, kind_of: String, default: '.'
|
||||||
attribute :target, kind_of: [Array, String], required: true
|
attribute :target, kind_of: [Array, String], required: true
|
||||||
|
|
|
@ -23,7 +23,7 @@ include Windows::Helper
|
||||||
property :url, String, name_property: true
|
property :url, String, name_property: true
|
||||||
property :user, String
|
property :user, String
|
||||||
property :sddl, String
|
property :sddl, String
|
||||||
property :exists, [true, false], desired_state: true
|
property :exists, [true, false]
|
||||||
|
|
||||||
# See https://msdn.microsoft.com/en-us/library/windows/desktop/cc307236%28v=vs.85%29.aspx for netsh info
|
# See https://msdn.microsoft.com/en-us/library/windows/desktop/cc307236%28v=vs.85%29.aspx for netsh info
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,39 @@
|
||||||
|
#
|
||||||
|
# Author:: Jason Field (jason.field@calastone.com)
|
||||||
|
# Cookbook:: windows
|
||||||
|
# Resource:: schannel
|
||||||
|
#
|
||||||
|
# Copyright:: 2019, Calastone Ltd.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
#
|
||||||
|
|
||||||
|
property :use_strong_crypto, [true, false], default: true
|
||||||
|
|
||||||
|
action :configure do
|
||||||
|
registry_key 'HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\.NETFramework\\v4.0.30319' do
|
||||||
|
values [{
|
||||||
|
name: 'SchUseStrongCrypto',
|
||||||
|
type: :dword,
|
||||||
|
data: new_resource.use_strong_crypto ? 1 : 0,
|
||||||
|
}]
|
||||||
|
end
|
||||||
|
|
||||||
|
registry_key 'HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\.NETFramework\\v4.0.30319' do
|
||||||
|
values [{
|
||||||
|
name: 'SchUseStrongCrypto',
|
||||||
|
type: :dword,
|
||||||
|
data: new_resource.use_strong_crypto ? 1 : 0,
|
||||||
|
}]
|
||||||
|
end
|
||||||
|
end
|
|
@ -1,288 +0,0 @@
|
||||||
#
|
|
||||||
# Author:: Sölvi Páll Ásgeirsson (<solvip@gmail.com>)
|
|
||||||
# Author:: Richard Lavey (richard.lavey@calastone.com)
|
|
||||||
# Author:: Tim Smith (tsmith@chef.io)
|
|
||||||
# Cookbook:: windows
|
|
||||||
# Resource:: share
|
|
||||||
#
|
|
||||||
# Copyright:: 2014-2017, Sölvi Páll Ásgeirsson.
|
|
||||||
# Copyright:: 2018, Chef Software, Inc.
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
# you may not use this file except in compliance with the License.
|
|
||||||
# You may obtain a copy of the License at
|
|
||||||
#
|
|
||||||
# http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
#
|
|
||||||
# Unless required by applicable law or agreed to in writing, software
|
|
||||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
# See the License for the specific language governing permissions and
|
|
||||||
# limitations under the License.
|
|
||||||
#
|
|
||||||
|
|
||||||
chef_version_for_provides '< 14.7' if respond_to?(:chef_version_for_provides)
|
|
||||||
resource_name :windows_share
|
|
||||||
|
|
||||||
require 'chef/json_compat'
|
|
||||||
require 'chef/util/path_helper'
|
|
||||||
|
|
||||||
# Specifies a name for the SMB share. The name may be composed of any valid file name characters, but must be less than 80 characters long. The names pipe and mailslot are reserved for use by the computer.
|
|
||||||
property :share_name, String, name_property: true
|
|
||||||
|
|
||||||
# Specifies the path of the location of the folder to share. The path must be fully qualified. Relative paths or paths that contain wildcard characters are not permitted.
|
|
||||||
property :path, String
|
|
||||||
|
|
||||||
# Specifies an optional description of the SMB share. A description of the share is displayed by running the Get-SmbShare cmdlet. The description may not contain more than 256 characters.
|
|
||||||
property :description, String, default: ''
|
|
||||||
|
|
||||||
# Specifies which accounts are granted full permission to access the share. Use a comma-separated list to specify multiple accounts. An account may not be specified more than once in the FullAccess, ChangeAccess, or ReadAccess parameter lists, but may be specified once in the FullAccess, ChangeAccess, or ReadAccess parameter list and once in the NoAccess parameter list.
|
|
||||||
property :full_users, Array, default: [], coerce: proc { |u| u.sort }
|
|
||||||
|
|
||||||
# Specifies which users are granted modify permission to access the share
|
|
||||||
property :change_users, Array, default: [], coerce: proc { |u| u.sort }
|
|
||||||
|
|
||||||
# Specifies which users are granted read permission to access the share. Multiple users can be specified by supplying a comma-separated list.
|
|
||||||
property :read_users, Array, default: [], coerce: proc { |u| u.sort }
|
|
||||||
|
|
||||||
# Specifies the lifetime of the new SMB share. A temporary share does not persist beyond the next restart of the computer. By default, new SMB shares are persistent, and non-temporary.
|
|
||||||
property :temporary, [true, false], default: false
|
|
||||||
|
|
||||||
# Specifies the scope name of the share.
|
|
||||||
property :scope_name, String, default: '*'
|
|
||||||
|
|
||||||
# Specifies the continuous availability time-out for the share.
|
|
||||||
property :ca_timeout, Integer, default: 0
|
|
||||||
|
|
||||||
# Indicates that the share is continuously available.
|
|
||||||
property :continuously_available, [true, false], default: false
|
|
||||||
|
|
||||||
# Specifies the caching mode of the offline files for the SMB share.
|
|
||||||
# property :caching_mode, String, equal_to: %w(None Manual Documents Programs BranchCache)
|
|
||||||
|
|
||||||
# Specifies the maximum number of concurrently connected users that the new SMB share may accommodate. If this parameter is set to zero (0), then the number of users is unlimited.
|
|
||||||
property :concurrent_user_limit, Integer, default: 0
|
|
||||||
|
|
||||||
# Indicates that the share is encrypted.
|
|
||||||
property :encrypt_data, [true, false], default: false
|
|
||||||
|
|
||||||
# Specifies which files and folders in the SMB share are visible to users. AccessBased: SMB does not the display the files and folders for a share to a user unless that user has rights to access the files and folders. By default, access-based enumeration is disabled for new SMB shares. Unrestricted: SMB displays files and folders to a user even when the user does not have permission to access the items.
|
|
||||||
# property :folder_enumeration_mode, String, equal_to: %(AccessBased Unrestricted)
|
|
||||||
|
|
||||||
include Chef::Mixin::PowershellOut
|
|
||||||
|
|
||||||
load_current_value do |desired|
|
|
||||||
# this command selects individual objects because EncryptData & CachingMode have underlying
|
|
||||||
# types that get converted to their Integer values by ConvertTo-Json & we need to make sure
|
|
||||||
# those get written out as strings
|
|
||||||
share_state_cmd = "Get-SmbShare -Name '#{desired.share_name}' | Select-Object Name,Path, Description, Temporary, CATimeout, ContinuouslyAvailable, ConcurrentUserLimit, EncryptData | ConvertTo-Json"
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{share_state_cmd}' to determine share state'")
|
|
||||||
ps_results = powershell_out(share_state_cmd)
|
|
||||||
|
|
||||||
# detect a failure without raising and then set current_resource to nil
|
|
||||||
if ps_results.error?
|
|
||||||
Chef::Log.debug("Error fetching share state: #{ps_results.stderr}")
|
|
||||||
current_value_does_not_exist!
|
|
||||||
end
|
|
||||||
|
|
||||||
Chef::Log.debug("The Get-SmbShare results were #{ps_results.stdout}")
|
|
||||||
results = Chef::JSONCompat.from_json(ps_results.stdout)
|
|
||||||
|
|
||||||
path results['Path']
|
|
||||||
description results['Description']
|
|
||||||
temporary results['Temporary']
|
|
||||||
ca_timeout results['CATimeout']
|
|
||||||
continuously_available results['ContinuouslyAvailable']
|
|
||||||
# caching_mode results['CachingMode']
|
|
||||||
concurrent_user_limit results['ConcurrentUserLimit']
|
|
||||||
encrypt_data results['EncryptData']
|
|
||||||
# folder_enumeration_mode results['FolderEnumerationMode']
|
|
||||||
|
|
||||||
perm_state_cmd = %(Get-SmbShareAccess -Name "#{desired.share_name}" | Select-Object AccountName,AccessControlType,AccessRight | ConvertTo-Json)
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{perm_state_cmd}' to determine share permissions state'")
|
|
||||||
ps_perm_results = powershell_out(perm_state_cmd)
|
|
||||||
|
|
||||||
# we raise here instead of warning like above because we'd only get here if the above Get-SmbShare
|
|
||||||
# command was successful and that continuing would leave us with 1/2 known state
|
|
||||||
raise "Could not determine #{desired.share_name} share permissions by running '#{perm_state_cmd}'" if ps_perm_results.error?
|
|
||||||
|
|
||||||
Chef::Log.debug("The Get-SmbShareAccess results were #{ps_perm_results.stdout}")
|
|
||||||
|
|
||||||
f_users, c_users, r_users = parse_permissions(ps_perm_results.stdout)
|
|
||||||
|
|
||||||
full_users f_users
|
|
||||||
change_users c_users
|
|
||||||
read_users r_users
|
|
||||||
end
|
|
||||||
|
|
||||||
def after_created
|
|
||||||
raise 'The windows_share resource relies on PowerShell cmdlets not present in Windows releases prior to 8/2012. Cannot continue!' if node['platform_version'].to_f < 6.3
|
|
||||||
end
|
|
||||||
|
|
||||||
# given the string output of Get-SmbShareAccess parse out
|
|
||||||
# arrays of full access users, change users, and read only users
|
|
||||||
def parse_permissions(results_string)
|
|
||||||
json_results = Chef::JSONCompat.from_json(results_string)
|
|
||||||
json_results = [json_results] unless json_results.is_a?(Array) # single result is not an array
|
|
||||||
|
|
||||||
f_users = []
|
|
||||||
c_users = []
|
|
||||||
r_users = []
|
|
||||||
|
|
||||||
json_results.each do |perm|
|
|
||||||
next unless perm['AccessControlType'] == 0 # allow
|
|
||||||
case perm['AccessRight']
|
|
||||||
when 0 then f_users << stripped_account(perm['AccountName']) # 0 full control
|
|
||||||
when 1 then c_users << stripped_account(perm['AccountName']) # 1 == change
|
|
||||||
when 2 then r_users << stripped_account(perm['AccountName']) # 2 == read
|
|
||||||
end
|
|
||||||
end
|
|
||||||
[f_users, c_users, r_users]
|
|
||||||
end
|
|
||||||
|
|
||||||
# local names are returned from Get-SmbShareAccess in the full format MACHINE\\NAME
|
|
||||||
# but users of this resource would simply say NAME so we need to strip the values for comparison
|
|
||||||
def stripped_account(name)
|
|
||||||
name.slice!("#{node['hostname']}\\")
|
|
||||||
name
|
|
||||||
end
|
|
||||||
|
|
||||||
action :create do
|
|
||||||
# we do this here instead of requiring the property because :delete doesn't need path set
|
|
||||||
raise 'No path property set' unless new_resource.path
|
|
||||||
|
|
||||||
converge_if_changed do
|
|
||||||
# you can't actually change the path so you have to delete the old share first
|
|
||||||
if different_path?
|
|
||||||
Chef::Log.debug('The path has changed so we will delete and recreate share')
|
|
||||||
delete_share
|
|
||||||
create_share
|
|
||||||
elsif current_resource.nil?
|
|
||||||
# powershell cmdlet for create is different than updates
|
|
||||||
Chef::Log.debug('The current resource is nil so we will create a new share')
|
|
||||||
create_share
|
|
||||||
else
|
|
||||||
Chef::Log.debug('The current resource was not nil so we will update an existing share')
|
|
||||||
update_share
|
|
||||||
end
|
|
||||||
|
|
||||||
# creating the share does not set permissions so we need to update
|
|
||||||
update_permissions
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
action :delete do
|
|
||||||
if current_resource.nil?
|
|
||||||
Chef::Log.debug("#{new_resource.share_name} does not exist - nothing to do")
|
|
||||||
else
|
|
||||||
converge_by("delete #{new_resource.share_name}") do
|
|
||||||
delete_share
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
action_class do
|
|
||||||
def different_path?
|
|
||||||
return false if current_resource.nil? # going from nil to something isn't different for our concerns
|
|
||||||
return false if current_resource.path == Chef::Util::PathHelper.cleanpath(new_resource.path)
|
|
||||||
true
|
|
||||||
end
|
|
||||||
|
|
||||||
def delete_share
|
|
||||||
delete_command = "Remove-SmbShare -Name '#{new_resource.share_name}' -Force"
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{delete_command}' to remove the share")
|
|
||||||
powershell_out!(delete_command)
|
|
||||||
end
|
|
||||||
|
|
||||||
def update_share
|
|
||||||
update_command = "Set-SmbShare -Name '#{new_resource.share_name}' -Description '#{new_resource.description}' -Force"
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{update_command}' to update the share")
|
|
||||||
powershell_out!(update_command)
|
|
||||||
end
|
|
||||||
|
|
||||||
def create_share
|
|
||||||
raise "#{new_resource.path} is missing or not a directory. Shares cannot be created if the path doesn't first exist." unless ::File.directory? new_resource.path
|
|
||||||
|
|
||||||
share_cmd = "New-SmbShare -Name '#{new_resource.share_name}' -Path '#{Chef::Util::PathHelper.cleanpath(new_resource.path)}' -Description '#{new_resource.description}' -ConcurrentUserLimit #{new_resource.concurrent_user_limit} -CATimeout #{new_resource.ca_timeout} -EncryptData:#{bool_string(new_resource.encrypt_data)} -ContinuouslyAvailable:#{bool_string(new_resource.continuously_available)}"
|
|
||||||
share_cmd << " -ScopeName #{new_resource.scope_name}" unless new_resource.scope_name == '*' # passing * causes the command to fail
|
|
||||||
share_cmd << " -Temporary:#{bool_string(new_resource.temporary)}" if new_resource.temporary # only set true
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{share_cmd}' to create the share")
|
|
||||||
powershell_out!(share_cmd)
|
|
||||||
|
|
||||||
# New-SmbShare adds the "Everyone" user with read access no matter what so we need to remove it
|
|
||||||
# before we add our permissions
|
|
||||||
revoke_user_permissions(['Everyone'])
|
|
||||||
end
|
|
||||||
|
|
||||||
# determine what users in the current state don't exist in the desired state
|
|
||||||
# users/groups will have their permissions updated with the same command that
|
|
||||||
# sets it, but removes must be performed with Revoke-SmbShareAccess
|
|
||||||
def users_to_revoke
|
|
||||||
@users_to_revoke ||= begin
|
|
||||||
# if the resource doesn't exist then nothing needs to be revoked
|
|
||||||
if current_resource.nil?
|
|
||||||
[]
|
|
||||||
else # if it exists then calculate the current to new resource diffs
|
|
||||||
(current_resource.full_users + current_resource.change_users + current_resource.read_users) - (new_resource.full_users + new_resource.change_users + new_resource.read_users)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# update existing permissions on a share
|
|
||||||
def update_permissions
|
|
||||||
# revoke any users that had something, but now has nothing
|
|
||||||
revoke_user_permissions(users_to_revoke) unless users_to_revoke.empty?
|
|
||||||
|
|
||||||
# set permissions for each of the permission types
|
|
||||||
%w(full read change).each do |perm_type|
|
|
||||||
# set permissions for a brand new share OR
|
|
||||||
# update permissions if the current state and desired state differ
|
|
||||||
next unless permissions_need_update?(perm_type)
|
|
||||||
grant_command = "Grant-SmbShareAccess -Name '#{new_resource.share_name}' -AccountName \"#{new_resource.send("#{perm_type}_users").join('","')}\" -Force -AccessRight #{perm_type}"
|
|
||||||
|
|
||||||
Chef::Log.debug("Running '#{grant_command}' to update the share permissions")
|
|
||||||
powershell_out!(grant_command)
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
# determine if permissions need to be updated.
|
|
||||||
# Brand new share with no permissions defined: no
|
|
||||||
# Brand new share with permissions defined: yes
|
|
||||||
# Existing share with differing permissions: yes
|
|
||||||
#
|
|
||||||
# @param [String] type the permissions type (Full, Read, or Change)
|
|
||||||
def permissions_need_update?(type)
|
|
||||||
property_name = "#{type}_users"
|
|
||||||
|
|
||||||
# brand new share, but nothing to set
|
|
||||||
return false if current_resource.nil? && new_resource.send(property_name).empty?
|
|
||||||
|
|
||||||
# brand new share with new permissions to set
|
|
||||||
return true if current_resource.nil? && !new_resource.send(property_name).empty?
|
|
||||||
|
|
||||||
# there's a difference between the current and desired state
|
|
||||||
return true unless (new_resource.send(property_name) - current_resource.send(property_name)).empty?
|
|
||||||
|
|
||||||
# anything else
|
|
||||||
false
|
|
||||||
end
|
|
||||||
|
|
||||||
# revoke user permissions from a share
|
|
||||||
# @param [Array] users
|
|
||||||
def revoke_user_permissions(users)
|
|
||||||
revoke_command = "Revoke-SmbShareAccess -Name '#{new_resource.share_name}' -AccountName \"#{users.join('","')}\" -Force"
|
|
||||||
Chef::Log.debug("Running '#{revoke_command}' to revoke share permissions")
|
|
||||||
powershell_out!(revoke_command)
|
|
||||||
end
|
|
||||||
|
|
||||||
# convert True/False into "$True" & "$False"
|
|
||||||
def bool_string(bool)
|
|
||||||
# bool ? 1 : 0
|
|
||||||
bool ? '$true' : '$false'
|
|
||||||
end
|
|
||||||
end
|
|
|
@ -4,11 +4,13 @@
|
||||||
# Resource:: user_privilege
|
# Resource:: user_privilege
|
||||||
#
|
#
|
||||||
|
|
||||||
|
chef_version_for_provides '< 16.0' if respond_to?(:chef_version_for_provides)
|
||||||
|
|
||||||
property :principal, String, name_property: true
|
property :principal, String, name_property: true
|
||||||
property :privilege, [Array, String], required: true, coerce: proc { |v| [*v].sort }
|
property :privilege, [Array, String], required: true, coerce: proc { |v| Array(v).sort }
|
||||||
|
|
||||||
action :add do
|
action :add do
|
||||||
([*new_resource.privilege] - [*current_resource.privilege]).each do |user_right|
|
new_resource.privilege - Array(current_resource.privilege).each do |user_right|
|
||||||
converge_by("adding user privilege #{user_right}") do
|
converge_by("adding user privilege #{user_right}") do
|
||||||
Chef::ReservedNames::Win32::Security.add_account_right(new_resource.principal, user_right)
|
Chef::ReservedNames::Win32::Security.add_account_right(new_resource.principal, user_right)
|
||||||
end
|
end
|
||||||
|
|
|
@ -116,6 +116,7 @@ action_class do
|
||||||
|
|
||||||
def ensure_rubyzip_gem_installed
|
def ensure_rubyzip_gem_installed
|
||||||
require 'zip'
|
require 'zip'
|
||||||
|
Chef::Log.warn('The windows_zipfile resource has been deprecated as Chef Infra Client 15.0 shipped with a new archive_file resource, which natively handles multiple archive formats. Please update any cookbooks using this resource to instead use the `archive_file` resource: https://docs.chef.io/resource_archive_file.html')
|
||||||
rescue LoadError
|
rescue LoadError
|
||||||
Chef::Log.info("Missing gem 'rubyzip'...installing now.")
|
Chef::Log.info("Missing gem 'rubyzip'...installing now.")
|
||||||
chef_gem 'rubyzip' do
|
chef_gem 'rubyzip' do
|
||||||
|
|
|
@ -2,6 +2,61 @@
|
||||||
|
|
||||||
This file is used to list changes made in each version of the yum-epel cookbook.
|
This file is used to list changes made in each version of the yum-epel cookbook.
|
||||||
|
|
||||||
|
## 4.2.3 - *2021-11-03*
|
||||||
|
|
||||||
|
- Rename helper method to `epel_8_repos` to not conflict with yum-centos
|
||||||
|
|
||||||
|
## 4.2.2 - *2021-11-02*
|
||||||
|
|
||||||
|
- Update documentation for epel on CentOS Stream
|
||||||
|
|
||||||
|
## 4.2.1 - *2021-11-02*
|
||||||
|
|
||||||
|
- Add epel and epel-debuginfo repos by default for CentOS Streams
|
||||||
|
|
||||||
|
## 4.2.0 - *2021-11-02*
|
||||||
|
|
||||||
|
- Add support for CentOS Stream 8
|
||||||
|
|
||||||
|
## 4.1.4 - *2021-08-30*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 4.1.3 - *2021-07-14*
|
||||||
|
|
||||||
|
- Remove deprecated `failoverprorioty` setting
|
||||||
|
|
||||||
|
## 4.1.2 - *2021-06-01*
|
||||||
|
|
||||||
|
- Standardise files with files in sous-chefs/repo-management
|
||||||
|
|
||||||
|
## 4.1.1 - *2021-01-24*
|
||||||
|
|
||||||
|
- Fix support for Oracle Linux
|
||||||
|
|
||||||
|
## 4.1.0 - *2021-01-14*
|
||||||
|
|
||||||
|
- Sous Chefs Adoption
|
||||||
|
|
||||||
|
## 4.0.1 (2021-01-04)
|
||||||
|
|
||||||
|
- Return empty array on non-yum systems - [@ramereth](https://github.com/ramereth)
|
||||||
|
|
||||||
|
## 4.0.0 (2020-12-15)
|
||||||
|
|
||||||
|
- Cookstyle fixes - [@tas50](https://github.com/tas50)
|
||||||
|
- Switch all http URLs to HTTPS URLs - [@damacus](https://github.com/damacus)
|
||||||
|
- Switch gpgkey urls - [@knightorc](https://github.com/knightorc)
|
||||||
|
- Require Chef 12.15+ - [@tas50](https://github.com/tas50)
|
||||||
|
- Remove CentOS 6 / Amazon Linux 201X support/testing - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Improve InSpec test by using yum.repo resource - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Fix repo descriptions on Amazon Linux - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Test all supported repos in new "all" suite - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Ensure other epel repos are not enabled in default suite - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Add various modular and playground repos for EL8 - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Update README - [@ramereth](https://github.com/ramereth)
|
||||||
|
- Cleanup metadata.rb formatting - [@ramereth](https://github.com/ramereth)
|
||||||
|
|
||||||
## 3.3.0 (2018-10-09)
|
## 3.3.0 (2018-10-09)
|
||||||
|
|
||||||
- Fix cookbook to work on all releases of Amazon Linux 2
|
- Fix cookbook to work on all releases of Amazon Linux 2
|
||||||
|
|
|
@ -1,2 +0,0 @@
|
||||||
Please refer to
|
|
||||||
https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD
|
|
|
@ -0,0 +1,202 @@
|
||||||
|
Apache License
|
||||||
|
Version 2.0, January 2004
|
||||||
|
http://www.apache.org/licenses/
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||||
|
|
||||||
|
1. Definitions.
|
||||||
|
|
||||||
|
"License" shall mean the terms and conditions for use, reproduction,
|
||||||
|
and distribution as defined by Sections 1 through 9 of this document.
|
||||||
|
|
||||||
|
"Licensor" shall mean the copyright owner or entity authorized by
|
||||||
|
the copyright owner that is granting the License.
|
||||||
|
|
||||||
|
"Legal Entity" shall mean the union of the acting entity and all
|
||||||
|
other entities that control, are controlled by, or are under common
|
||||||
|
control with that entity. For the purposes of this definition,
|
||||||
|
"control" means (i) the power, direct or indirect, to cause the
|
||||||
|
direction or management of such entity, whether by contract or
|
||||||
|
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||||
|
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||||
|
|
||||||
|
"You" (or "Your") shall mean an individual or Legal Entity
|
||||||
|
exercising permissions granted by this License.
|
||||||
|
|
||||||
|
"Source" form shall mean the preferred form for making modifications,
|
||||||
|
including but not limited to software source code, documentation
|
||||||
|
source, and configuration files.
|
||||||
|
|
||||||
|
"Object" form shall mean any form resulting from mechanical
|
||||||
|
transformation or translation of a Source form, including but
|
||||||
|
not limited to compiled object code, generated documentation,
|
||||||
|
and conversions to other media types.
|
||||||
|
|
||||||
|
"Work" shall mean the work of authorship, whether in Source or
|
||||||
|
Object form, made available under the License, as indicated by a
|
||||||
|
copyright notice that is included in or attached to the work
|
||||||
|
(an example is provided in the Appendix below).
|
||||||
|
|
||||||
|
"Derivative Works" shall mean any work, whether in Source or Object
|
||||||
|
form, that is based on (or derived from) the Work and for which the
|
||||||
|
editorial revisions, annotations, elaborations, or other modifications
|
||||||
|
represent, as a whole, an original work of authorship. For the purposes
|
||||||
|
of this License, Derivative Works shall not include works that remain
|
||||||
|
separable from, or merely link (or bind by name) to the interfaces of,
|
||||||
|
the Work and Derivative Works thereof.
|
||||||
|
|
||||||
|
"Contribution" shall mean any work of authorship, including
|
||||||
|
the original version of the Work and any modifications or additions
|
||||||
|
to that Work or Derivative Works thereof, that is intentionally
|
||||||
|
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||||
|
or by an individual or Legal Entity authorized to submit on behalf of
|
||||||
|
the copyright owner. For the purposes of this definition, "submitted"
|
||||||
|
means any form of electronic, verbal, or written communication sent
|
||||||
|
to the Licensor or its representatives, including but not limited to
|
||||||
|
communication on electronic mailing lists, source code control systems,
|
||||||
|
and issue tracking systems that are managed by, or on behalf of, the
|
||||||
|
Licensor for the purpose of discussing and improving the Work, but
|
||||||
|
excluding communication that is conspicuously marked or otherwise
|
||||||
|
designated in writing by the copyright owner as "Not a Contribution."
|
||||||
|
|
||||||
|
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||||
|
on behalf of whom a Contribution has been received by Licensor and
|
||||||
|
subsequently incorporated within the Work.
|
||||||
|
|
||||||
|
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
copyright license to reproduce, prepare Derivative Works of,
|
||||||
|
publicly display, publicly perform, sublicense, and distribute the
|
||||||
|
Work and such Derivative Works in Source or Object form.
|
||||||
|
|
||||||
|
3. Grant of Patent License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
(except as stated in this section) patent license to make, have made,
|
||||||
|
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||||
|
where such license applies only to those patent claims licensable
|
||||||
|
by such Contributor that are necessarily infringed by their
|
||||||
|
Contribution(s) alone or by combination of their Contribution(s)
|
||||||
|
with the Work to which such Contribution(s) was submitted. If You
|
||||||
|
institute patent litigation against any entity (including a
|
||||||
|
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||||
|
or a Contribution incorporated within the Work constitutes direct
|
||||||
|
or contributory patent infringement, then any patent licenses
|
||||||
|
granted to You under this License for that Work shall terminate
|
||||||
|
as of the date such litigation is filed.
|
||||||
|
|
||||||
|
4. Redistribution. You may reproduce and distribute copies of the
|
||||||
|
Work or Derivative Works thereof in any medium, with or without
|
||||||
|
modifications, and in Source or Object form, provided that You
|
||||||
|
meet the following conditions:
|
||||||
|
|
||||||
|
(a) You must give any other recipients of the Work or
|
||||||
|
Derivative Works a copy of this License; and
|
||||||
|
|
||||||
|
(b) You must cause any modified files to carry prominent notices
|
||||||
|
stating that You changed the files; and
|
||||||
|
|
||||||
|
(c) You must retain, in the Source form of any Derivative Works
|
||||||
|
that You distribute, all copyright, patent, trademark, and
|
||||||
|
attribution notices from the Source form of the Work,
|
||||||
|
excluding those notices that do not pertain to any part of
|
||||||
|
the Derivative Works; and
|
||||||
|
|
||||||
|
(d) If the Work includes a "NOTICE" text file as part of its
|
||||||
|
distribution, then any Derivative Works that You distribute must
|
||||||
|
include a readable copy of the attribution notices contained
|
||||||
|
within such NOTICE file, excluding those notices that do not
|
||||||
|
pertain to any part of the Derivative Works, in at least one
|
||||||
|
of the following places: within a NOTICE text file distributed
|
||||||
|
as part of the Derivative Works; within the Source form or
|
||||||
|
documentation, if provided along with the Derivative Works; or,
|
||||||
|
within a display generated by the Derivative Works, if and
|
||||||
|
wherever such third-party notices normally appear. The contents
|
||||||
|
of the NOTICE file are for informational purposes only and
|
||||||
|
do not modify the License. You may add Your own attribution
|
||||||
|
notices within Derivative Works that You distribute, alongside
|
||||||
|
or as an addendum to the NOTICE text from the Work, provided
|
||||||
|
that such additional attribution notices cannot be construed
|
||||||
|
as modifying the License.
|
||||||
|
|
||||||
|
You may add Your own copyright statement to Your modifications and
|
||||||
|
may provide additional or different license terms and conditions
|
||||||
|
for use, reproduction, or distribution of Your modifications, or
|
||||||
|
for any such Derivative Works as a whole, provided Your use,
|
||||||
|
reproduction, and distribution of the Work otherwise complies with
|
||||||
|
the conditions stated in this License.
|
||||||
|
|
||||||
|
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||||
|
any Contribution intentionally submitted for inclusion in the Work
|
||||||
|
by You to the Licensor shall be under the terms and conditions of
|
||||||
|
this License, without any additional terms or conditions.
|
||||||
|
Notwithstanding the above, nothing herein shall supersede or modify
|
||||||
|
the terms of any separate license agreement you may have executed
|
||||||
|
with Licensor regarding such Contributions.
|
||||||
|
|
||||||
|
6. Trademarks. This License does not grant permission to use the trade
|
||||||
|
names, trademarks, service marks, or product names of the Licensor,
|
||||||
|
except as required for reasonable and customary use in describing the
|
||||||
|
origin of the Work and reproducing the content of the NOTICE file.
|
||||||
|
|
||||||
|
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||||
|
agreed to in writing, Licensor provides the Work (and each
|
||||||
|
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||||
|
implied, including, without limitation, any warranties or conditions
|
||||||
|
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||||
|
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||||
|
appropriateness of using or redistributing the Work and assume any
|
||||||
|
risks associated with Your exercise of permissions under this License.
|
||||||
|
|
||||||
|
8. Limitation of Liability. In no event and under no legal theory,
|
||||||
|
whether in tort (including negligence), contract, or otherwise,
|
||||||
|
unless required by applicable law (such as deliberate and grossly
|
||||||
|
negligent acts) or agreed to in writing, shall any Contributor be
|
||||||
|
liable to You for damages, including any direct, indirect, special,
|
||||||
|
incidental, or consequential damages of any character arising as a
|
||||||
|
result of this License or out of the use or inability to use the
|
||||||
|
Work (including but not limited to damages for loss of goodwill,
|
||||||
|
work stoppage, computer failure or malfunction, or any and all
|
||||||
|
other commercial damages or losses), even if such Contributor
|
||||||
|
has been advised of the possibility of such damages.
|
||||||
|
|
||||||
|
9. Accepting Warranty or Additional Liability. While redistributing
|
||||||
|
the Work or Derivative Works thereof, You may choose to offer,
|
||||||
|
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||||
|
or other liability obligations and/or rights consistent with this
|
||||||
|
License. However, in accepting such obligations, You may act only
|
||||||
|
on Your own behalf and on Your sole responsibility, not on behalf
|
||||||
|
of any other Contributor, and only if You agree to indemnify,
|
||||||
|
defend, and hold each Contributor harmless for any liability
|
||||||
|
incurred by, or claims asserted against, such Contributor by reason
|
||||||
|
of your accepting any such warranty or additional liability.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
APPENDIX: How to apply the Apache License to your work.
|
||||||
|
|
||||||
|
To apply the Apache License to your work, attach the following
|
||||||
|
boilerplate notice, with the fields enclosed by brackets "{}"
|
||||||
|
replaced with your own identifying information. (Don't include
|
||||||
|
the brackets!) The text should be enclosed in the appropriate
|
||||||
|
comment syntax for the file format. We also recommend that a
|
||||||
|
file or class name and description of purpose be included on the
|
||||||
|
same "printed page" as the copyright notice for easier
|
||||||
|
identification within third-party archives.
|
||||||
|
|
||||||
|
Copyright {yyyy} {name of copyright owner}
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
|
|
@ -1,10 +1,40 @@
|
||||||
# yum-epel Cookbook
|
# yum-epel Cookbook
|
||||||
|
|
||||||
[![Build Status](https://travis-ci.org/chef-cookbooks/yum-epel.svg?branch=master)](http://travis-ci.org/chef-cookbooks/yum-epel) [![Cookbook Version](https://img.shields.io/cookbook/v/yum-epel.svg)](https://supermarket.chef.io/cookbooks/yum-epel)
|
[![Cookbook Version](https://img.shields.io/cookbook/v/yum-epel.svg)](https://supermarket.chef.io/cookbooks/yum-epel)
|
||||||
|
[![CI State](https://github.com/sous-chefs/yum-epel/workflows/ci/badge.svg)](https://github.com/sous-chefs/yum-epel/actions?query=workflow%3Aci)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/backers/badge.svg)](#backers)
|
||||||
|
[![OpenCollective](https://opencollective.com/sous-chefs/sponsors/badge.svg)](#sponsors)
|
||||||
|
[![License](https://img.shields.io/badge/License-Apache%202.0-green.svg)](https://opensource.org/licenses/Apache-2.0)
|
||||||
|
|
||||||
Extra Packages for Enterprise Linux (or EPEL) is a Fedora Special Interest Group that creates, maintains, and manages a high quality set of additional packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL), CentOS and Scientific Linux (SL), Oracle Linux (OL).
|
Extra Packages for Enterprise Linux (or EPEL) is a Fedora Special Interest Group that creates, maintains, and manages a high quality set of additional packages for Enterprise Linux, including, but not limited to, Red Hat Enterprise Linux (RHEL), CentOS , CentOS Stream and Scientific Linux (SL), Oracle Linux (OL).
|
||||||
|
|
||||||
The yum-epel cookbook takes over management of the default repositoryids shipped with epel-release. It allows attribute manipulation of `epel`, `epel-debuginfo`, `epel-source`, `epel-testing`, `epel-testing-debuginfo`, and `epel-testing-source`.
|
The yum-epel cookbook takes over management of the default repositoryids shipped with epel-release.
|
||||||
|
|
||||||
|
Below is a table showing which repositoryids we manage that are shipped by default via the epel-release package:
|
||||||
|
|
||||||
|
| Repo ID | EL 7 | EL 8 | CentOS Stream 8 |
|
||||||
|
| ------------------------------ | :--------------: | :--------------: | :--------------: |
|
||||||
|
| epel |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-debuginfo |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-modular | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-modular-debuginfo | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-modular-source | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-next | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-next-debuginfo | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-next-source | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-next-testing | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-next-testing-debug | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-next-testing-source | :x: | :x: |:heavy_check_mark:|
|
||||||
|
| epel-playground | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-playground-debuginfo | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-playground-source | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-source |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing-debuginfo |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing-modular | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing-modular-debuginfo | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing-modular-source | :x: |:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
| epel-testing-source |:heavy_check_mark:|:heavy_check_mark:|:heavy_check_mark:|
|
||||||
|
|
||||||
## Requirements
|
## Requirements
|
||||||
|
|
||||||
|
@ -14,7 +44,11 @@ The yum-epel cookbook takes over management of the default repositoryids shipped
|
||||||
|
|
||||||
### Chef
|
### Chef
|
||||||
|
|
||||||
- Chef 12.14+
|
- Chef 12.15+
|
||||||
|
|
||||||
|
## Maintainers
|
||||||
|
|
||||||
|
This cookbook is maintained by the Sous Chefs. The Sous Chefs are a community of Chef cookbook maintainers working together to maintain important cookbooks. If you’d like to know more please visit [sous-chefs.org](https://sous-chefs.org/) or come chat with us on the Chef Community Slack in [#sous-chefs](https://chefcommunity.slack.com/messages/C2V7B88SF).
|
||||||
|
|
||||||
### Cookbooks
|
### Cookbooks
|
||||||
|
|
||||||
|
@ -22,100 +56,11 @@ The yum-epel cookbook takes over management of the default repositoryids shipped
|
||||||
|
|
||||||
## Attributes
|
## Attributes
|
||||||
|
|
||||||
The following attributes are set by default
|
See individual repository attribute files for defaults.
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum-epel']['repos'] = %w(
|
|
||||||
epel
|
|
||||||
epel-debuginfo
|
|
||||||
epel-source
|
|
||||||
epel-testing
|
|
||||||
epel-testing-debuginfo
|
|
||||||
epel-testing-source
|
|
||||||
)
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel']['repositoryid'] = 'epel'
|
|
||||||
default['yum']['epel']['description'] = 'Extra Packages for Enterprise Linux 6 - $basearch'
|
|
||||||
default['yum']['epel']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch'
|
|
||||||
default['yum']['epel']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
|
||||||
default['yum']['epel']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel']['gpgcheck'] = true
|
|
||||||
default['yum']['epel']['enabled'] = true
|
|
||||||
default['yum']['epel']['managed'] = true
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel-debuginfo']['repositoryid'] = 'epel-debuginfo'
|
|
||||||
default['yum']['epel-debuginfo']['description'] = 'Extra Packages for Enterprise Linux 6 - $basearch - Debug'
|
|
||||||
default['yum']['epel-debuginfo']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=epel-debug-6&arch=$basearch'
|
|
||||||
default['yum']['epel-debuginfo']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
|
||||||
default['yum']['epel-debuginfo']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-debuginfo']['gpgcheck'] = true
|
|
||||||
default['yum']['epel-debuginfo']['enabled'] = false
|
|
||||||
default['yum']['epel-debuginfo']['managed'] = false
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel-source']['repositoryid'] = 'epel-source'
|
|
||||||
default['yum']['epel-source']['description'] = 'Extra Packages for Enterprise Linux 6 - $basearch - Source'
|
|
||||||
default['yum']['epel-source']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-6&arch=$basearch'
|
|
||||||
default['yum']['epel-source']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
|
||||||
default['yum']['epel-source']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-source']['gpgcheck'] = true
|
|
||||||
default['yum']['epel-source']['enabled'] = false
|
|
||||||
default['yum']['epel-source']['managed'] = false
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel-testing']['repositoryid'] = 'epel-testing'
|
|
||||||
default['yum']['epel-testing']['description'] = 'Extra Packages for Enterprise Linux 6 - Testing - $basearch'
|
|
||||||
default['yum']['epel-testing']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=testing-epel6&arch=$basearch'
|
|
||||||
default['yum']['epel-testing']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6r'
|
|
||||||
default['yum']['epel-testing']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-testing']['gpgcheck'] = true
|
|
||||||
default['yum']['epel-testing']['enabled'] = false
|
|
||||||
default['yum']['epel-testing']['managed'] = false
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel-testing-debuginfo']['repositoryid'] = 'epel-testing-debuginfo'
|
|
||||||
default['yum']['epel-testing-debuginfo']['description'] = 'Extra Packages for Enterprise Linux 6 - Testing - $basearch Debug'
|
|
||||||
default['yum']['epel-testing-debuginfo']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=testing-debug-epel6&arch=$basearch'
|
|
||||||
default['yum']['epel-testing-debuginfo']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
|
||||||
default['yum']['epel-testing-debuginfo']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-testing-debuginfo']['gpgcheck'] = true
|
|
||||||
default['yum']['epel-testing-debuginfo']['enabled'] = false
|
|
||||||
default['yum']['epel-testing-debuginfo']['managed'] = false
|
|
||||||
```
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
default['yum']['epel-testing-source']['repositoryid'] = 'epel-testing-source'
|
|
||||||
default['yum']['epel-testing-source']['description'] = 'Extra Packages for Enterprise Linux 6 - Testing - $basearch Source'
|
|
||||||
default['yum']['epel-testing-source']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=testing-source-epel6&arch=$basearch'
|
|
||||||
default['yum']['epel-testing-source']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
|
||||||
default['yum']['epel-testing-source']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-testing-source']['gpgcheck'] = true
|
|
||||||
default['yum']['epel-testing-source']['enabled'] = false
|
|
||||||
default['yum']['epel-testing-source']['managed'] = false
|
|
||||||
```
|
|
||||||
|
|
||||||
## Recipes
|
## Recipes
|
||||||
|
|
||||||
- default - Walks through node attributes and feeds a yum_resource
|
- `yum-epel::default` Generates `yum_repository` configs for the standard EPEL repositories. By default the `epel` repository is enabled. For CentOS Stream, the [epel-next](https://docs.fedoraproject.org/en-US/epel/#what_is_epel_next) repository is also enabled.
|
||||||
- parameters. The following is an example a resource generated by the
|
|
||||||
- recipe during compilation.
|
|
||||||
|
|
||||||
```ruby
|
|
||||||
yum_repository 'epel' do
|
|
||||||
mirrorlist 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch'
|
|
||||||
description 'Extra Packages for Enterprise Linux 5 - $basearch'
|
|
||||||
enabled true
|
|
||||||
gpgcheck true
|
|
||||||
gpgkey 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL'
|
|
||||||
end
|
|
||||||
```
|
|
||||||
|
|
||||||
## Usage Example
|
## Usage Example
|
||||||
|
|
||||||
|
@ -148,28 +93,33 @@ Point the epel repositories at an internally hosted server.
|
||||||
```ruby
|
```ruby
|
||||||
node.default['yum']['epel']['enabled'] = true
|
node.default['yum']['epel']['enabled'] = true
|
||||||
node.default['yum']['epel']['mirrorlist'] = nil
|
node.default['yum']['epel']['mirrorlist'] = nil
|
||||||
node.default['yum']['epel']['baseurl'] = 'https://internal.example.com/centos/6/os/x86_64'
|
node.default['yum']['epel']['baseurl'] = 'https://internal.example.com/centos/7/os/x86_64'
|
||||||
node.default['yum']['epel']['sslverify'] = false
|
node.default['yum']['epel']['sslverify'] = false
|
||||||
|
|
||||||
include_recipe 'yum-epel'
|
include_recipe 'yum-epel'
|
||||||
```
|
```
|
||||||
|
|
||||||
## License & Authors
|
## Contributors
|
||||||
|
|
||||||
**Author:** Cookbook Engineering Team ([cookbooks@chef.io](mailto:cookbooks@chef.io))
|
This project exists thanks to all the people who [contribute.](https://opencollective.com/sous-chefs/contributors.svg?width=890&button=false)
|
||||||
|
|
||||||
**Copyright:** 2011-2016, Chef Software, Inc.
|
### Backers
|
||||||
|
|
||||||
```
|
Thank you to all our backers!
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
you may not use this file except in compliance with the License.
|
|
||||||
You may obtain a copy of the License at
|
|
||||||
|
|
||||||
http://www.apache.org/licenses/LICENSE-2.0
|
![https://opencollective.com/sous-chefs#backers](https://opencollective.com/sous-chefs/backers.svg?width=600&avatarHeight=40)
|
||||||
|
|
||||||
Unless required by applicable law or agreed to in writing, software
|
### Sponsors
|
||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
Support this project by becoming a sponsor. Your logo will show up here with a link to your website.
|
||||||
See the License for the specific language governing permissions and
|
|
||||||
limitations under the License.
|
![https://opencollective.com/sous-chefs/sponsor/0/website](https://opencollective.com/sous-chefs/sponsor/0/avatar.svg?avatarHeight=100)
|
||||||
```
|
![https://opencollective.com/sous-chefs/sponsor/1/website](https://opencollective.com/sous-chefs/sponsor/1/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/2/website](https://opencollective.com/sous-chefs/sponsor/2/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/3/website](https://opencollective.com/sous-chefs/sponsor/3/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/4/website](https://opencollective.com/sous-chefs/sponsor/4/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/5/website](https://opencollective.com/sous-chefs/sponsor/5/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/6/website](https://opencollective.com/sous-chefs/sponsor/6/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/7/website](https://opencollective.com/sous-chefs/sponsor/7/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/8/website](https://opencollective.com/sous-chefs/sponsor/8/avatar.svg?avatarHeight=100)
|
||||||
|
![https://opencollective.com/sous-chefs/sponsor/9/website](https://opencollective.com/sous-chefs/sponsor/9/avatar.svg?avatarHeight=100)
|
||||||
|
|
|
@ -1,8 +1,28 @@
|
||||||
default['yum-epel']['repos'] = %w(
|
default['yum-epel']['repos'] =
|
||||||
epel
|
value_for_platform(
|
||||||
epel-debuginfo
|
%w(redhat centos oracle) => {
|
||||||
epel-source
|
'>= 8.0' => epel_8_repos,
|
||||||
epel-testing
|
'~> 7.0' =>
|
||||||
epel-testing-debuginfo
|
%w(
|
||||||
epel-testing-source
|
epel
|
||||||
)
|
epel-debuginfo
|
||||||
|
epel-source
|
||||||
|
epel-testing
|
||||||
|
epel-testing-debuginfo
|
||||||
|
epel-testing-source
|
||||||
|
),
|
||||||
|
},
|
||||||
|
'amazon' => {
|
||||||
|
'default' =>
|
||||||
|
%w(
|
||||||
|
epel
|
||||||
|
epel-debuginfo
|
||||||
|
epel-source
|
||||||
|
epel-testing
|
||||||
|
epel-testing-debuginfo
|
||||||
|
epel-testing-source
|
||||||
|
),
|
||||||
|
},
|
||||||
|
# No-op on non-yum systems
|
||||||
|
'default' => []
|
||||||
|
)
|
||||||
|
|
|
@ -1,19 +1,14 @@
|
||||||
default['yum']['epel-debuginfo']['repositoryid'] = 'epel-debuginfo'
|
default['yum']['epel-debuginfo']['repositoryid'] = 'epel-debuginfo'
|
||||||
default['yum']['epel-debuginfo']['description'] = "Extra Packages for #{node['platform_version'].to_i} - $basearch - Debug"
|
|
||||||
|
|
||||||
if platform?('amazon')
|
if platform?('amazon')
|
||||||
if node['platform_version'].to_i > 2010
|
default['yum']['epel-debuginfo']['description'] = 'Extra Packages for 7 - $basearch - Debug'
|
||||||
default['yum']['epel-debuginfo']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-6&arch=$basearch'
|
default['yum']['epel-debuginfo']['mirrorlist'] = 'https://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-7&arch=$basearch'
|
||||||
default['yum']['epel-debuginfo']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
default['yum']['epel-debuginfo']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7'
|
||||||
else
|
|
||||||
default['yum']['epel-debuginfo']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-7&arch=$basearch'
|
|
||||||
default['yum']['epel-debuginfo']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7'
|
|
||||||
end
|
|
||||||
else
|
else
|
||||||
default['yum']['epel-debuginfo']['mirrorlist'] = "http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-#{node['platform_version'].to_i}&arch=$basearch"
|
default['yum']['epel-debuginfo']['description'] = "Extra Packages for #{node['platform_version'].to_i} - $basearch - Debug"
|
||||||
|
default['yum']['epel-debuginfo']['mirrorlist'] = "https://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
default['yum']['epel-debuginfo']['gpgkey'] = "https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
default['yum']['epel-debuginfo']['gpgkey'] = "https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
end
|
end
|
||||||
default['yum']['epel-debuginfo']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-debuginfo']['gpgcheck'] = true
|
default['yum']['epel-debuginfo']['gpgcheck'] = true
|
||||||
default['yum']['epel-debuginfo']['enabled'] = false
|
default['yum']['epel-debuginfo']['enabled'] = false
|
||||||
default['yum']['epel-debuginfo']['managed'] = false
|
default['yum']['epel-debuginfo']['managed'] = false
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-modular-debuginfo']['repositoryid'] = 'epel-modular-debuginfo'
|
||||||
|
default['yum']['epel-modular-debuginfo']['description'] = 'Extra Packages for Enterprise Linux Modular $releasever - $basearch - Debug'
|
||||||
|
default['yum']['epel-modular-debuginfo']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=epel-modular-debug-$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-modular-debuginfo']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-modular-debuginfo']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-modular-debuginfo']['enabled'] = false
|
||||||
|
default['yum']['epel-modular-debuginfo']['managed'] = false
|
||||||
|
default['yum']['epel-modular-debuginfo']['make_cache'] = true
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-modular-source']['repositoryid'] = 'epel-modular-source'
|
||||||
|
default['yum']['epel-modular-source']['description'] = 'Extra Packages for Enterprise Linux Modular $releasever - $basearch - Source'
|
||||||
|
default['yum']['epel-modular-source']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=epel-modular-source-$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-modular-source']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-modular-source']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-modular-source']['enabled'] = false
|
||||||
|
default['yum']['epel-modular-source']['managed'] = false
|
||||||
|
default['yum']['epel-modular-source']['make_cache'] = true
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-modular']['repositoryid'] = 'epel-modular'
|
||||||
|
default['yum']['epel-modular']['description'] = 'Extra Packages for Enterprise Linux Modular $releasever - $basearch'
|
||||||
|
default['yum']['epel-modular']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=epel-modular-$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-modular']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-modular']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-modular']['enabled'] = false
|
||||||
|
default['yum']['epel-modular']['managed'] = false
|
||||||
|
default['yum']['epel-modular']['make_cache'] = true
|
|
@ -0,0 +1,11 @@
|
||||||
|
default['yum']['epel-next-debuginfo']['repositoryid'] = 'epel-next-debuginfo'
|
||||||
|
default['yum']['epel-next-debuginfo']['description'] =
|
||||||
|
"Extra Packages for #{node['platform_version'].to_i} - $basearch - Next - Debug"
|
||||||
|
default['yum']['epel-next-debuginfo']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=epel-next-debug-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next-debuginfo']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next-debuginfo']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next-debuginfo']['enabled'] = false
|
||||||
|
default['yum']['epel-next-debuginfo']['managed'] = false
|
||||||
|
default['yum']['epel-next-debuginfo']['make_cache'] = true
|
|
@ -0,0 +1,11 @@
|
||||||
|
default['yum']['epel-next-source']['repositoryid'] = 'epel-next-source'
|
||||||
|
default['yum']['epel-next-source']['description'] =
|
||||||
|
"Extra Packages for #{node['platform_version'].to_i} $basearch - Next -Source"
|
||||||
|
default['yum']['epel-next-source']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=epel-next-source-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next-source']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next-source']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next-source']['enabled'] = false
|
||||||
|
default['yum']['epel-next-source']['managed'] = false
|
||||||
|
default['yum']['epel-next-source']['make_cache'] = true
|
|
@ -0,0 +1,11 @@
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['repositoryid'] = 'epel-next-testing-debuginfo'
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['description'] =
|
||||||
|
"Extra Packages for #{node['platform_version'].to_i} - $basearch - Next - Testing Debug"
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=epel-testing-next-debug-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['enabled'] = false
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['managed'] = false
|
||||||
|
default['yum']['epel-next-testing-debuginfo']['make_cache'] = true
|
|
@ -0,0 +1,11 @@
|
||||||
|
default['yum']['epel-next-testing-source']['repositoryid'] = 'epel-next-testing-source'
|
||||||
|
default['yum']['epel-next-testing-source']['description'] =
|
||||||
|
"Extra Packages for #{node['platform_version'].to_i} - $basearch - Next - Testing Source"
|
||||||
|
default['yum']['epel-next-testing-source']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=testing-source-epel#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next-testing-source']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next-testing-source']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next-testing-source']['enabled'] = false
|
||||||
|
default['yum']['epel-next-testing-source']['managed'] = false
|
||||||
|
default['yum']['epel-next-testing-source']['make_cache'] = true
|
|
@ -0,0 +1,11 @@
|
||||||
|
default['yum']['epel-next-testing']['repositoryid'] = 'epel-next-testing'
|
||||||
|
default['yum']['epel-next-testing']['description'] =
|
||||||
|
"Extra Packages for #{node['platform_version'].to_i} - $basearch - Next - Testing"
|
||||||
|
default['yum']['epel-next-testing']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=epel-testing-next-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next-testing']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next-testing']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next-testing']['enabled'] = false
|
||||||
|
default['yum']['epel-next-testing']['managed'] = false
|
||||||
|
default['yum']['epel-next-testing']['make_cache'] = true
|
|
@ -0,0 +1,10 @@
|
||||||
|
default['yum']['epel-next']['repositoryid'] = 'epel-next'
|
||||||
|
default['yum']['epel-next']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-next']['description'] = 'Extra Packages for $releasever - Next - $basearch'
|
||||||
|
default['yum']['epel-next']['mirrorlist'] =
|
||||||
|
"https://mirrors.fedoraproject.org/mirrorlist?repo=epel-next-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
|
default['yum']['epel-next']['gpgkey'] =
|
||||||
|
"https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
|
default['yum']['epel-next']['enabled'] = true
|
||||||
|
default['yum']['epel-next']['managed'] = true
|
||||||
|
default['yum']['epel-next']['make_cache'] = true
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-playground-debuginfo']['repositoryid'] = 'epel-playground-debuginfo'
|
||||||
|
default['yum']['epel-playground-debuginfo']['description'] = 'Extra Packages for Enterprise Linux $releasever - Playground - $basearch - Debug'
|
||||||
|
default['yum']['epel-playground-debuginfo']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=playground-debug-epel$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-playground-debuginfo']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-playground-debuginfo']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-playground-debuginfo']['enabled'] = false
|
||||||
|
default['yum']['epel-playground-debuginfo']['managed'] = false
|
||||||
|
default['yum']['epel-playground-debuginfo']['make_cache'] = true
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-playground-source']['repositoryid'] = 'epel-playground-source'
|
||||||
|
default['yum']['epel-playground-source']['description'] = 'Extra Packages for Enterprise Linux $releasever - Playground - $basearch - Source'
|
||||||
|
default['yum']['epel-playground-source']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=playground-source-epel$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-playground-source']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-playground-source']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-playground-source']['enabled'] = false
|
||||||
|
default['yum']['epel-playground-source']['managed'] = false
|
||||||
|
default['yum']['epel-playground-source']['make_cache'] = true
|
|
@ -0,0 +1,8 @@
|
||||||
|
default['yum']['epel-playground']['repositoryid'] = 'epel-playground'
|
||||||
|
default['yum']['epel-playground']['description'] = 'Extra Packages for Enterprise Linux $releasever - Playground - $basearch'
|
||||||
|
default['yum']['epel-playground']['mirrorlist'] = 'https://mirrors.fedoraproject.org/metalink?repo=playground-epel$releasever&arch=$basearch&infra=$infra&content=$contentdir'
|
||||||
|
default['yum']['epel-playground']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-8'
|
||||||
|
default['yum']['epel-playground']['gpgcheck'] = true
|
||||||
|
default['yum']['epel-playground']['enabled'] = false
|
||||||
|
default['yum']['epel-playground']['managed'] = false
|
||||||
|
default['yum']['epel-playground']['make_cache'] = true
|
|
@ -1,19 +1,14 @@
|
||||||
default['yum']['epel-source']['repositoryid'] = 'epel-source'
|
default['yum']['epel-source']['repositoryid'] = 'epel-source'
|
||||||
default['yum']['epel-source']['description'] = "Extra Packages for #{node['platform_version'].to_i} - $basearch - Source"
|
|
||||||
|
|
||||||
if platform?('amazon')
|
if platform?('amazon')
|
||||||
if node['platform_version'].to_i > 2010
|
default['yum']['epel-source']['description'] = 'Extra Packages for 7 - $basearch - Source'
|
||||||
default['yum']['epel-source']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-6&arch=$basearch'
|
default['yum']['epel-source']['mirrorlist'] = 'https://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-7&arch=$basearch'
|
||||||
default['yum']['epel-source']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-6'
|
default['yum']['epel-source']['gpgkey'] = 'https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7'
|
||||||
else
|
|
||||||
default['yum']['epel-source']['mirrorlist'] = 'http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-7&arch=$basearch'
|
|
||||||
default['yum']['epel-source']['gpgkey'] = 'http://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-7'
|
|
||||||
end
|
|
||||||
else
|
else
|
||||||
default['yum']['epel-source']['mirrorlist'] = "http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-#{node['platform_version'].to_i}&arch=$basearch"
|
default['yum']['epel-source']['description'] = "Extra Packages for #{node['platform_version'].to_i} - $basearch - Source"
|
||||||
|
default['yum']['epel-source']['mirrorlist'] = "https://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-#{node['platform_version'].to_i}&arch=$basearch"
|
||||||
default['yum']['epel-source']['gpgkey'] = "https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
default['yum']['epel-source']['gpgkey'] = "https://download.fedoraproject.org/pub/epel/RPM-GPG-KEY-EPEL-#{node['platform_version'].to_i}"
|
||||||
end
|
end
|
||||||
default['yum']['epel-source']['failovermethod'] = 'priority'
|
|
||||||
default['yum']['epel-source']['gpgcheck'] = true
|
default['yum']['epel-source']['gpgcheck'] = true
|
||||||
default['yum']['epel-source']['enabled'] = false
|
default['yum']['epel-source']['enabled'] = false
|
||||||
default['yum']['epel-source']['managed'] = false
|
default['yum']['epel-source']['managed'] = false
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue