BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
0abce36c
Unverified
Commit
0abce36c
authored
Feb 04, 2018
by
Matija Čupić
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update list of allowed attribute updates in Runner
parent
053b9d21
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
3 deletions
+11
-3
runner.rb
app/models/ci/runner.rb
+11
-3
No files found.
app/models/ci/runner.rb
View file @
0abce36c
...
...
@@ -68,8 +68,8 @@ module Ci
ONLINE_CONTACT_TIMEOUT
.
ago
end
def
contacted_at
cached_attribute
(
:
contacted_at
)
||
read_attribute
(
:contacted_at
)
def
name
cached_attribute
(
:
name
)
||
read_attribute
(
:name
)
end
def
version
...
...
@@ -80,10 +80,18 @@ module Ci
cached_attribute
(
:revision
)
||
read_attribute
(
:revision
)
end
def
platform
cached_attribute
(
:platform
)
||
read_attribute
(
:platform
)
end
def
architecture
cached_attribute
(
:architecture
)
||
read_attribute
(
:architecture
)
end
def
contacted_at
cached_attribute
(
:contacted_at
)
||
read_attribute
(
:contacted_at
)
end
def
set_default_values
self
.
token
=
SecureRandom
.
hex
(
15
)
if
self
.
token
.
blank?
end
...
...
@@ -170,7 +178,7 @@ module Ci
end
def
update_cached_info
(
values
)
values
=
values
.
slice
(
:version
,
:revision
,
:platform
,
:architecture
)
values
=
values
&
.
slice
(
:name
,
:version
,
:revision
,
:platform
,
:architecture
)
||
{}
values
[
:contacted_at
]
=
Time
.
now
cache_attributes
(
values
)
...
...
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