shipit-engine 0.44.0 → 0.44.2
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 021ceb8e303c18a51452d849fb476af3da93cbd837af411d4a94e0836f893848
|
|
4
|
+
data.tar.gz: f3c157eab35e563dcc58f32d4de0c0ad5c0d9c48411c676ef42c8ab30e9dcdd3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 147c22c3269f4334f52ac357ff5eeebf70599fb01e853d88075de2bce8abb52970704efa1960798c8be533e04c62d776a0303cc95d8354a6f383934c49764e2d
|
|
7
|
+
data.tar.gz: cff060b1f000c0700d518018e36b0f4ed02ed204417a749c8d176a0d5baa8b4cef669ec71f5d075de55b67787c218d30a44117d5770da41392abe518d25f9c6f
|
|
@@ -58,7 +58,11 @@ module Shipit
|
|
|
58
58
|
|
|
59
59
|
def perform_task
|
|
60
60
|
capture_all!(@commands.install_dependencies)
|
|
61
|
-
|
|
61
|
+
if ENV['SHIPIT_DRY_RUN'].present?
|
|
62
|
+
@task.write("\nSkipping deploy steps (dry run mode)\n")
|
|
63
|
+
else
|
|
64
|
+
capture_all!(@commands.perform)
|
|
65
|
+
end
|
|
62
66
|
end
|
|
63
67
|
|
|
64
68
|
def checkout_repository
|
|
@@ -70,7 +70,11 @@
|
|
|
70
70
|
<p class="banner__text">
|
|
71
71
|
Continuous Delivery for this stack is currently paused because
|
|
72
72
|
|
|
73
|
-
|
|
73
|
+
<% if stack.next_commit_to_deploy %>
|
|
74
|
+
<%= link_to_if stack.deployment_checks_passed?, 'the pre-deploy checks failed', stack_commit_checks_path(stack, sha: stack.next_commit_to_deploy.sha) %>.
|
|
75
|
+
<% else %>
|
|
76
|
+
the pre-deploy checks failed.
|
|
77
|
+
<% end %>
|
|
74
78
|
You can either wait for them to pass, or trigger a deploy manually.
|
|
75
79
|
</p>
|
|
76
80
|
</div>
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
host: 'shipit-engine.myshopify.io'
|
|
2
|
-
redis_url: 'redis://shipit-engine.railgun:6379'
|
|
3
2
|
|
|
4
3
|
# For creating an app see: https://github.com/Shopify/shipit-engine/blob/main/docs/setup.md#creating-the-github-app
|
|
5
4
|
|
|
@@ -21,4 +20,4 @@ github:
|
|
|
21
20
|
oauth:
|
|
22
21
|
id:
|
|
23
22
|
secret:
|
|
24
|
-
teams:
|
|
23
|
+
teams:
|
data/lib/shipit/version.rb
CHANGED
|
@@ -44,4 +44,41 @@ module Shipit
|
|
|
44
44
|
Shipit::PerformTaskJob.new.perform(task)
|
|
45
45
|
end
|
|
46
46
|
end
|
|
47
|
+
|
|
48
|
+
class DefaultTaskExecutionStrategyDryRunTest < ActiveSupport::TestCase
|
|
49
|
+
setup do
|
|
50
|
+
@task = mock('task')
|
|
51
|
+
@commands = mock('commands')
|
|
52
|
+
@install_deps = [mock('install_dep_cmd')]
|
|
53
|
+
@perform_cmds = [mock('perform_cmd')]
|
|
54
|
+
@commands.stubs(:install_dependencies).returns(@install_deps)
|
|
55
|
+
@commands.stubs(:perform).returns(@perform_cmds)
|
|
56
|
+
Shipit::Commands.stubs(:for).with(@task).returns(@commands)
|
|
57
|
+
|
|
58
|
+
@strategy = Shipit::TaskExecutionStrategy::Default.new(@task)
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
teardown do
|
|
62
|
+
ENV.delete('SHIPIT_DRY_RUN')
|
|
63
|
+
end
|
|
64
|
+
|
|
65
|
+
test "perform_task runs both install_dependencies and perform when SHIPIT_DRY_RUN is not set" do
|
|
66
|
+
@strategy.instance_variable_set(:@commands, @commands)
|
|
67
|
+
@strategy.expects(:capture_all!).with(@install_deps).once
|
|
68
|
+
@strategy.expects(:capture_all!).with(@perform_cmds).once
|
|
69
|
+
|
|
70
|
+
@strategy.perform_task
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
test "perform_task skips perform when SHIPIT_DRY_RUN is set" do
|
|
74
|
+
ENV['SHIPIT_DRY_RUN'] = '1'
|
|
75
|
+
|
|
76
|
+
@strategy.instance_variable_set(:@commands, @commands)
|
|
77
|
+
@strategy.expects(:capture_all!).with(@install_deps).once
|
|
78
|
+
@strategy.expects(:capture_all!).with(@perform_cmds).never
|
|
79
|
+
@task.expects(:write).with("\nSkipping deploy steps (dry run mode)\n")
|
|
80
|
+
|
|
81
|
+
@strategy.perform_task
|
|
82
|
+
end
|
|
83
|
+
end
|
|
47
84
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: shipit-engine
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.44.
|
|
4
|
+
version: 0.44.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jean Boussier
|
|
@@ -1051,7 +1051,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
1051
1051
|
- !ruby/object:Gem::Version
|
|
1052
1052
|
version: '0'
|
|
1053
1053
|
requirements: []
|
|
1054
|
-
rubygems_version: 4.0.
|
|
1054
|
+
rubygems_version: 4.0.6
|
|
1055
1055
|
specification_version: 4
|
|
1056
1056
|
summary: Application deployment software
|
|
1057
1057
|
test_files:
|