Skip to content

Commit 5bb45b6

Browse files
authored
Merge pull request #398 from puppetlabs/pdksync_maint/pdk_update_20-04
pdksync - (Maint) PDK Update
2 parents 1ec6540 + 2dde826 commit 5bb45b6

File tree

12 files changed

+60
-53
lines changed

12 files changed

+60
-53
lines changed

.github/workflows/nightly.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,5 +200,5 @@ jobs:
200200
repo_token: ${{ secrets.GITHUB_TOKEN }}
201201
slack_webhook_url: ${{ secrets.SLACK_WEBHOOK }}
202202
# Optional Input
203-
channel: '#team-ia-bots'
203+
channel: '#team-cat-bots'
204204
name: 'GABot'

.github/workflows/pr_test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on: [pull_request]
44

55

66
env:
7+
78
HONEYCOMB_WRITEKEY: 7f3c63a70eecc61d635917de46bea4e6
89
HONEYCOMB_DATASET: litmus tests
910

.github/workflows/spec.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ jobs:
5454
buildevents step $TRACE_ID $STEP_ID $STEP_START 'Setup Environment'
5555
echo STEP_ID=Setup-Acceptance-Test-Matrix >> $GITHUB_ENV
5656
echo STEP_START=$(date +%s) >> $GITHUB_ENV
57-
# - name: Run Static & Syntax Tests
58-
# if: ${{ github.repository_owner == 'puppetlabs' }}
59-
# run: |
60-
# buildevents cmd $TRACE_ID $STEP_ID 'static_syntax_checks' -- bundle exec rake syntax lint metadata_lint check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop
57+
- name: Run Static & Syntax Tests
58+
if: ${{ github.repository_owner == 'puppetlabs' }}
59+
run: |
60+
buildevents cmd $TRACE_ID $STEP_ID 'static_syntax_checks' -- bundle exec rake syntax lint metadata_lint check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop
6161
6262
- name: Setup Spec Test Matrix
6363
id: get-matrix

.puppet-lint.rc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
--relative
2+
--no-parameter_documentation-check
3+
--no-parameter_type-check

.sync.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,3 +29,7 @@ spec/spec_helper.rb:
2929
unmanaged: false
3030
.travis.yml:
3131
delete: true
32+
Rakefile:
33+
extra_disabled_lint_checks:
34+
- parameter_documentation
35+
- parameter_type

Rakefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ def changelog_future_release
4242
end
4343

4444
PuppetLint.configuration.send('disable_relative')
45+
PuppetLint.configuration.send('disable_parameter_documentation')
46+
PuppetLint.configuration.send('disable_parameter_type')
4547

4648

4749
if Bundler.rubygems.find_name('github_changelog_generator').any?

lib/puppet/provider/java_ks/keytool.rb

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ def update
280280
end
281281

282282
def certificate
283-
return @resource[:certificate] if @resource[:certificate]
283+
return @resource[:certificate] if @resource[:certificate]
284284

285285
# When no certificate file is specified, we infer the usage of
286286
# certificate content and create a tempfile containing this value.
@@ -296,20 +296,17 @@ def certificate
296296

297297
def private_key
298298
return @resource[:private_key] if @resource[:private_key]
299-
if @resource[:private_key_content]
300-
301-
302-
# When no private key file is specified, we infer the usage of
303-
# private key content and create a tempfile containing this value.
304-
# we leave it to to the tempfile to clean it up after the pupet run exists.
305-
file = Tempfile.new('private_key')
306-
# Check if the specified value is a Sensitive data type. If so, unwrap it and use
307-
# the value.
308-
content = @resource[:private_key_content].respond_to?(:unwrap) ? @resource[:private_key_content].unwrap : @resource[:private_key_content]
309-
file.write(content)
310-
file.close
311-
file.path
312-
end
299+
return unless @resource[:private_key_content]
300+
# When no private key file is specified, we infer the usage of
301+
# private key content and create a tempfile containing this value.
302+
# we leave it to to the tempfile to clean it up after the pupet run exists.
303+
file = Tempfile.new('private_key')
304+
# Check if the specified value is a Sensitive data type. If so, unwrap it and use
305+
# the value.
306+
content = @resource[:private_key_content].respond_to?(:unwrap) ? @resource[:private_key_content].unwrap : @resource[:private_key_content]
307+
file.write(content)
308+
file.close
309+
file.path
313310
end
314311

315312
def private_key_type

lib/puppet/type/java_ks.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def insync?(is)
8686
desc 'If you want an application to be a server and encrypt traffic,
8787
you will need a private key. Private key entries in a keystore must be
8888
accompanied by a signed certificate for the keytool provider. This parameter
89-
allows you to specify the file name containing the private key. This will autorequire
89+
allows you to specify the file name containing the private key. This will autorequire
9090
the specified file.'
9191
end
9292

manifests/config.pp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# java_ks configuration
33
#
44
class java_ks::config (
5-
$params = {},
6-
){
7-
create_resources('java_ks', $params )
5+
$params = {},
6+
) {
7+
create_resources('java_ks', $params )
88
}

metadata.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,6 @@
109109
],
110110
"description": "Uses a combination of keytool and Ruby openssl library to manage entries in a Java keystore.",
111111
"template-url": "https://github.com/puppetlabs/pdk-templates.git#main",
112-
"template-ref": "heads/main-0-gf3911d3",
113-
"pdk-version": "2.3.0"
112+
"template-ref": "heads/main-0-g806810b",
113+
"pdk-version": "2.4.0"
114114
}

0 commit comments

Comments
 (0)