Sha256: ab71c650bd9a99ec88187f21c6d14610b237f8b807df3d04192cd8772b38f1d1

Contents?: true

Size: 1.12 KB

Versions: 7

Compression:

Stored size: 1.12 KB

Contents

# frozen_string_literal: true

require 'avm/entries/jobs/base'
require 'avm/eac_ubuntu_base0/apache'
require 'avm/eac_webapp_base0/instances/apache_base'
require 'eac_ruby_utils/core_ext'

module Avm
  module EacWebappBase0
    module Instances
      class ApachePath < ::Avm::EacWebappBase0::Instances::ApacheBase
        JOBS = %w[write_available_conf enable_conf reload_apache].freeze
        include ::Avm::Entries::Jobs::Base

        def content
          ::Avm::EacWebappBase0::Instances::ApachePath.template.child('default.conf')
                                                      .apply(variables_source)
        end

        def document_root
          instance.read_entry(::Avm::Instances::EntryKeys::INSTALL_PATH)
        end

        def extra_content
          ''
        end

        private

        def enable_conf
          infom 'Enabling configuration...'
          conf.enable
        end

        def conf_uncached
          apache.conf(instance.id)
        end

        def write_available_conf
          infom 'Writing available configuration...'
          conf.write(content)
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
eac_tools-0.74.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/apache_path.rb
eac_tools-0.73.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/apache_path.rb
eac_tools-0.72.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/apache_path.rb
avm-eac_webapp_base0-0.18.1 lib/avm/eac_webapp_base0/instances/apache_path.rb
eac_tools-0.70.1 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/apache_path.rb
avm-eac_webapp_base0-0.18.0 lib/avm/eac_webapp_base0/instances/apache_path.rb
eac_tools-0.70.0 sub/avm-eac_webapp_base0/lib/avm/eac_webapp_base0/instances/apache_path.rb