I am not new to puppet, but I am new to using it on Windows. Trying to configure chocolatey using the puppetlabs/chocolatey module. Initial puppet run without the module worked just fine. Then I added include chocolatey to the manifest, and it downloaded and installed chocolatey. So far, so good. However, then I went to add a custom source like so:
chocolateysource { 'mysource':
ensure => present,
location => 'https://my.chocolatey.source',
priority => 10,
}
Now I get the following message when running puppet agent -t:
PS C:\Windows\system32> puppet agent -t
Error: Could not autoload puppet/provider/package/chocolatey: C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/provider/package/chocolatey.rb:280: syntax error, unexpected '.'
pin_output&.split("\n")&.each { |pin| pin...
^
C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/provider/package/chocolatey.rb:280: syntax error, unexpected '.'
... pin_output&.split("\n")&.each { |pin| pins << pin.spli...
... ^
Error: Facter: error while resolving custom facts in C:/ProgramData\PuppetLabs\puppet\cache\lib\facter\package_provider.rb: Could not autoload puppet/provider/package/chocolatey: C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/provider/package/chocolatey.rb:280: syntax error, unexpected '.'
pin_output&.split("\n")&.each { |pin| pin...
^
C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/provider/package/chocolatey.rb:280: syntax error, unexpected '.'
... pin_output&.split("\n")&.each { |pin| pins << pin.spli...
... ^
Info: Using configured environment 'production'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Loading facts
Info: Redefining package in Puppet::Type
Error: Could not autoload puppet/type/chocolateysource: C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/type/chocolateysource.rb:221: syntax error, unexpected '.'
parameter(:password)&.sensitive = true
^
Error: Could not retrieve catalog from remote server: Could not intern from text/pson: Could not autoload puppet/type/chocolateysource: C:/ProgramData/PuppetLabs/puppet/cache/lib/puppet/type/chocolateysource.rb:221: syntax error, unexpected '.'
parameter(:password)&.sensitive = true
^
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
As a non-Windows user, I feel like I'm missing something to make this work, but I'm not sure what it is. I have verified that .Net framework is installed, but not sure what else to check here. Thanks in advance for any help.
Turns out the version was the issue. I had mistakenly installed puppet 4 agent, while the server is puppet 7.
Related
An unknown server-side error occurred while processing the command. Original error: Cannot verify the signature of '/Applications/Appium.app/Contents/Resources/app/node_modules/appium/node_modules/appium-uiautomator2-server/apks/appium-uiautomator2-server-v4.21.1.apk'. Original error: The JAVA_HOME location '/Library/Java/JavaVirtualMachines/jdk-17.0.1.jdk/Contents/Home ' must exist
Can you please check if JAVA_HOME is being configured on your local machine?
I deployed an app with netlify + gatsby default options and then I cloned that repo, so I can edit the style. The problem is that it doesn't work on my machine, the following error persists:
2 problems (0 errors, 2 warnings)
ERROR #98123 WEBPACK
Generating development JavaScript bundle failed
$black: #2b2523;
^
Invalid CSS after "...black: #2b2523;": expected 1 selector or at-rule,
was ".navbar .navbar-men"
in /Users/micazev/Documents/ecominimalismo.com/src/components/all.sass
(line 11, column 17)
File: src/components/all.sass
failed Building development bundle - 22.833s
ERROR Failed to compile with 1 errors 14:39:49
⠀
error in ./src/components/all.sass
⠀
Module build failed (from
./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from
./node_modules/sass-loader/dist/cjs.js):
$black: #2b2523;
^
Invalid CSS after "...black: #2b2523;": expected 1 selector or at-rule,
was ".navbar .navbar-men"
in /Users/micazev/Documents/ecominimalismo.com/src/components/all.sass
(line 11, column 17)
at /Users/micazev/Documents/ecominimalismo.com/node_modules/webpack/lib/Norm
alModule.js:316:20
at /Users/micazev/Documents/ecominimalismo.com/node_modules/loader-runner/li
b/LoaderRunner.js:367:11
at /Users/micazev/Documents/ecominimalismo.com/node_modules/loader-runner/li
b/LoaderRunner.js:233:18
at context.callback (/Users/micazev/Documents/ecominimalismo.com/node_module
s/loader-runner/lib/LoaderRunner.js:111:13)
at Object.callback (/Users/micazev/Documents/ecominimalismo.com/node_modules
/sass-loader/dist/index.js:89:7)
at Object.done [as callback] (/Users/micazev/Documents/ecominimalismo.com/no
de_modules/neo-async/async.js:8069:18)
at options.error (/Users/micazev/Documents/ecominimalismo.com/node_modules/n
ode-sass/lib/index.js:294:32)
# ./src/components/Layout.js 17:0-20
# ./src/templates/blog-post.js
# ./src/cms/preview-templates/BlogPostPreview.js
# ./src/cms/cms.js
# multi ./node_modules/gatsby-plugin-netlify-cms/cms.js
./node_modules/gatsby-plugin-netlify-cms/cms-identity.js ./src/cms/cms.js
My repo is: https://github.com/micazev/ecominimalismo.com
I don't know what other info I could give. Please, help.
According to some threads about that starter, there's a bug about the Sass loaders that causes this issue. You have many solutions provided in this GitHub thread:
Add options to the gatsby-plugin-sass:
{
resolve: 'gatsby-plugin-sass',
options: {
indentedSyntax: true
}
}
This will allow the loader to understand the indented syntax of Sass.
Changing the extension from .sass to .scss, changing also all the references in the project: you'll need to add semicolons (;) and braces ({}) when needed.
Obviously, the second one is easier and safer.
I am testing this out and getting an error on the Puppet agent node
[root#pagent1 ~]# puppet agent -t
Info: Using configured environment 'production'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Retrieving locales
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Function Call, Could not find class ::nginx for pagent1.testcentos7.com (file: /etc/puppetlabs/code/environments/production/manifests/site.pp, line: 3, column: 3) on node pagent1.testcentos7.com
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run
Content of these classes from the Puppet server:
[root#pmaster ~]# cat /etc/puppetlabs/code/environments/production/manifests/site.pp
node pagent1.testcentos7.com {
class { 'nginx': }
}
[root#pmaster ~]# cat /etc/puppetlabs/code/environments/production/modules/nginx/manifests/manifests/init.pp
class nginx {
contain nginx::install
}
[root#pmaster ~]# cat /etc/puppetlabs/code/environments/production/modules/nginx/manifests/install.pp
class nginx::install {
package { 'install_nginx':
name => 'nginx',
ensure => 'present',
}
}
Syntax check shows this error:
[root#pmaster ~]# puppet parser validate /etc/puppetlabs/code/environments/production/modules/nginx/manifests/manifests/init.pp
Error: Could not parse for environment production: Unacceptable location. The name 'nginx' is unacceptable in file '/etc/puppetlabs/code/environments/production/modules/nginx/manifests/manifests/init.pp' (file: /etc/puppetlabs/code/environments/production/modules/nginx/manifests/manifests/init.pp, line: 7, column: 1)
NOTE: Created module 'nginx' and its classes using Puppet Development Kit(PDK).
Is that a bug or something or I made a mistake with the class name?.
Related thread I found is https://groups.google.com/forum/embed/#!topic/puppet-users/nxbwCvWrgMI but would like to have someone simplify this for me
Solved this by moving 'init.pp' to the path /etc/puppetlabs/code/environments/production/modules/nginx/manifests where install class file 'install.pp' exists.
For more clarity, I put both the files 'init.pp' and 'install.pp' in the same location directory /etc/puppetlabs/code/environments/production/modules/nginx/manifests to solve this.
Trying out puppet-acl module on Windows Server 2016, Preview5. I'm getting the weirdest error on the second puppet run. If i remove the trnsactionstore.yaml file, and re-run the puppet agent, the behavior is repeatable. Im running puppet4 with latest agent version.
This is my codeblock
acl { "c:/temp":
permissions => [
{ identity => 'Administrator', rights => ['full'] },
{ identity => 'Users', rights => ['read','execute'] }
],
}
This is the output from the puppet-run.
PS C:\ProgramData\PuppetLabs\puppet\cache\state> puppet agent -t
Info: Using configured environment 'local'
Info: Retrieving pluginfacts
Info: Retrieving plugin
Info: Loading facts
Info: Caching catalog for opslowebf02n02.local
Error: Transaction store file C:/ProgramData/PuppetLabs/puppet/cache/state/transactionstore.yaml is corrupt (wrong number of arguments (0 for 1..2)); replacing
Error: Transaction state file C:/ProgramData/PuppetLabs/puppet/cache/state/transactionstore.yaml is valid YAML but not returning a hash. Check the file for corruption, or remove it before continuing.
Info: Applying configuration version '1471436916'
Notice: /Stage[main]/platform_base_system::Role::Windows/Exec[check-powershell-exection-policy]/returns: executed successfully
Notice: /Stage[main]/configs_iis::Profile::Default/Exec[check-iis-global-anonymous-authentication]/returns: executed successfully
Notice: Applied catalog in 7.42 seconds
In the transactionstore.yaml file, this is the error section:
Acl[c:/temp]:
parameters:
permissions:
system_value:
- !ruby/hash:Puppet::Type::Acl::Ace {}
- !ruby/hash:Puppet::Type::Acl::Ace {}
inherit_parent_permissions:
system_value: :true
This has been resolved by dowwngrading the puppet agent to 4.5.3.
Behavior of the 4.6.0 version must have changed.
With 4.5.3 i still see the error in the logfile, but the puppetrun does not fail
I'll try to talk to the people at puppet about this.
Acl[c:/temp]:
parameters:
permissions:
system_value:
- !ruby/hash:Puppet::Type::Acl::Ace {}
- !ruby/hash:Puppet::Type::Acl::Ace {}
inherit_parent_permissions:
system_value: :true
This is being tracked as https://tickets.puppetlabs.com/browse/PUP-6629. It's almost coincidental that you created https://tickets.puppetlabs.com/browse/PUP-6630 right afterwards.
I am running openwrt on beagle bone black board. I am getting following error while running freeradius.
radiusd -X
rlm_eap: SSL error error:02001002:lib(2):func(1):reason(2)
rlm_eap_tls: Error reading certificate file /etc/freeradius2/certs/server.pem
rlm_eap: Failed to initialize type tls
/etc/freeradius2/eap.conf[17]: Instantiation failed for module "eap"
/etc/freeradius2/sites/default[312]: Failed to find "eap" in the "modules" section.
/etc/freeradius2/sites/default[254]: Errors parsing authenticate section.
when i checked there is no "cert" directory present in /etc/freeradius2/. Plz help
Problem was solved after installing freeradius2-democerts_2.2.7-1_omap.ipk
after installing following error might trouble:
Debug: Module: Checking authorize {...} for more modules to load
Error: /etc/freeradius2/sites/default[160]: Failed to find "reject" in the "modules" section.
Error: /etc/freeradius2/sites/default[69]: Errors parsing authorize section.
to resolve this go to /etc/freeradius2/sites/default line no. 160. comment the line which has reject word.