Skip to content

Commit

Permalink
Fix storage config (#1854)
Browse files Browse the repository at this point in the history
## Problem

There is collision between
#1848 and
#1840 where bootloader adds
another interface with Get/SetConfig on Storage service. This result
that generic access no longer works and needs access via specific
interface.

reported on slack
https://suse.slack.com/archives/C02TLF25571/p1734924853266999

## Solution

Change code to avoid ambitious code.


## Testing

- *Tested manually*
  • Loading branch information
dgdavid authored Dec 23, 2024
2 parents cf131a8 + 5824069 commit c3d85bb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 4 additions & 2 deletions service/lib/agama/dbus/clients/storage.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ def finish
#
# @return [Hash]
def config
serialized_config = dbus_object.GetConfig
# Use storage iface to avoid collision with bootloader iface
serialized_config = dbus_object[STORAGE_IFACE].GetConfig
JSON.parse(serialized_config, symbolize_names: true)
end

Expand All @@ -76,7 +77,8 @@ def config
# @param config [Hash]
def config=(config)
serialized_config = JSON.pretty_generate(config)
dbus_object.SetConfig(serialized_config)
# Use storage iface to avoid collision with bootloader iface
dbus_object[STORAGE_IFACE].SetConfig(serialized_config)
end

private
Expand Down
6 changes: 6 additions & 0 deletions service/package/rubygem-agama-yast.changes
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
-------------------------------------------------------------------
Mon Dec 23 18:40:01 UTC 2024 - Josef Reidinger <[email protected]>

- Fix collision between hotfix and new bootlaoder dbus interface
(gh#agama-project/agama#1852)

-------------------------------------------------------------------
Fri Dec 20 15:05:11 UTC 2024 - José Iván López González <[email protected]>

Expand Down

0 comments on commit c3d85bb

Please sign in to comment.