FAQ
I think you need to double quote strings that contain variables. So try:

     line => "INSTANCE=$instance",

-Steve

On Fri, Mar 28, 2014 at 1:58 PM, Matt Gieselman wrote:

Given the following snippet from an init.pp file:

$instance = 22

file_line { 'instance' :

path => '/etc/init.d/myfile',

line => 'INSTANCE=$instance',

match => 'INSTANCE='

}

What I expect to happen is have the line in /etc/init.d/myfile change from
INSTANCE=1 to INSTANCE=22, what happens is the file has INSTANCE=$instance
any suggestions?

--
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 puppet-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/puppet-users/879ed188-481d-4c25-805c-acd5ce1b3a85%40googlegroups.com<https://groups.google.com/d/msgid/puppet-users/879ed188-481d-4c25-805c-acd5ce1b3a85%40googlegroups.com?utm_medium=email&utm_source=footer>
.
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 puppet-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CANVRfYqpXnazJ%2BhyTHVhHy6C_pFB9qBK_Es6E2a8pObgrsU8UA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 2 | next ›
Discussion Overview
grouppuppet-users @
categoriespuppet
postedMar 28, '14 at 6:00p
activeMar 28, '14 at 6:02p
posts2
users2
websitepuppetlabs.com

2 users in discussion

Stephen Jahl: 1 post Matt Gieselman: 1 post

People

Translate

site design / logo © 2022 Grokbase