Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package
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
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Nicolas Wavrant
slapos.package
Commits
292bf85d
Commit
292bf85d
authored
Feb 24, 2014
by
Rafael Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update local file after perform the upgrade only.
parent
1dd26cbc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
11 deletions
+11
-11
slapos/package/update.py
slapos/package/update.py
+11
-11
No files found.
slapos/package/update.py
View file @
292bf85d
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
# -*- coding: utf-8 -*-
##############################################################################
##############################################################################
#
#
# Copyright (c) 2012
-2014
Vifib SARL and Contributors.
# Copyright (c) 2012 Vifib SARL and Contributors.
# All Rights Reserved.
# All Rights Reserved.
#
#
# WARNING: This program as such is intended to be used by professional
# WARNING: This program as such is intended to be used by professional
...
@@ -95,16 +95,6 @@ class Upgrader:
...
@@ -95,16 +95,6 @@ class Upgrader:
def
fixConsistency
(
self
,
signature
,
upgrade
=
0
,
reboot
=
0
,
boot
=
0
,
**
kw
):
def
fixConsistency
(
self
,
signature
,
upgrade
=
0
,
reboot
=
0
,
boot
=
0
,
**
kw
):
today
=
datetime
.
date
.
today
().
isoformat
()
today
=
datetime
.
date
.
today
().
isoformat
()
if
upgrade
and
boot
:
signature
.
update
(
reboot
=
today
,
upgrade
=
today
)
if
upgrade
:
signature
.
update
(
upgrade
=
today
)
elif
reboot
:
signature
.
update
(
reboot
=
today
)
else
:
raise
ValueError
(
"You need upgrade and/or reboot when invoke fixConsistency!"
)
if
upgrade
:
if
upgrade
:
pkgmanager
=
BasePromise
()
pkgmanager
=
BasePromise
()
configuration_dict
=
signature
.
get_signature_dict
()
configuration_dict
=
signature
.
get_signature_dict
()
...
@@ -122,6 +112,16 @@ class Upgrader:
...
@@ -122,6 +112,16 @@ class Upgrader:
pkgmanager
.
update
(
repository_tuple_list
,
upgrade_goal
[
'filter-package-list'
])
pkgmanager
.
update
(
repository_tuple_list
,
upgrade_goal
[
'filter-package-list'
])
if
upgrade
and
boot
:
signature
.
update
(
reboot
=
today
,
upgrade
=
today
)
if
upgrade
:
signature
.
update
(
upgrade
=
today
)
elif
reboot
:
signature
.
update
(
reboot
=
today
)
else
:
raise
ValueError
(
"You need upgrade and/or reboot when invoke fixConsistency!"
)
def
checkConsistency
(
self
,
fixit
=
0
,
**
kw
):
def
checkConsistency
(
self
,
fixit
=
0
,
**
kw
):
# Get configuration
# Get configuration
...
...
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