Page MenuHomePhabricator

service::node managed templates cannot see calling scope variables under Puppet4
Closed, ResolvedPublic

Description

It looks like Parsoid's systemd config file is missing some variable values. The line
ExecStart=/usr/bin/nodejs <%= @script %> -c <%= @dir %>/config.vagrant.yaml
appears to be rendered as
ExecStart=/usr/bin/nodejs -c /config.vagrant.yaml
in /etc/systemd/system/multi-user.target.wants/parsoid.service

Event Timeline

SBisson created this task.Jan 17 2018, 4:18 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJan 17 2018, 4:18 PM

restbase and citoid systemd config files have the same issue (I didn't check any other ones)

bd808 added a subscriber: bd808.Jan 17 2018, 4:36 PM

With Puppet4, local scope variables are no longer passed through to templates rendered by defines (which is how service::node works).

There are 2 ways to fix it:

This probably affects all service::node uses in the Puppet codebase:

  • changeprop
  • citiod
  • graphoid
  • mathoid
  • mobileapps
  • parsoid
  • restbase
bd808 renamed this task from Parsoid not working after a fresh vagrant up to service::node managed templates cannot see calling scope variables under Puppet4.Jan 17 2018, 4:37 PM

Change 404908 had a related patch set uploaded (by BryanDavis; owner: Bryan Davis):
[mediawiki/vagrant@master] service::node: Use epp template for systemd service

https://gerrit.wikimedia.org/r/404908

Change 404908 merged by jenkins-bot:
[mediawiki/vagrant@master] service::node: Use epp template for systemd service

https://gerrit.wikimedia.org/r/404908

bd808 closed this task as Resolved.Jan 18 2018, 4:43 AM
bd808 claimed this task.