traquitana 0.1.7 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/config/default.yml +16 -9
- data/config/proc.sh +23 -2
- data/gem-public_cert.pem +22 -22
- data/lib/config.rb +1 -1
- data/lib/deployer.rb +3 -3
- data/lib/traquitana/version.rb +1 -1
- data/spec/config_spec.rb +4 -4
- data/spec/network_spec.rb +5 -5
- data.tar.gz.sig +0 -0
- metadata +25 -25
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8b30d41d162c3a01a8223a97b09e0b5015fa88265517d95305416548000e6d63
|
4
|
+
data.tar.gz: 9cd60f1814e6dcdadcf2d339c725629066de58db7326b43225c1ead0390c86e4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fcda62780cc49a616d33661687aaa74d0fe87369d5b79665e5f9f8e4225850813e2e1c77148569a04cb87506e779a1aa1a8d7a8deb15f3648e2735bf0ac38c50
|
7
|
+
data.tar.gz: b6886ab40ea74fe2a9af4528e8348b3d5c30743265c905bf53481813c1ace1da9999e68fbfe5ff7763033bfecafa644f31c8da4668609fe8fad338bab79a8f0a
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/config/default.yml
CHANGED
@@ -1,9 +1,8 @@
|
|
1
1
|
# Default configuration---
|
2
|
-
|
3
|
-
|
4
|
-
:
|
5
|
-
:
|
6
|
-
:list:
|
2
|
+
version: 0.1.8
|
3
|
+
directory: /tmp/traq_test
|
4
|
+
user: taq
|
5
|
+
list:
|
7
6
|
- Rakefile
|
8
7
|
- config.ru
|
9
8
|
- Gemfile
|
@@ -16,10 +15,16 @@
|
|
16
15
|
- - config/environments/production.rb
|
17
16
|
- - config/locales/**/*
|
18
17
|
- - config/routes.rb
|
18
|
+
- - config/boot.rb
|
19
|
+
- - config/database.yml
|
20
|
+
- - config/secrets.yml
|
19
21
|
- - config/storage.yml
|
22
|
+
- - config/cable.yml
|
23
|
+
- - config/importmap.rb
|
20
24
|
- - config/webpacker.yml
|
21
25
|
- - config/webpack/environment.js
|
22
26
|
- - config/webpack/production.js
|
27
|
+
- - config/traq/extra.sh
|
23
28
|
- - app/**/*
|
24
29
|
- - db/migrate/**/*
|
25
30
|
- - public/javascripts/**/*
|
@@ -29,10 +34,12 @@
|
|
29
34
|
- - public/500.html
|
30
35
|
- - public/favicon.ico
|
31
36
|
- - public/robots.txt
|
37
|
+
- - public/manifest.json
|
32
38
|
- - lib/**/*
|
39
|
+
- - bin/**/*
|
33
40
|
- - public/images/**/*
|
34
41
|
- public/images/uploads/**/*
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
42
|
+
password: fill your password here
|
43
|
+
host: localhost
|
44
|
+
server: passenger
|
45
|
+
shell: bash -l -c
|
data/config/proc.sh
CHANGED
@@ -163,6 +163,17 @@ function permissions() {
|
|
163
163
|
fi
|
164
164
|
}
|
165
165
|
|
166
|
+
#
|
167
|
+
# Check if vendor javascript dir exists, if not, created it.
|
168
|
+
# When compiling Rails 7.x assets, it will fail if not found
|
169
|
+
#
|
170
|
+
function vendor_javascript() {
|
171
|
+
msg "Checking vendor javascript diretory ..."
|
172
|
+
if [ ! -d 'vendor/javascript' ]; then
|
173
|
+
mkdir vendor/javascript
|
174
|
+
fi
|
175
|
+
}
|
176
|
+
|
166
177
|
#
|
167
178
|
# Fix current gems, running bundle
|
168
179
|
#
|
@@ -186,8 +197,17 @@ function fix_gems() {
|
|
186
197
|
bundle install --without development test
|
187
198
|
# if user is not root and gemdir is not the home dir, install on vendor
|
188
199
|
else
|
189
|
-
|
190
|
-
|
200
|
+
local version=$(bundle -v | grep -o -e "[0-9]\.[0-9]\.[0-9]" | cut -d'.' -f1)
|
201
|
+
msg "Performing a \e[1mlocal gem install on vendor/bundle with bundler version $version\e[0m"
|
202
|
+
|
203
|
+
# bundler version 2 doesnt have anymore those flags below
|
204
|
+
if [ $version -ge 2 ]; then
|
205
|
+
bundle config --local set path 'vendor/bundle'
|
206
|
+
bundle config --local set without 'development test'
|
207
|
+
bundle install
|
208
|
+
else
|
209
|
+
bundle install --path vendor/bundle --without development test
|
210
|
+
fi
|
191
211
|
fi
|
192
212
|
fi
|
193
213
|
}
|
@@ -304,6 +324,7 @@ fix_gems
|
|
304
324
|
createdb
|
305
325
|
channels
|
306
326
|
migrate
|
327
|
+
vendor_javascript
|
307
328
|
assets
|
308
329
|
permissions
|
309
330
|
|
data/gem-public_cert.pem
CHANGED
@@ -1,26 +1,26 @@
|
|
1
1
|
-----BEGIN CERTIFICATE-----
|
2
2
|
MIIEVjCCAr6gAwIBAgIBATANBgkqhkiG9w0BAQsFADAqMSgwJgYDVQQDDB9ldXN0
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
3
|
+
YXF1aW9yYW5nZWwvREM9Z21haWwvREM9Y29tMB4XDTIyMDMyNDExMzcyM1oXDTIz
|
4
|
+
MDMyNDExMzcyM1owKjEoMCYGA1UEAwwfZXVzdGFxdWlvcmFuZ2VsL0RDPWdtYWls
|
5
|
+
L0RDPWNvbTCCAaIwDQYJKoZIhvcNAQEBBQADggGPADCCAYoCggGBANAGhKJUcqaZ
|
6
|
+
Hj39UyB+C5LFhLnxTbBFITdek6KogjlxeFTdomdIkZ4eezhRHTSZhIhDLt3lXooI
|
7
|
+
t7oEXPHcgVA5G1piZo7M7DSaxaL5uFlOePFGp2zcsyVUCcswHVy2DvbvpAy0U3Ne
|
8
|
+
rnR1xrR+TW6A3ZnxZnONGNX5uIx5yaGs0yQw6awtHrInxv7gHDz4bCHouCL5z2Zy
|
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JqtSQvC10HEj
|
23
|
+
774vxPz0bwbBL31fheYMpnPgjOYn9U39Y+xxqOSMmRLnI1RDZH1e//crTp4rXZ+X
|
24
|
+
Fl+IMrhXtSOX0D0wb3xvk1Eg7xgH4mo78Se2OmuccewHjyjL4NAwU0lZmkb0d7yX
|
25
|
+
MoFYhSMI+0s3Wg==
|
26
26
|
-----END CERTIFICATE-----
|
data/lib/config.rb
CHANGED
data/lib/deployer.rb
CHANGED
@@ -11,7 +11,7 @@ module Traquitana
|
|
11
11
|
STDOUT.puts "\e[1mRunning Traquitana version #{VERSION}\e[0m\n\n"
|
12
12
|
|
13
13
|
unless File.exist?(@config.filename)
|
14
|
-
warn "\e[31mNo config file (#{@config.filename}) found."
|
14
|
+
warn "\e[31mNo config file (#{@config.filename}) found."
|
15
15
|
warn "Did you run \e[1mtraq setup\e[0;31m ?"
|
16
16
|
warn "Run it and check the configuration before deploying.\e[0m"
|
17
17
|
exit 1
|
@@ -28,12 +28,12 @@ module Traquitana
|
|
28
28
|
@packager.verbose = @verbose
|
29
29
|
all_list_file, all_list_zip = @packager.pack
|
30
30
|
|
31
|
-
if !File.
|
31
|
+
if !File.exist?(all_list_file) || !File.exist?(all_list_zip)
|
32
32
|
warn "\e[31mCould not create the needed files.\e[0m"
|
33
33
|
exit 2
|
34
34
|
end
|
35
35
|
|
36
|
-
# check if the traq destination and config directories exists
|
36
|
+
# check if the traq destination and config directories exists
|
37
37
|
@network.execute(["mkdir -p #{@config.directory}/traq"],@verbose)
|
38
38
|
@updater = Traquitana::Bar.new
|
39
39
|
|
data/lib/traquitana/version.rb
CHANGED
data/spec/config_spec.rb
CHANGED
@@ -65,7 +65,7 @@ describe Traquitana::Config do
|
|
65
65
|
expect(@config).must_respond_to :setup
|
66
66
|
end
|
67
67
|
|
68
|
-
it 'should do nothing if the configuration file
|
68
|
+
it 'should do nothing if the configuration file exist' do
|
69
69
|
expect(@config.setup).must_equal false
|
70
70
|
end
|
71
71
|
|
@@ -73,11 +73,11 @@ describe Traquitana::Config do
|
|
73
73
|
contents = File.read(@config.filename)
|
74
74
|
File.unlink(@config.filename)
|
75
75
|
|
76
|
-
expect(File.
|
76
|
+
expect(File.exist?(@config.filename)).must_equal false
|
77
77
|
expect(@config.setup).must_equal true
|
78
|
-
expect(File.
|
78
|
+
expect(File.exist?(@config.filename)).must_equal true
|
79
79
|
|
80
|
-
File.open(@config.filename, 'w') do |file|
|
80
|
+
File.open(@config.filename, 'w') do |file|
|
81
81
|
file << contents
|
82
82
|
end
|
83
83
|
end
|
data/spec/network_spec.rb
CHANGED
@@ -9,7 +9,7 @@ describe Traquitana::SSH do
|
|
9
9
|
@send = "#{File.expand_path(File.dirname(__FILE__))}/config/network_test.txt"
|
10
10
|
@md5 = Digest::MD5.hexdigest(File.read(@send))
|
11
11
|
|
12
|
-
Dir.mkdir(@config.directory) if !File.
|
12
|
+
Dir.mkdir(@config.directory) if !File.exist?(@config.directory)
|
13
13
|
end
|
14
14
|
|
15
15
|
describe 'configs' do
|
@@ -33,11 +33,11 @@ describe Traquitana::SSH do
|
|
33
33
|
|
34
34
|
it 'should send a file to the remote host' do
|
35
35
|
check = "#{@config.directory}/#{File.basename(@send)}"
|
36
|
-
File.unlink(check) if File.
|
36
|
+
File.unlink(check) if File.exist?(check)
|
37
37
|
|
38
38
|
@network.send_files([[@send, "#{@config.directory}/#{File.basename(@send)}"]], Traquitana::Bar.new)
|
39
39
|
|
40
|
-
expect(File.
|
40
|
+
expect(File.exist?(check)).must_equal true
|
41
41
|
expect(Digest::MD5.hexdigest(File.read(check))).must_equal @md5
|
42
42
|
end
|
43
43
|
|
@@ -47,10 +47,10 @@ describe Traquitana::SSH do
|
|
47
47
|
|
48
48
|
it 'should execute a command on the remote host' do
|
49
49
|
remote_dir = "#{@config.directory}/remote_dir"
|
50
|
-
FileUtils.rmdir(remote_dir) if File.
|
50
|
+
FileUtils.rmdir(remote_dir) if File.exist?(remote_dir)
|
51
51
|
|
52
52
|
@network.execute(["mkdir #{@config.directory}/remote_dir"])
|
53
|
-
expect(File.
|
53
|
+
expect(File.exist?(remote_dir)).must_equal true
|
54
54
|
end
|
55
55
|
end
|
56
56
|
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: traquitana
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eustaquio Rangel
|
@@ -11,31 +11,31 @@ cert_chain:
|
|
11
11
|
- |
|
12
12
|
-----BEGIN CERTIFICATE-----
|
13
13
|
MIIEVjCCAr6gAwIBAgIBATANBgkqhkiG9w0BAQsFADAqMSgwJgYDVQQDDB9ldXN0
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
14
|
+
YXF1aW9yYW5nZWwvREM9Z21haWwvREM9Y29tMB4XDTIyMDMyNDExMzcyM1oXDTIz
|
15
|
+
MDMyNDExMzcyM1owKjEoMCYGA1UEAwwfZXVzdGFxdWlvcmFuZ2VsL0RDPWdtYWls
|
16
|
+
L0RDPWNvbTCCAaIwDQYJKoZIhvcNAQEBBQADggGPADCCAYoCggGBANAGhKJUcqaZ
|
17
|
+
Hj39UyB+C5LFhLnxTbBFITdek6KogjlxeFTdomdIkZ4eezhRHTSZhIhDLt3lXooI
|
18
|
+
t7oEXPHcgVA5G1piZo7M7DSaxaL5uFlOePFGp2zcsyVUCcswHVy2DvbvpAy0U3Ne
|
19
|
+
rnR1xrR+TW6A3ZnxZnONGNX5uIx5yaGs0yQw6awtHrInxv7gHDz4bCHouCL5z2Zy
|
20
|
+
ataxl3pfTBVdzvd9ecIAmD/nfrejhkGv1HBY8m70H3sHOgHN7J2nve6KBWmKyEmm
|
21
|
+
kG0dZYt7C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|
+
Fl+IMrhXtSOX0D0wb3xvk1Eg7xgH4mo78Se2OmuccewHjyjL4NAwU0lZmkb0d7yX
|
36
|
+
MoFYhSMI+0s3Wg==
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date:
|
38
|
+
date: 2022-03-24 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: highline
|
@@ -190,7 +190,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
190
190
|
- !ruby/object:Gem::Version
|
191
191
|
version: '0'
|
192
192
|
requirements: []
|
193
|
-
rubygems_version: 3.
|
193
|
+
rubygems_version: 3.0.3
|
194
194
|
signing_key:
|
195
195
|
specification_version: 4
|
196
196
|
summary: Just a simple tool to deploy Rails apps with SSH and some shell scripts
|
metadata.gz.sig
CHANGED
Binary file
|