cono_storage 0.0.4 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +5 -3
- data/lib/cono_storage/client.rb +3 -4
- data/lib/cono_storage/version.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9e5c77e883fc9197384ec63973f82988309c3c5b
|
4
|
+
data.tar.gz: 3bcdb135df6ae0054f5b2f9420445ec3d0ebe239
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 708debac5c0a76a889a759ea94fd9ac9b29be9de9958092ed85d3b3d4340eec476bd58636092c41d6e96aaea812eb8e8cdd859ddb825c480c7113c0663646b2d
|
7
|
+
data.tar.gz: 21fcf235aec863247085d409676cf89dcca6fd8c07aad35edaa72bd3d58ff67b4f5a58f19ed40fdab431c6b75783716e23bf1520916dea1eab1aaf836f5212ee
|
data/README.md
CHANGED
@@ -10,6 +10,8 @@ OpenStack Swift Client for ConoHa オブジェクトストレージ
|
|
10
10
|
require 'cono_storage'
|
11
11
|
|
12
12
|
client = ConoStorage.new(
|
13
|
+
# via. https://identity.tyo1.conoha.io/
|
14
|
+
auth_url: 'https://identity.tyo1.conoha.io/v2.0/',
|
13
15
|
tenant_id: 'b7daff9xxxxxxxxxxxxxxxxx',
|
14
16
|
username: 1111111,
|
15
17
|
password: '^passw0rd$',
|
@@ -18,8 +20,8 @@ client = ConoStorage.new(
|
|
18
20
|
)
|
19
21
|
|
20
22
|
client.put_container('awsome_gifs')# => ConoStorage::Response
|
21
|
-
client.put_object('awsome_gifs','nyan.gif').url #=> "https://objectstore-...cnode.jp/.../awsome_gifs/nyan.gif"
|
22
|
-
client.put_object('awsome_gifs', 'wan.gif',
|
23
|
+
client.put_object('awsome_gifs', 'nyan.gif', '/local/path/to/nyan.gif').url #=> "https://objectstore-...cnode.jp/.../awsome_gifs/nyan.gif"
|
24
|
+
client.put_object('awsome_gifs', 'wan.gif', '/local/path/to/wan.gif', headers: { 'X-Delete-At' => "1170774000" } ) # Custom Headers
|
23
25
|
client.get_object('awsome_gifs', 'nyan.gif')
|
24
26
|
client.delete_object('awsome_gifs', 'nyan.gif')
|
25
27
|
client.delete_container('awsome_gifs').status #=> 204
|
@@ -27,7 +29,7 @@ client.delete_container('awsome_gifs').status #=> 204
|
|
27
29
|
|
28
30
|
## Documentation
|
29
31
|
|
30
|
-
- [オブジェクトストレージ APIリファレンス - ConoHa](https://www.conoha.jp/
|
32
|
+
- [オブジェクトストレージ APIリファレンス - ConoHa](https://www.conoha.jp/docs/)
|
31
33
|
|
32
34
|
## Requirements
|
33
35
|
|
data/lib/cono_storage/client.rb
CHANGED
@@ -12,15 +12,14 @@ module ConoStorage
|
|
12
12
|
"Content-Type" => "application/json"
|
13
13
|
}
|
14
14
|
|
15
|
-
# @param auth_url [String] default: https://ident-r1nd1001.cnode.jp/v2.0
|
16
15
|
# @param web_mode [Boolean] true でコンテナやオブジェクトを作成/更新すると公開状態になります。
|
16
|
+
# @param auth_url [String]
|
17
17
|
# @param tenant_id [String]
|
18
18
|
# @param username [String]
|
19
19
|
# @param password [String]
|
20
20
|
# @param endpoint [String]
|
21
|
-
def initialize(
|
22
|
-
|
23
|
-
tenant_id: , username: , password: , endpoint: )
|
21
|
+
def initialize(web_mode: false,
|
22
|
+
auth_url: , tenant_id: , username: , password: , endpoint: )
|
24
23
|
@auth_url = auth_url
|
25
24
|
@web_mode = web_mode
|
26
25
|
@tenant_id = tenant_id
|
data/lib/cono_storage/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cono_storage
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- kkosuge
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-03-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -132,9 +132,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
132
132
|
version: '0'
|
133
133
|
requirements: []
|
134
134
|
rubyforge_project:
|
135
|
-
rubygems_version: 2.
|
135
|
+
rubygems_version: 2.6.13
|
136
136
|
signing_key:
|
137
137
|
specification_version: 4
|
138
138
|
summary: OpenStack Swift Client for ConoHa オブジェクトストレージ
|
139
139
|
test_files: []
|
140
|
-
has_rdoc:
|