Sha256: ab81c0f58bf68a17838ebc545fecbb4478a48c350e55073b131b5e034975c676

Contents?: true

Size: 797 Bytes

Versions: 32

Compression:

Stored size: 797 Bytes

Contents

# frozen_string_literal: true

require 'avm/instances/process'
require 'eac_ruby_utils/core_ext'

module Avm
  module EacWebappBase0
    module Instances
      module Processes
        class WebServer < ::Avm::Instances::Process
          def available?
            instance.apache_resource.present?
          end

          def enable
            apache_resource_change(__method__)
          end

          def enabled?
            instance.apache_resource.enabled?
          end

          def disable
            apache_resource_change(__method__)
          end

          private

          def apache_resource_change(action)
            instance.apache_resource.send(action)
            instance.platform_instance.apache.service(:reload)
          end
        end
      end
    end
  end
end

Version data entries

32 entries across 32 versions & 2 rubygems

Version Path
eac_tools-0.76.1 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.76.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.75.2 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.75.1 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.75.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
avm-eac_webapp_base0-0.18.2 lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.74.1 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.74.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.73.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.72.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb
avm-eac_webapp_base0-0.18.1 lib/avm/eac_webapp_base0/instances/processes/web_server.rb
eac_tools-0.70.1 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/processes/web_server.rb