Class: Google::Apis::OsconfigV1::OsPolicyResourceFileResource
- Inherits:
-
Object
- Object
- Google::Apis::OsconfigV1::OsPolicyResourceFileResource
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/osconfig_v1/classes.rb,
lib/google/apis/osconfig_v1/representations.rb,
lib/google/apis/osconfig_v1/representations.rb
Overview
A resource that manages the state of a file.
Instance Attribute Summary collapse
-
#content ⇒ String
A a file with this content.
-
#file ⇒ Google::Apis::OsconfigV1::OsPolicyResourceFile
A remote or local file.
-
#path ⇒ String
Required.
-
#permissions ⇒ String
Consists of three octal digits which represent, in order, the permissions of the owner, group, and other users for the file (similarly to the numeric mode used in the linux chmod utility).
-
#state ⇒ String
Required.
Instance Method Summary collapse
-
#initialize(**args) ⇒ OsPolicyResourceFileResource
constructor
A new instance of OsPolicyResourceFileResource.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ OsPolicyResourceFileResource
Returns a new instance of OsPolicyResourceFileResource.
2140 2141 2142 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2140 def initialize(**args) update!(**args) end |
Instance Attribute Details
#content ⇒ String
A a file with this content. The size of the content is limited to 32KiB.
Corresponds to the JSON property content
2111 2112 2113 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2111 def content @content end |
#file ⇒ Google::Apis::OsconfigV1::OsPolicyResourceFile
A remote or local file.
Corresponds to the JSON property file
2116 2117 2118 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2116 def file @file end |
#path ⇒ String
Required. The absolute path of the file within the VM.
Corresponds to the JSON property path
2121 2122 2123 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2121 def path @path end |
#permissions ⇒ String
Consists of three octal digits which represent, in order, the permissions of
the owner, group, and other users for the file (similarly to the numeric mode
used in the linux chmod utility). Each digit represents a three bit number
with the 4 bit corresponding to the read permissions, the 2 bit corresponds to
the write bit, and the one bit corresponds to the execute permission. Default
behavior is 755. Below are some examples of permissions and their associated
values: read, write, and execute: 7 read and execute: 5 read and write: 6 read
only: 4
Corresponds to the JSON property permissions
2133 2134 2135 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2133 def @permissions end |
#state ⇒ String
Required. Desired state of the file.
Corresponds to the JSON property state
2138 2139 2140 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2138 def state @state end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
2145 2146 2147 2148 2149 2150 2151 |
# File 'lib/google/apis/osconfig_v1/classes.rb', line 2145 def update!(**args) @content = args[:content] if args.key?(:content) @file = args[:file] if args.key?(:file) @path = args[:path] if args.key?(:path) @permissions = args[:permissions] if args.key?(:permissions) @state = args[:state] if args.key?(:state) end |