Hi Jochen, I’m going to give this back to the rest of the list since I’m out of my depth, and I don’t have the time to figure out the details at the moment. Good luck though 😊
Peter From: Jochen Haeberle Sent: 06 March 2018 00:48 To: [email protected] Subject: Re: [Puppet Users] Unable to solve a require statement Hi Peter, The MySQL profile does indeed install the MySQL-client. But I can’t require it in the other profile class. In class profile::software::wordpress I put require profile::software::mysql, where I call the puppetlabs-mysql module to do the actual installation. Is there a better way to describe the dependency? Jochen Am 05.03.2018 um 21:19 schrieb P C Kroon <[email protected]>: Hi, Make sure you have that module also install the MySQL client, and require mysql::client. I’m deliberately vague on the exact syntax since I’m not sure. Peter From: Jochen Haeberle Sent: 03 March 2018 13:43 To: [email protected] Subject: Re: [Puppet Users] Unable to solve a require statement Hi Peter, Thanks for the tip. I tried that already, but it results in a Error: Could not find resource 'Package[mysql-client]' in parameter 'require' (file: /etc/puppetlabs/code/environments/production/modules/profile/manifests/software/wordpress.pp, line: 26) on node stretch.localdomain I tried to require my profile::mysql class, where it set up the mailserver using puppetlabs-mysql, but this does not help. Thanks, Jochen Am 02.03.2018 um 19:08 schrieb P C Kroon <[email protected]>: Hi Jochen, Try the following: require => [File[‘php-wpcli_latest_all.deb’], Package[‘mysql-client’]], HTH Peter From: Jochen Häberle Sent: 02 March 2018 04:56 To: [email protected] Subject: [Puppet Users] Unable to solve a require statement Hi, I am having a problem installing wp-cli alongside MySQL on Debian 9.3 using latest Puppet 5.4 I am using rotes and Profiles and in my wordpress.pp I have: # WP-CLI # TODO install latest wp-cli file { 'php-wpcli_latest_all.deb': path => '/tmp/php-wpcli_latest_all.deb', ensure => 'file', source => 'puppet:///modules/profile/wordpress/php-wpcli_1.5.0_all.deb', } package { 'wpcli': provider => dpkg, ensure => installed, source => '/tmp/php-wpcli_latest_all.deb', # require => File['php-wpcli_latest_all.deb'], # require => Service['mysql'], # require => Service['mysql'], } You see some of the require Statements I already tried ;-) To install MySQL (or MariaDB) I am using puppetlabs/mysql module from the Forge. I am setting this up in a mysql Profile which I require in the former mentioned wordpress.pp. In my node definition, I include mysql.pp before wordpress.pp The error I get is the following (among similar ones): Error: Execution of '/usr/bin/dpkg --force-confold -i /tmp/php-wpcli_latest_all.deb' returned 1: Selecting previously unselected package php-wpcli. (Reading database ... 62113 files and directories currently installed.) Preparing to unpack /tmp/php-wpcli_latest_all.deb ... Unpacking php-wpcli (1.5.0) ... dpkg: dependency problems prevent configuration of php-wpcli: php-wpcli depends on mysql-client | mariadb-client; however: Package mysql-client is not installed. Package mariadb-client is not installed. dpkg: error processing package php-wpcli (--install): dependency problems - leaving unconfigured Processing triggers for man-db (2.7.6.1-2) ... Errors were encountered while processing: php-wpcli Error: /Stage[main]/Profile::Software::Wordpress/Package[wpcli]/ensure: change from 'purged' to 'present' failed: Execution of '/usr/bin/dpkg --force-confold -i /tmp/php-wpcli_latest_all.deb' returned 1: Selecting previously unselected package php-wpcli. (Reading database ... 62113 files and directories currently installed.) Preparing to unpack /tmp/php-wpcli_latest_all.deb ... Unpacking php-wpcli (1.5.0) ... dpkg: dependency problems prevent configuration of php-wpcli: php-wpcli depends on mysql-client | mariadb-client; however: Package mysql-client is not installed. Package mariadb-client is not installed. dpkg: error processing package php-wpcli (--install): dependency problems - leaving unconfigured Processing triggers for man-db (2.7.6.1-2) ... Errors were encountered while processing: php-wpcli as I can install wp-cli using puppet when MySQL is already installed through puppet, this is clearly an issue of sequence. But I cannot find a way to solve this and to have MySQL installied before wp-cli. Can anyone help me out, please? Thanks, erhards Jochen -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/19ADAF36-F85F-445E-AF5C-B59E47237BB8%40gmail.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5a99930e.46d3620a.a69c6.203e%40mx.google.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/C2ECE598-168D-4915-B0BD-0BE535757BA6%40gmail.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5a9da66f.44196b0a.e76d5.428f%40mx.google.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/FC42C939-7E6D-4184-8942-0A02A1FF2A24%40gmail.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/5a9ef0f1.8e5d620a.8ce26.c336%40mx.google.com. For more options, visit https://groups.google.com/d/optout.
