Class: Inspec::Resources::Apache
- Inherits:
- 
      Object
      
        - Object
- Inspec::Resources::Apache
 
- Defined in:
- lib/inspec/resources/apache.rb
Instance Attribute Summary collapse
- 
  
    
      #conf_dir  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    Returns the value of attribute conf_dir. 
- 
  
    
      #conf_path  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    Returns the value of attribute conf_path. 
- 
  
    
      #service  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    Returns the value of attribute service. 
- 
  
    
      #user  ⇒ Object 
    
    
  
  
  
  
    
      readonly
    
    
  
  
  
  
  
  
    Returns the value of attribute user. 
Instance Method Summary collapse
- 
  
    
      #initialize  ⇒ Apache 
    
    
  
  
  
    constructor
  
  
  
  
  
  
  
    A new instance of Apache. 
- #to_s ⇒ Object
Constructor Details
#initialize ⇒ Apache
Returns a new instance of Apache.
| 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | # File 'lib/inspec/resources/apache.rb', line 27 def initialize Inspec.deprecate(:resource_apache, "The apache resource is deprecated") if inspec.os.debian? @service = "apache2" @conf_dir = "/etc/apache2/" @conf_path = File.join @conf_dir, "apache2.conf" @user = "www-data" else @service = "httpd" @conf_dir = "/etc/httpd/" @conf_path = File.join @conf_dir, "/conf/httpd.conf" @user = "apache" end end | 
Instance Attribute Details
#conf_dir ⇒ Object (readonly)
Returns the value of attribute conf_dir.
| 26 27 28 | # File 'lib/inspec/resources/apache.rb', line 26 def conf_dir @conf_dir end | 
#conf_path ⇒ Object (readonly)
Returns the value of attribute conf_path.
| 26 27 28 | # File 'lib/inspec/resources/apache.rb', line 26 def conf_path @conf_path end | 
#service ⇒ Object (readonly)
Returns the value of attribute service.
| 26 27 28 | # File 'lib/inspec/resources/apache.rb', line 26 def service @service end | 
#user ⇒ Object (readonly)
Returns the value of attribute user.
| 26 27 28 | # File 'lib/inspec/resources/apache.rb', line 26 def user @user end | 
Instance Method Details
#to_s ⇒ Object
| 43 44 45 | # File 'lib/inspec/resources/apache.rb', line 43 def to_s "Apache Environment" end |