On 19/05/16 17:22, Julie Iaccarino wrote:
Hey all! I've got a bit of an oddity.

I've upgraded from 3.7 to 4.4 and gone over the upgrade checklist for my
code, but I'm still getting some catalog errors.


    2016-05-19 15:06:51 +0000 Puppet (err): Could not retrieve catalog
    from remote server: Error 400 on SERVER: Evaluation Error: Error
    while evaluating a Resource Statement, Evaluation Error: Error while
    evaluating a Resource Statement, Cannot alias
    Registry_value[register host key Debug.1.00.2073 build copy
    c:\webservicestore.zip] to
    
["HKEY_CURRENT_USER\\Software\\SimonTatham\\PuTTY\\SshHostKeys\\################"]
    at
    
/etc/puppetlabs/code/environments/production/modules/profiles/manifests/build/scp_copy.pp:5;
    resource ["Registry_value",
    
"HKEY_CURRENT_USER\\Software\\SimonTatham\\PuTTY\\SshHostKeys\\##############"]
    already declared at
    
/etc/puppetlabs/code/environments/production/modules/profiles/manifests/build/scp_copy.pp:5
    at
    
/etc/puppetlabs/code/environments/production/modules/profiles/manifests/build/scp_copy.pp:5:5
    at
    
/etc/puppetlabs/code/environments/production/modules/profiles/manifests/build/util/zip_retrieve.pp:12
    on node ##################



It's nothing super fancy, just a SCP script on puppet:
|
define profiles::build::scp_copy ($sharename = $title, $source,
$destination) {

    # Add the host key to the server if it doesn't already exist.
    # Without this, scp will fail in batch mode because the host might
be spoofed.
    registry_value { "register host key ${sharename}":
         ensure => present,
         path   =>
"HKEY_CURRENT_USER\\Software\\SimonTatham\\PuTTY\\SshHostKeys\\######",

         type   => string,
         data   => "#######"
    }

    # Copy the file specified in source to destination.
    exec { "copy build ${sharename}":
         provider => 'powershell',
         command  => "pscp -batch -pw ##############
#############@##############:${source} ${destination}"
    }
}
|


Being utilized like:

|
profiles::build::scp_copy { "${buildType}.${buildNo} build copy
${zipSaveAbsolutePath}":
        source      => '${buildNo}\\${buildType}.${buildNo}.zip',
        destination => '${zipSaveAbsolutePath}'
    }
|

I'm sure it's something easy that I'm missing. But I'm quite stuck. Any
ideas?


The problem may be outside of these snippets. What the error is telling you is that the path you are managing is also managed by some other resource. Thus you may have a problem elsewhere where you now (because of changes to the language in 4.x from 3.x (unless you ran 3.7 with future parser)).

That is not much, but I hope it helps.

- henrik

--
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]
<mailto:[email protected]>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/c695e60f-3bc6-4ab9-b197-b517139dc2e9%40googlegroups.com
<https://groups.google.com/d/msgid/puppet-users/c695e60f-3bc6-4ab9-b197-b517139dc2e9%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.


--

Visit my Blog "Puppet on the Edge"
http://puppet-on-the-edge.blogspot.se/

--
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/44c997a1-a88f-ddbc-c99c-e1e957618443%40puppet.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to