Class: OracleBMC::Config
- Inherits:
-
Object
- Object
- OracleBMC::Config
- Defined in:
- lib/oraclebmc/config.rb
Instance Attribute Summary collapse
-
#additional_user_agent ⇒ String
If set, then this string will be added to the user agent sent with each request.
-
#connection_timeout ⇒ Integer
The time limit for the connection phase in seconds.
-
#fingerprint ⇒ String
SSL Fingerprint to use for authentication.
-
#key_file ⇒ String
Client private key file.
-
#log_requests ⇒ true, false
Whether to log detailed request and response data.
-
#logger ⇒ Logger
Defines the logger used for debugging.
-
#pass_phrase ⇒ String
Pass phrase used for key file, if it is encrypted.
-
#region ⇒ OracleBMC::Regions::REGION_ENUM
A region to use for APIs created with this Config.
-
#tenancy ⇒ String
OCID of the tenancy to use for authentication.
-
#timeout ⇒ Integer
The time limit for HTTP request in seconds.
-
#user ⇒ String
OCID of the user to use for authentication.
Instance Method Summary collapse
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
74 75 76 77 78 |
# File 'lib/oraclebmc/config.rb', line 74 def initialize @timeout = 0 @connection_timeout = 10 @log_requests = false end |
Instance Attribute Details
#additional_user_agent ⇒ String
If set, then this string will be added to the user agent sent with each request.
72 73 74 |
# File 'lib/oraclebmc/config.rb', line 72 def additional_user_agent @additional_user_agent end |
#connection_timeout ⇒ Integer
The time limit for the connection phase in seconds. Defaults to 10 seconds.
66 67 68 |
# File 'lib/oraclebmc/config.rb', line 66 def connection_timeout @connection_timeout end |
#fingerprint ⇒ String
SSL Fingerprint to use for authentication. Example: 20:3b:97:13:55:1c:1c:0d:d3:37:d8:50:4e:c5:3a:12
18 19 20 |
# File 'lib/oraclebmc/config.rb', line 18 def fingerprint @fingerprint end |
#key_file ⇒ String
Client private key file. Example: ~/.ssh/bmc_key
30 31 32 |
# File 'lib/oraclebmc/config.rb', line 30 def key_file @key_file end |
#log_requests ⇒ true, false
Whether to log detailed request and response data. This will always write to STDOUT. Defaults to false.
54 55 56 |
# File 'lib/oraclebmc/config.rb', line 54 def log_requests @log_requests end |
#logger ⇒ Logger
Defines the logger used for debugging. For example, log to STDOUT by setting this to Logger.new(STDOUT). This property cannot be set from a config file.
47 48 49 |
# File 'lib/oraclebmc/config.rb', line 47 def logger @logger end |
#pass_phrase ⇒ String
Pass phrase used for key file, if it is encrypted.
35 36 37 |
# File 'lib/oraclebmc/config.rb', line 35 def pass_phrase @pass_phrase end |
#region ⇒ OracleBMC::Regions::REGION_ENUM
A region to use for APIs created with this Config.
40 41 42 |
# File 'lib/oraclebmc/config.rb', line 40 def region @region end |
#tenancy ⇒ String
OCID of the tenancy to use for authentication. Example: ocid1.tenancy.oc1..aaaaaaaaba3pv6wkcr4jqae5f15p2b2m2yt2j6rx32uzr4h25vqstifsfdsq
24 25 26 |
# File 'lib/oraclebmc/config.rb', line 24 def tenancy @tenancy end |
#timeout ⇒ Integer
The time limit for HTTP request in seconds. Defaults to 0 (never times out).
60 61 62 |
# File 'lib/oraclebmc/config.rb', line 60 def timeout @timeout end |
#user ⇒ String
OCID of the user to use for authentication. Example: ocidv1:user:oc1:phx:1460406592659:aaaaaaaawcbqrkycbolrirg2n3xjl5fabc
12 13 14 |
# File 'lib/oraclebmc/config.rb', line 12 def user @user end |