Class: Artifactory::Resource::Backup
- Defined in:
- lib/artifactory/resources/backup.rb
Class Method Summary collapse
-
.all(options = {}) ⇒ Array<Resource::Backup>
Get a list of all backup jobs in the system.
-
.find(key, options = {}) ⇒ Resource::Backup?
Find (fetch) a backup job by its key.
Instance Method Summary collapse
-
#create_archive ⇒ Object
Return this object’s
create_archive
. -
#create_archive=(value) ⇒ Object
Set this object’s
create_archive
. -
#create_archive? ⇒ Boolean
Determines if the
create_archive
value exists and is truthy. -
#cron_exp ⇒ Object
Return this object’s
cron_exp
. -
#cron_exp=(value) ⇒ Object
Set this object’s
cron_exp
. -
#cron_exp? ⇒ Boolean
Determines if the
cron_exp
value exists and is truthy. -
#dir ⇒ Object
Return this object’s
dir
. -
#dir=(value) ⇒ Object
Set this object’s
dir
. -
#dir? ⇒ Boolean
Determines if the
dir
value exists and is truthy. -
#enabled ⇒ Object
Return this object’s
enabled
. -
#enabled=(value) ⇒ Object
Set this object’s
enabled
. -
#enabled? ⇒ Boolean
Determines if the
enabled
value exists and is truthy. -
#exclude_builds ⇒ Object
Return this object’s
exclude_builds
. -
#exclude_builds=(value) ⇒ Object
Set this object’s
exclude_builds
. -
#exclude_builds? ⇒ Boolean
Determines if the
exclude_builds
value exists and is truthy. -
#excluded_repositories ⇒ Object
Return this object’s
excluded_repositories
. -
#excluded_repositories=(value) ⇒ Object
Set this object’s
excluded_repositories
. -
#excluded_repositories? ⇒ Boolean
Determines if the
excluded_repositories
value exists and is truthy. -
#key ⇒ Object
Return this object’s
key
. -
#key=(value) ⇒ Object
Set this object’s
key
. -
#key? ⇒ Boolean
Determines if the
key
value exists and is truthy. -
#retention_period_hours ⇒ Object
Return this object’s
retention_period_hours
. -
#retention_period_hours=(value) ⇒ Object
Set this object’s
retention_period_hours
. -
#retention_period_hours? ⇒ Boolean
Determines if the
retention_period_hours
value exists and is truthy. -
#send_mail_on_error ⇒ Object
Return this object’s
send_mail_on_error
. -
#send_mail_on_error=(value) ⇒ Object
Set this object’s
send_mail_on_error
. -
#send_mail_on_error? ⇒ Boolean
Determines if the
send_mail_on_error
value exists and is truthy.
Methods inherited from Base
attribute, attributes, #attributes, #client, #client=, #client?, #extract_client!, extract_client!, format_repos!, #format_repos!, from_hash, from_url, has_attribute?, #initialize, #inspect, #set, #to_hash, #to_json, #to_matrix_properties, #to_query_string_parameters, #to_s, url_safe, #url_safe
Constructor Details
This class inherits a constructor from Artifactory::Resource::Base
Class Method Details
.all(options = {}) ⇒ Array<Resource::Backup>
Get a list of all backup jobs in the system.
34 35 36 37 |
# File 'lib/artifactory/resources/backup.rb', line 34 def all( = {}) config = Resource::System.configuration() list_from_config('config/backups/backup', config, ) end |
.find(key, options = {}) ⇒ Resource::Backup?
Find (fetch) a backup job by its key.
57 58 59 60 61 62 63 |
# File 'lib/artifactory/resources/backup.rb', line 57 def find(key, = {}) config = Resource::System.configuration() find_from_config("config/backups/backup/key[text()='#{key}']", config, ) rescue Error::HTTPError => e raise unless e.code == 404 nil end |
Instance Method Details
#create_archive ⇒ Object
Return this object’s create_archive
115 |
# File 'lib/artifactory/resources/backup.rb', line 115 attribute :create_archive |
#create_archive=(value) ⇒ Object
Set this object’s create_archive
115 |
# File 'lib/artifactory/resources/backup.rb', line 115 attribute :create_archive |
#create_archive? ⇒ Boolean
Determines if the create_archive
value exists and is truthy
115 |
# File 'lib/artifactory/resources/backup.rb', line 115 attribute :create_archive |
#cron_exp ⇒ Object
Return this object’s cron_exp
113 |
# File 'lib/artifactory/resources/backup.rb', line 113 attribute :cron_exp |
#cron_exp=(value) ⇒ Object
Set this object’s cron_exp
113 |
# File 'lib/artifactory/resources/backup.rb', line 113 attribute :cron_exp |
#cron_exp? ⇒ Boolean
Determines if the cron_exp
value exists and is truthy
113 |
# File 'lib/artifactory/resources/backup.rb', line 113 attribute :cron_exp |
#dir ⇒ Object
Return this object’s dir
112 |
# File 'lib/artifactory/resources/backup.rb', line 112 attribute :dir |
#dir=(value) ⇒ Object
Set this object’s dir
112 |
# File 'lib/artifactory/resources/backup.rb', line 112 attribute :dir |
#dir? ⇒ Boolean
Determines if the dir
value exists and is truthy
112 |
# File 'lib/artifactory/resources/backup.rb', line 112 attribute :dir |
#enabled ⇒ Object
Return this object’s enabled
111 |
# File 'lib/artifactory/resources/backup.rb', line 111 attribute :enabled, true |
#enabled=(value) ⇒ Object
Set this object’s enabled
111 |
# File 'lib/artifactory/resources/backup.rb', line 111 attribute :enabled, true |
#enabled? ⇒ Boolean
Determines if the enabled
value exists and is truthy
111 |
# File 'lib/artifactory/resources/backup.rb', line 111 attribute :enabled, true |
#exclude_builds ⇒ Object
Return this object’s exclude_builds
118 |
# File 'lib/artifactory/resources/backup.rb', line 118 attribute :exclude_builds |
#exclude_builds=(value) ⇒ Object
Set this object’s exclude_builds
118 |
# File 'lib/artifactory/resources/backup.rb', line 118 attribute :exclude_builds |
#exclude_builds? ⇒ Boolean
Determines if the exclude_builds
value exists and is truthy
118 |
# File 'lib/artifactory/resources/backup.rb', line 118 attribute :exclude_builds |
#excluded_repositories ⇒ Object
Return this object’s excluded_repositories
116 |
# File 'lib/artifactory/resources/backup.rb', line 116 attribute :excluded_repositories |
#excluded_repositories=(value) ⇒ Object
Set this object’s excluded_repositories
116 |
# File 'lib/artifactory/resources/backup.rb', line 116 attribute :excluded_repositories |
#excluded_repositories? ⇒ Boolean
Determines if the excluded_repositories
value exists and is truthy
116 |
# File 'lib/artifactory/resources/backup.rb', line 116 attribute :excluded_repositories |
#key ⇒ Object
Return this object’s key
110 |
# File 'lib/artifactory/resources/backup.rb', line 110 attribute :key, ->{ raise 'name missing!' } |
#key=(value) ⇒ Object
Set this object’s key
110 |
# File 'lib/artifactory/resources/backup.rb', line 110 attribute :key, ->{ raise 'name missing!' } |
#key? ⇒ Boolean
Determines if the key
value exists and is truthy
110 |
# File 'lib/artifactory/resources/backup.rb', line 110 attribute :key, ->{ raise 'name missing!' } |
#retention_period_hours ⇒ Object
Return this object’s retention_period_hours
114 |
# File 'lib/artifactory/resources/backup.rb', line 114 attribute :retention_period_hours |
#retention_period_hours=(value) ⇒ Object
Set this object’s retention_period_hours
114 |
# File 'lib/artifactory/resources/backup.rb', line 114 attribute :retention_period_hours |
#retention_period_hours? ⇒ Boolean
Determines if the retention_period_hours
value exists and is truthy
114 |
# File 'lib/artifactory/resources/backup.rb', line 114 attribute :retention_period_hours |
#send_mail_on_error ⇒ Object
Return this object’s send_mail_on_error
117 |
# File 'lib/artifactory/resources/backup.rb', line 117 attribute :send_mail_on_error |
#send_mail_on_error=(value) ⇒ Object
Set this object’s send_mail_on_error
117 |
# File 'lib/artifactory/resources/backup.rb', line 117 attribute :send_mail_on_error |
#send_mail_on_error? ⇒ Boolean
Determines if the send_mail_on_error
value exists and is truthy
117 |
# File 'lib/artifactory/resources/backup.rb', line 117 attribute :send_mail_on_error |