luban 0.9.4 → 0.9.5

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
  SHA1:
3
- metadata.gz: 4e240a43c20677833fa1d61393fc56cae749cbda
4
- data.tar.gz: 067f7af5c4dc165ead41759fb5f19d58785c5afb
3
+ metadata.gz: 555b9db7bfefbf548122ebead92affe65ed5269a
4
+ data.tar.gz: bd4b6318133e7950e21e6c52d17fab5ebe0f1b56
5
5
  SHA512:
6
- metadata.gz: 6ba915e9a22d46ba2ea4a66809766f923040cc029b548bd38ec2bdbaa6ad38da7f3d187c6a55d6010c893d809dc6f8a4ed1e803d88b53373818db8cadf16352b
7
- data.tar.gz: 3d497bd458bbef3e85ef7c08d61cf6788d5a8c0dd4a230ee20fd2315f4056eb820151ff225b805446039d6cf2e4d04f82ca1ce04e2d2c0d56dad9f38d6ac460d
6
+ metadata.gz: af4f00a1aa72e2e61550a0104274e33f3af3a7be6e5dbd19b861422a9022dac1a5a2107af235f19b98894d72c80bbba9fc85b05f3c893d068107e041ad750e6a
7
+ data.tar.gz: 7d5c2fc63d7b3652588df65fab8261be9ae05266c0691067d1e03d4a199cb20f1b475552d8d8edc6aeb3cef12570b5703dc77370b414778fa0c9f80f2aaf1baa
data/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Change log
2
2
 
3
+ ## Version 0.9.5 (Oct 18, 2016)
4
+
5
+ New features:
6
+ * Added package support for Curl
7
+
8
+ Minor enhancements:
9
+ * Upgraded the dependency on OpenSSL in Git to version 1.0.2j
10
+ * Refactored symlink creation for archived logs
11
+ * Updated package dependency of rubygems-update in Ruby to version 2.6.7 instead of latest to avoid unnecessary network query
12
+
3
13
  ## Version 0.9.4 (Oct 17, 2016)
4
14
 
5
15
  New feature:
@@ -119,7 +119,6 @@ module Luban
119
119
 
120
120
  def create_profile_symlinks
121
121
  create_release_symlink(shared_path)
122
- create_symlinks_for_archived_logs
123
122
  end
124
123
 
125
124
  def create_app_symlinks
@@ -142,10 +141,6 @@ module Luban
142
141
  create_linked_files(linked_files, from: profile_path, to: release_path.join('config'))
143
142
  end
144
143
 
145
- def create_symlinks_for_archived_logs
146
- assure_symlink(archived_logs_path, log_path.join(archived_logs_path.basename))
147
- end
148
-
149
144
  def update_releases_log
150
145
  execute %{echo "[$(date -u)][#{user}] #{release_log_message}" >> #{releases_log_path}}
151
146
  end
@@ -42,15 +42,6 @@ module Luban
42
42
  def bundle_command(cmd, **opts)
43
43
  shell_command("#{bundle_executable} exec #{cmd}", **opts)
44
44
  end
45
-
46
- def app_archives_path
47
- @app_archives_path ||=
48
- archives_path.join("#{stage}.#{project}", application, hostname)
49
- end
50
-
51
- def archived_logs_path
52
- @archived_logs_path ||= app_archives_path.join('archived_logs')
53
- end
54
45
  end
55
46
  end
56
47
  end
@@ -16,6 +16,7 @@ module Luban
16
16
  super
17
17
  create_symlinks_for_linked_dirs
18
18
  create_symlinks_for_linked_files
19
+ create_symlinks_for_archived_logs
19
20
  end
20
21
 
21
22
  def create_symlinks_for_linked_dirs
@@ -36,6 +36,10 @@ module Luban
36
36
  assure_symlink(source_path, target_path)
37
37
  end
38
38
  end
39
+
40
+ def create_symlinks_for_archived_logs
41
+ assure_symlink(archived_logs_path, log_path.join(archived_logs_path.basename))
42
+ end
39
43
  end
40
44
  end
41
45
  end
@@ -0,0 +1,39 @@
1
+ module Luban
2
+ module Deployment
3
+ module Packages
4
+ class Curl < Luban::Deployment::Package::Base
5
+ apply_to :all do
6
+ before_install do
7
+ depend_on 'openssl', version: '1.0.2j'
8
+ end
9
+ end
10
+
11
+ class Installer < Luban::Deployment::Package::Installer
12
+ define_executable 'curl'
13
+
14
+ def source_repo
15
+ @source_repo ||= "https://curl.haxx.se"
16
+ end
17
+
18
+ def source_url_root
19
+ @source_url_root ||= "download"
20
+ end
21
+
22
+ def installed?
23
+ return false unless file?(curl_executable)
24
+ pattern = "curl #{package_version}"
25
+ match?("#{curl_executable} -V 2>&1", pattern)
26
+ end
27
+
28
+ def with_openssl_dir(dir)
29
+ if osx?
30
+ @configure_opts << "--with-darwinssl"
31
+ else
32
+ @configure_opts << "--with-ssl=#{dir}"
33
+ end
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
39
+ end
@@ -4,7 +4,7 @@ module Luban
4
4
  class Git < Luban::Deployment::Package::Base
5
5
  apply_to :all do
6
6
  before_install do
7
- depend_on 'openssl', version: '1.0.2h'
7
+ depend_on 'openssl', version: '1.0.2j'
8
8
  end
9
9
  end
10
10
 
@@ -50,7 +50,7 @@ module Luban
50
50
  #depend_on 'yaml', version: '0.1.6'
51
51
  end
52
52
  after_install do
53
- depend_on 'rubygems-update', version: 'latest'
53
+ depend_on 'rubygems-update', version: '2.6.7'
54
54
  end
55
55
  end
56
56
 
@@ -1,5 +1,5 @@
1
1
  module Luban
2
2
  module Deployment
3
- VERSION = "0.9.4"
3
+ VERSION = "0.9.5"
4
4
  end
5
5
  end
@@ -79,6 +79,15 @@ module Luban
79
79
  luban_install_path.join('pkg', package_name.to_s, 'versions',
80
80
  packages[package_name.to_sym].current_version, 'bin')
81
81
  end
82
+
83
+ def app_archives_path
84
+ @app_archives_path ||=
85
+ archives_path.join("#{stage}.#{project}", application, hostname)
86
+ end
87
+
88
+ def archived_logs_path
89
+ @archived_logs_path ||= app_archives_path.join('archived_logs')
90
+ end
82
91
  end
83
92
  end
84
93
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: luban
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.4
4
+ version: 0.9.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rubyist Lei
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-10-17 00:00:00.000000000 Z
11
+ date: 2016-10-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: luban-cli
@@ -142,6 +142,7 @@ files:
142
142
  - lib/luban/deployment/helpers/linked_paths.rb
143
143
  - lib/luban/deployment/helpers/utils.rb
144
144
  - lib/luban/deployment/packages/bundler.rb
145
+ - lib/luban/deployment/packages/curl.rb
145
146
  - lib/luban/deployment/packages/gem.rb
146
147
  - lib/luban/deployment/packages/git.rb
147
148
  - lib/luban/deployment/packages/logrotate.rb