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
40d8fdb8
Commit
40d8fdb8
authored
Nov 20, 2020
by
Tiger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move Terraform state versioning default to database
parent
0072a1e3
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
16 additions
and
2 deletions
+16
-2
app/models/terraform/state.rb
app/models/terraform/state.rb
+0
-1
changelogs/unreleased/update-terraform-versioning-default.yml
...gelogs/unreleased/update-terraform-versioning-default.yml
+5
-0
db/migrate/20201119213406_change_terraform_versioning_enabled_default.rb
...1119213406_change_terraform_versioning_enabled_default.rb
+9
-0
db/schema_migrations/20201119213406
db/schema_migrations/20201119213406
+1
-0
db/structure.sql
db/structure.sql
+1
-1
No files found.
app/models/terraform/state.rb
View file @
40d8fdb8
...
...
@@ -35,7 +35,6 @@ module Terraform
format:
{
with:
HEX_REGEXP
,
message:
'only allows hex characters'
}
default_value_for
(
:uuid
,
allows_nil:
false
)
{
SecureRandom
.
hex
(
UUID_LENGTH
/
2
)
}
default_value_for
(
:versioning_enabled
,
true
)
mount_file_store_uploader
StateUploader
...
...
changelogs/unreleased/update-terraform-versioning-default.yml
0 → 100644
View file @
40d8fdb8
---
title
:
Move Terraform state versioning default to database
merge_request
:
48194
author
:
type
:
other
db/migrate/20201119213406_change_terraform_versioning_enabled_default.rb
0 → 100644
View file @
40d8fdb8
# frozen_string_literal: true
class
ChangeTerraformVersioningEnabledDefault
<
ActiveRecord
::
Migration
[
6.0
]
DOWNTIME
=
false
def
change
change_column_default
:terraform_states
,
:versioning_enabled
,
from:
false
,
to:
true
end
end
db/schema_migrations/20201119213406
0 → 100644
View file @
40d8fdb8
33970a1295b84040c82034041c99f13578352844c9c6cb092b5cc35913576a7e
\ No newline at end of file
db/structure.sql
View file @
40d8fdb8
...
...
@@ -16644,7 +16644,7 @@ CREATE TABLE terraform_states (
locked_by_user_id
bigint
,
uuid
character
varying
(
32
)
NOT
NULL
,
name
character
varying
(
255
),
versioning_enabled
boolean
DEFAULT
fals
e
NOT
NULL
versioning_enabled
boolean
DEFAULT
tru
e
NOT
NULL
);
CREATE
SEQUENCE
terraform_states_id_seq
...
...
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