<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>47705</bug_id>
          
          <creation_ts>2023-09-23 12:46:15 +0300</creation_ts>
          <short_desc>Не запускается сервис PuppetServer (requires Ruby 3.1.0 or greater)</short_desc>
          <delta_ts>2024-03-15 15:50:18 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>puppetserver</component>
          <version>unstable</version>
          <rep_platform>x86_64</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugzilla.altlinux.org/show_bug.cgi?id=40238</see_also>
    
    <see_also>https://bugzilla.altlinux.org/show_bug.cgi?id=38464</see_also>
    
    <see_also>https://bugzilla.altlinux.org/show_bug.cgi?id=49169</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Evgeny Shesteperov">alimektor</reporter>
          <assigned_to name="majioa@altlinux.org">majioa</assigned_to>
          <cc>3aHyga</cc>
    
    <cc>amakeenk</cc>
    
    <cc>cas</cc>
    
    <cc>majioa</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>233735</commentid>
    <comment_count>0</comment_count>
    <who name="Evgeny Shesteperov">alimektor</who>
    <bug_when>2023-09-23 12:46:15 +0300</bug_when>
    <thetext>Версия

-   gem-puppet-7.24.0.161-alt2
-   puppetserver-6.20.0-alt1
-   java-17-openjdk-17.0.8.0.7-alt2

Шаги воспроизведения

    # apt-get install -y puppet puppetserver java-17-openjdk
    # systemctl enable --now puppet &amp;&amp; sleep 5; systemctl status puppet --no-pager -l
    # systemctl start puppetserver &amp;&amp; sleep 5; systemctl status puppetserver --no-pager -l

Ожидаемый результат: сервис active (running)

Фактический результат: сервис failed (Result: exit-code)

В логах /var/log/puppetserver/puppetserver.log характерное :

    Caused by: org.jruby.exceptions.LoadError: (LoadError) Puppet 8.0.0 requires Ruby 3.1.0 or greater, found Ruby 2.5.7.

Файл, ломающий это,
/usr/lib/ruby/gemie/gems/puppet-7.24.0.161/lib/puppet.rb:

    Puppet::OLDEST_RECOMMENDED_RUBY_VERSION = &apos;3.1.0&apos;
    if Gem::Version.new(RUBY_VERSION.dup) &lt; Gem::Version.new(Puppet::OLDEST_RECOMMENDED_RUBY_VERSION)
      raise LoadError, &quot;Puppet #{Puppet.version} requires Ruby #{Puppet::OLDEST_RECOMMENDED_RUBY_VERSION} or greater, found Ruby #{RUBY_VERSION.dup}.&quot;
    end

Причина в том, что используется старая версия JRuby:

    # puppetserver ruby --version
    jruby 9.2.13.0 (2.5.7) 2020-08-03 9a89c94bcc OpenJDK 64-Bit Server VM 17.0.8+7 on 17.0.8+7 +jit [linux-x86_64]

Не воспроизводится в P10.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>241246</commentid>
    <comment_count>1</comment_count>
    <who name="Alexander Makeenkov">amakeenk</who>
    <bug_when>2024-02-07 16:17:48 +0300</bug_when>
    <thetext>Актуально для версий:
gem-puppet-8.3.1-alt1
puppetserver-6.20.0-alt1
ruby-3.1.4-alt2.1</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>243064</commentid>
    <comment_count>2</comment_count>
    <who name="Repository Robot">repository-robot</who>
    <bug_when>2024-03-15 15:50:18 +0300</bug_when>
    <thetext>puppetserver-8.4.0-alt1 -&gt; sisyphus:

 Fri Mar 15 2024 Pavel Skrylev &lt;majioa@altlinux&gt; 8.4.0-alt1
 - ^ 6.20.0 -&gt; 8.4.0 by cas@ (ALT #38464).
 - Added requires java-17-openjdk by cas@ (ALT #41623).
 - Set current version in executables by cas@ (ALT #47704).
 - Used bundled jruby by cas@ (ALT #47705).
 - * put proper config</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>