deployhq 2.1.2 → 2.2.0
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
- data/lib/deploy/cli/websocket_client.rb +1 -1
- data/lib/deploy/cli.rb +15 -4
- data/lib/deploy/resources/project.rb +6 -1
- metadata +3 -6
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 49b0d4dee17978ab6c1930da674f450c2a39f510e7ea16c7e780071ce4d01645
|
|
4
|
+
data.tar.gz: 605d88bb4aab28b84f66b9924dfcce27321b1c483498fd932600f29058e77de6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2475fd2e69653132c6d19b41de8f1c3a842dca009822965ec7e2d5b81c9a57200d3aeab53cf7746a98d3c19a111f127d7749d5611e80ae5dcdb309253f073f10
|
|
7
|
+
data.tar.gz: d4239817c17165c41324afe6e895745e6062a55fdb6f9800850fab675636ef59038b94d5872eccc6d74f0d9bb3c611ffc394bac67c75affeadf2155dc89e23ef
|
data/lib/deploy/cli.rb
CHANGED
|
@@ -7,7 +7,7 @@ require 'deploy'
|
|
|
7
7
|
require 'deploy/cli/websocket_client'
|
|
8
8
|
require 'deploy/cli/deployment_progress_output'
|
|
9
9
|
|
|
10
|
-
OptionsStruct = Struct.new(:config_file, :project)
|
|
10
|
+
OptionsStruct = Struct.new(:config_file, :project, :config_files_deployment)
|
|
11
11
|
|
|
12
12
|
# rubocop:disable Metrics/ClassLength
|
|
13
13
|
# rubocop:disable Metrics/AbcSize
|
|
@@ -25,7 +25,7 @@ module Deploy
|
|
|
25
25
|
def invoke(args)
|
|
26
26
|
@options = OptionsStruct.new
|
|
27
27
|
|
|
28
|
-
parser = OptionParser.new do |opts|
|
|
28
|
+
parser = OptionParser.new do |opts| # rubocop:disable Metrics/BlockLength
|
|
29
29
|
opts.banner = 'Usage: deployhq [options] command'
|
|
30
30
|
opts.separator ''
|
|
31
31
|
opts.separator 'Commands:'
|
|
@@ -45,6 +45,11 @@ module Deploy
|
|
|
45
45
|
@options.project = project_permalink
|
|
46
46
|
end
|
|
47
47
|
|
|
48
|
+
@options.config_files_deployment = false
|
|
49
|
+
opts.on('--config-files', 'Config files deployment') do |_config_files_deployment|
|
|
50
|
+
@options.config_files_deployment = true
|
|
51
|
+
end
|
|
52
|
+
|
|
48
53
|
opts.on_tail('-v', '--version', 'Shows Version') do
|
|
49
54
|
puts Deploy::VERSION
|
|
50
55
|
exit
|
|
@@ -127,8 +132,14 @@ module Deploy
|
|
|
127
132
|
end
|
|
128
133
|
end
|
|
129
134
|
|
|
130
|
-
|
|
131
|
-
|
|
135
|
+
if @options.config_files_deployment
|
|
136
|
+
$stdout.print "\nStarting config files deployment\n"
|
|
137
|
+
deployment = @project.config_files_deployment(parent.identifier)
|
|
138
|
+
else
|
|
139
|
+
$stdout.print "\nStarting deployment\n"
|
|
140
|
+
latest_revision = @project.latest_revision(parent.preferred_branch)
|
|
141
|
+
deployment = @project.deploy(parent.identifier, parent.last_revision, latest_revision)
|
|
142
|
+
end
|
|
132
143
|
|
|
133
144
|
$stdout.print 'Waiting for an available deployment slot...'
|
|
134
145
|
DeploymentProgressOutput.new(deployment).monitor
|
|
@@ -21,12 +21,17 @@ module Deploy
|
|
|
21
21
|
end
|
|
22
22
|
|
|
23
23
|
# Create a deployment in this project (and queue it to run)
|
|
24
|
-
def deploy(server, start_revision, end_revision)
|
|
24
|
+
def deploy(server, start_revision, end_revision, config_files_only: false)
|
|
25
25
|
run_deployment(server, start_revision, end_revision) do |d|
|
|
26
26
|
d.mode = 'queue'
|
|
27
|
+
d.config_files_deployment = '1' if config_files_only
|
|
27
28
|
end
|
|
28
29
|
end
|
|
29
30
|
|
|
31
|
+
def config_files_deployment(server)
|
|
32
|
+
deploy(server, nil, nil, config_files_only: true)
|
|
33
|
+
end
|
|
34
|
+
|
|
30
35
|
# Create a deployment preview
|
|
31
36
|
def preview(server, start_revision, end_revision)
|
|
32
37
|
run_deployment(server, start_revision, end_revision) do |d|
|
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: deployhq
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.2.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Adam Cooke
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: bin
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 2025-01-08 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: highline
|
|
@@ -81,7 +80,6 @@ homepage: https://github.com/krystal/deployhq-lib
|
|
|
81
80
|
licenses:
|
|
82
81
|
- MIT
|
|
83
82
|
metadata: {}
|
|
84
|
-
post_install_message:
|
|
85
83
|
rdoc_options: []
|
|
86
84
|
require_paths:
|
|
87
85
|
- lib
|
|
@@ -96,8 +94,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
96
94
|
- !ruby/object:Gem::Version
|
|
97
95
|
version: '0'
|
|
98
96
|
requirements: []
|
|
99
|
-
rubygems_version: 3.
|
|
100
|
-
signing_key:
|
|
97
|
+
rubygems_version: 3.6.2
|
|
101
98
|
specification_version: 4
|
|
102
99
|
summary: API and CLI client for the DeployHQ
|
|
103
100
|
test_files: []
|