title: Unable to override path for NodeJS binary in Assetic config
body: <p>I am having problems overriding the path to the Node.js binary used by the UglifyCSS filter in Assetic. <em>Supposedly</em> one can set the path in the <code>/app/config/config.yml</code> (<a href="https://symfony.com/doc/3.3/reference/configuration/assetic.html" rel="nofollow noreferrer">Symfony docs</a>, <a href="https://stackoverflow.com/questions/22198205/symfony2-assetic-path-to-node-executable-could-not-be-resolved">SO question</a>), but it does not seem to have any effect, no matter where I put the overridden value.</p>
  <p>To debug this, I changed line 37-39 in <code>vendor/kriswallsmith/assetic/src/Assetic/Filter/UglifyCssFilter.php</code> to output the value:</p>
  <pre><code>/**
   * @param string $uglifycssBin Absolute path to the uglifycss executable
   * @param string $nodeBin      Absolute path to the folder containg node.js executable
   */
  public function __construct($uglifycssBin = '/usr/bin/uglifycss', $nodeBin = null)
  {
          throw new \RuntimeException('Path to node executable '. $nodeBin . ' Uglify executable '. $uglifycssBin . &quot;\n\$PATH: &quot;. getenv('PATH'));
  </code></pre>
  <p>Here is the result</p>
  <pre><code>$ ../bin/console assetic:dump --env=prod
  
                                                                                                                                                                                  
    [RuntimeException]                                                                                                                                                            
    Path to node executable /usr/local/bin/node Uglify executable /home/myuser/dev/ptflow-api/app/../node_modules/.bin/uglifycss                                                
    $PATH: /home/myuser/.sdkman/candidates/java/current/bin:/home/myuser/go/bin:/home/myuser/.local/bin:/home/myuser/bin/Telegram:/home/myuser/.yarn/bin:/home/carleri  
    k/.config/yarn/global/node_modules/.bin:/home/myuser/bin:/home/myuser/.yarn/bin:/home/myuser/.config/yarn/global/node_modules/.bin:/home/myuser/go/bin:/home/carleri  
    k/.go/bin:/home/myuser/.cargo/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin                                        
                                                                                                                                                                                  
  </code></pre>
  <p>This shows that <code>$nodeBin</code> always has the value <code>/usr/local/bin/node</code>. This <em>is</em> actually the right path on my system, but I need to be able to set it manually for it to work in a Docker container that does not find the right executable.</p>
  <p>The example configs I have seen so far differ in whether to use the parameter path <code>assetic.node</code> or <code>assetic.node.bin</code>, but I have set both, in addition to <code>assetic.filters.uglifycss.node</code>:</p>
  <pre><code>assetic:
      node: /not/a/path/config.yml/node
          bin: '/usr/bin/node'
  </code></pre>
  <p>I also found a file that seemed to give some insight:</p>
  <pre><code>$ cat ./vendor/symfony/assetic-bundle/Resources/config/filters/uglifycss.xml 
  &lt;?xml version=&quot;1.0&quot; ?&gt;
  
  &lt;container xmlns=&quot;http://symfony.com/schema/dic/services&quot;
      xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;
      xsi:schemaLocation=&quot;http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd&quot;&gt;
  
      &lt;parameters&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.class&quot;&gt;Assetic\Filter\UglifyCssFilter&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.bin&quot;&gt;/usr/bin/uglifycss&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.node&quot;&gt;%assetic.node.bin%&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.timeout&quot;&gt;null&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.node_paths&quot;&gt;%assetic.node.paths%&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.expand_vars&quot;&gt;false&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.ugly_comments&quot;&gt;false&lt;/parameter&gt;
          &lt;parameter key=&quot;assetic.filter.uglifycss.cute_comments&quot;&gt;false&lt;/parameter&gt;
      &lt;/parameters&gt;
  
      &lt;services&gt;
          &lt;service id=&quot;assetic.filter.uglifycss&quot; class=&quot;%assetic.filter.uglifycss.class%&quot;&gt;
              &lt;tag name=&quot;assetic.filter&quot; alias=&quot;uglifycss&quot; /&gt;
              &lt;argument&gt;%assetic.filter.uglifycss.bin%&lt;/argument&gt;
              &lt;argument&gt;%assetic.filter.uglifycss.node%&lt;/argument&gt;
              &lt;call method=&quot;setTimeout&quot;&gt;&lt;argument&gt;%assetic.filter.uglifycss.timeout%&lt;/argument&gt;&lt;/call&gt;
              &lt;call method=&quot;setNodePaths&quot;&gt;&lt;argument&gt;%assetic.filter.uglifycss.node_paths%&lt;/argument&gt;&lt;/call&gt;
              &lt;call method=&quot;setExpandVars&quot;&gt;&lt;argument&gt;%assetic.filter.uglifycss.expand_vars%&lt;/argument&gt;&lt;/call&gt;
              &lt;call method=&quot;setUglyComments&quot;&gt;&lt;argument&gt;%assetic.filter.uglifycss.ugly_comments%&lt;/argument&gt;&lt;/call&gt;
              &lt;call method=&quot;setCuteComments&quot;&gt;&lt;argument&gt;%assetic.filter.uglifycss.cute_comments%&lt;/argument&gt;&lt;/call&gt;
          &lt;/service&gt;
      &lt;/services&gt;
  &lt;/container&gt;
  </code></pre>
  <p>This seems to indicate that setting either <code>assetic.filter.uglifycss.node</code> or <code>assetic.node.bin</code> both should work. Neither does... The XML file seems to describe how to call the filter using reflection. I am not that well versed in PHP development (NodeJS, Java, .NET background), so I am not sure which code will use this further up the stack.</p>
  <p>I am using Symfony 3.3 and the Assetic 2.8 bundle.</p>