Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
966d0fe8
Commit
966d0fe8
authored
Mar 20, 2020
by
zmartins
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add atomic and cleanup-on-fail parameters
To help when dealing with upgrades and failed states in Helm
parent
536d66aa
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
0 deletions
+24
-0
changelogs/unreleased/add_helm_params_rollback_related.yml
changelogs/unreleased/add_helm_params_rollback_related.yml
+5
-0
lib/gitlab/kubernetes/helm/install_command.rb
lib/gitlab/kubernetes/helm/install_command.rb
+5
-0
spec/lib/gitlab/kubernetes/helm/install_command_spec.rb
spec/lib/gitlab/kubernetes/helm/install_command_spec.rb
+14
-0
No files found.
changelogs/unreleased/add_helm_params_rollback_related.yml
0 → 100644
View file @
966d0fe8
---
title
:
Add atomic and cleanup-on-fail parameters for Helm
merge_request
:
27721
author
:
type
:
changed
lib/gitlab/kubernetes/helm/install_command.rb
View file @
966d0fe8
...
...
@@ -44,6 +44,7 @@ module Gitlab
def
install_command
command
=
[
'helm'
,
'upgrade'
,
name
,
chart
]
+
install_flag
+
rollback_support_flag
+
reset_values_flag
+
tls_flags_if_remote_tiller
+
optional_version_flag
+
...
...
@@ -83,6 +84,10 @@ module Gitlab
[
'--version'
,
version
]
end
def
rollback_support_flag
[
'--atomic'
,
'--cleanup-on-fail'
]
end
end
end
end
...
...
spec/lib/gitlab/kubernetes/helm/install_command_spec.rb
View file @
966d0fe8
...
...
@@ -41,6 +41,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--version 1.2.3
--set rbac.create
\\
=false,rbac.enabled
\\
=false
...
...
@@ -79,6 +81,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
#{
tls_flags
}
--version 1.2.3
...
...
@@ -109,6 +113,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--version 1.2.3
--set rbac.create
\\
=true,rbac.enabled
\\
=true
...
...
@@ -140,6 +146,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--version 1.2.3
--set rbac.create
\\
=false,rbac.enabled
\\
=false
...
...
@@ -171,6 +179,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--version 1.2.3
--set rbac.create
\\
=false,rbac.enabled
\\
=false
...
...
@@ -200,6 +210,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--version 1.2.3
--set rbac.create
\\
=false,rbac.enabled
\\
=false
...
...
@@ -229,6 +241,8 @@ describe Gitlab::Kubernetes::Helm::InstallCommand do
<<~
EOS
.
squish
helm upgrade app-name chart-name
--install
--atomic
--cleanup-on-fail
--reset-values
--set rbac.create
\\
=false,rbac.enabled
\\
=false
--namespace gitlab-managed-apps
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment