smartcloud 0.5.3 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0f8b33a78533be526973b7a6cd9b0908065ff243bd81f9f187e7b47ef3206b3f
|
4
|
+
data.tar.gz: b0c32955987e7dd6871b4d3ba19079ba89b900b69f6cb267554737447e4e32f0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 194c49f31b2732a5f80d29965608346b30411abfeceb51ae1a35c2cc732c81f49d8efbfc13182456af2f197246b856216c19a9d321a26d3074efbd4d615c9e26
|
7
|
+
data.tar.gz: c351811641f14509b224801c4b9d1f38eb62c4772bce7c386f662925494d2822d644dae5ece3efbfc38ce7139decf1c01cb00b80e0bd664ba6f1d052985a17ee
|
File without changes
|
@@ -0,0 +1,58 @@
|
|
1
|
+
# The main Smartcloud Grids Redis driver
|
2
|
+
module Smartcloud
|
3
|
+
module Grids
|
4
|
+
class Redis < Smartcloud::Base
|
5
|
+
def initialize
|
6
|
+
end
|
7
|
+
|
8
|
+
def self.up
|
9
|
+
if Smartcloud::Docker.running?
|
10
|
+
# Creating networks
|
11
|
+
unless system("docker network inspect redis-network", [:out, :err] => File::NULL)
|
12
|
+
print "-----> Creating network redis-network ... "
|
13
|
+
if system("docker network create redis-network", out: File::NULL)
|
14
|
+
puts "done"
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
# Creating & Starting containers
|
19
|
+
print "-----> Creating container redis ... "
|
20
|
+
if system("docker create \
|
21
|
+
--name='redis' \
|
22
|
+
--user `id -u`:`id -g` \
|
23
|
+
--volume='#{Smartcloud.config.user_home_path}/.smartcloud/grids/grid-redis/data:/data' \
|
24
|
+
--restart='always' \
|
25
|
+
--network='redis-network' \
|
26
|
+
redis:6.0-rc3-alpine3.11 redis-server --appendonly yes", out: File::NULL)
|
27
|
+
|
28
|
+
puts "done"
|
29
|
+
print "-----> Starting container redis ... "
|
30
|
+
if system("docker start redis", out: File::NULL)
|
31
|
+
puts "done"
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
def self.down
|
38
|
+
if Smartcloud::Docker.running?
|
39
|
+
# Stopping & Removing containers - in reverse order
|
40
|
+
print "-----> Stopping container redis ... "
|
41
|
+
if system("docker stop 'redis'", out: File::NULL)
|
42
|
+
puts "done"
|
43
|
+
print "-----> Removing container redis ... "
|
44
|
+
if system("docker rm 'redis'", out: File::NULL)
|
45
|
+
puts "done"
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
# Removing networks
|
50
|
+
print "-----> Removing network redis-network ... "
|
51
|
+
if system("docker network rm redis-network", out: File::NULL)
|
52
|
+
puts "done"
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
58
|
+
end
|
data/lib/smartcloud/machine.rb
CHANGED
@@ -254,6 +254,10 @@ module Smartcloud
|
|
254
254
|
'grids/grid-prereceiver',
|
255
255
|
'grids/grid-prereceiver/pre-receive',
|
256
256
|
|
257
|
+
'grids/grid-redis',
|
258
|
+
'grids/grid-redis/data',
|
259
|
+
'grids/grid-redis/data/.keep',
|
260
|
+
|
257
261
|
'grids/grid-redmine',
|
258
262
|
'grids/grid-redmine/files',
|
259
263
|
'grids/grid-redmine/files/.keep',
|
File without changes
|
data/lib/smartcloud/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: smartcloud
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Timeboard
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-04-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: net-ssh
|
@@ -100,6 +100,7 @@ files:
|
|
100
100
|
- lib/smartcloud/grids/grid-prereceiver/fcgiwrap/packages/main/x86_64/fcgiwrap-1.1.1-r4.apk
|
101
101
|
- lib/smartcloud/grids/grid-prereceiver/fcgiwrap/packages/main/x86_64/fcgiwrap-doc-1.1.1-r4.apk
|
102
102
|
- lib/smartcloud/grids/grid-prereceiver/fcgiwrap/packages/main/x86_64/fcgiwrap-openrc-1.1.1-r4.apk
|
103
|
+
- lib/smartcloud/grids/grid-redis/.keep
|
103
104
|
- lib/smartcloud/grids/grid-redmine/.keep
|
104
105
|
- lib/smartcloud/grids/grid-solr/config/.keep
|
105
106
|
- lib/smartcloud/grids/grid-solr/config/README.txt
|
@@ -269,6 +270,7 @@ files:
|
|
269
270
|
- lib/smartcloud/grids/nextcloud.rb
|
270
271
|
- lib/smartcloud/grids/nginx.rb
|
271
272
|
- lib/smartcloud/grids/prereceiver.rb
|
273
|
+
- lib/smartcloud/grids/redis.rb
|
272
274
|
- lib/smartcloud/grids/redmine.rb
|
273
275
|
- lib/smartcloud/grids/solr.rb
|
274
276
|
- lib/smartcloud/logger.rb
|
@@ -291,6 +293,7 @@ files:
|
|
291
293
|
- lib/smartcloud/templates/dotsmartcloud/grids/grid-nginx/htpasswd/.keep
|
292
294
|
- lib/smartcloud/templates/dotsmartcloud/grids/grid-nginx/nginx.tmpl
|
293
295
|
- lib/smartcloud/templates/dotsmartcloud/grids/grid-prereceiver/pre-receive
|
296
|
+
- lib/smartcloud/templates/dotsmartcloud/grids/grid-redis/data/.keep
|
294
297
|
- lib/smartcloud/templates/dotsmartcloud/grids/grid-redmine/files/.keep
|
295
298
|
- lib/smartcloud/templates/dotsmartcloud/grids/grid-solr/solr/.keep
|
296
299
|
- lib/smartcloud/templates/dotsmartcloud/tmp/.keep
|