Sha256: 2e120279e551b0602969b2b229fa14d35e48195c06a956680ecf7c93cc13c29b

Contents?: true

Size: 514 Bytes

Versions: 31

Compression:

Stored size: 514 Bytes

Contents

# encoding: utf-8

module <%=config[:constant_name]%>
  class Server

    def initialize
      $log.info("<%=config[:name]%>:boot #{RUBY_DESCRIPTION}")
      $log.info("<%=config[:name]%>:boot", {
        env: Env.mode,
      })

      Signal.register_shutdown_handler { shutdown }
    end

    def shutdown
      $log.info("<%=config[:name]%>:server", shutdown: :complete)
      exit(0)
    rescue => e
      $log.exception(e, "shutdown failed")
      exit(-1)
    end

    def run
      sleep
    end

  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
liquid-ext-3.5.3 lib/liquid/templates/server.rb.tt
liquid-ext-3.5.2 lib/liquid/templates/server.rb.tt
liquid-ext-3.5.0 lib/liquid/templates/server.rb.tt
liquid-ext-3.4.2 lib/liquid/templates/server.rb.tt
liquid-ext-3.4.1 lib/liquid/templates/server.rb.tt
liquid-ext-3.4.0 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.10 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.9 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.8 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.7 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.6 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.5 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.4 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.3 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.2 lib/liquid/templates/server.rb.tt
liquid-ext-3.3.0 lib/liquid/templates/server.rb.tt
liquid-ext-3.2.0 lib/liquid/templates/server.rb.tt
liquid-ext-3.1.2 lib/liquid/templates/server.rb.tt
liquid-ext-3.1.1 lib/liquid/templates/server.rb.tt
liquid-ext-3.1.0 lib/liquid/templates/server.rb.tt