File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11use std:: ffi:: CString ;
2- use std:: fs:: { read_dir, File } ;
2+ use std:: fs:: { exists , read_dir, File } ;
33use std:: io:: Write ;
44use std:: os:: fd:: AsFd ;
55use std:: path:: Path ;
@@ -136,6 +136,22 @@ pub fn mount_filesystems() -> Result<()> {
136136
137137 place_etc ( "resolv.conf" , None ) ?;
138138
139+ // Due to a FAR integration bug, GNOME installs may not have /etc/hostname. Somehow the system
140+ // mostly works like that? But Steam install depends on this file. If there's no hostname set
141+ // in the host, at least make up a hostname for the guest so the Steam install works in the
142+ // guest.
143+ //
144+ // This is a hot fix but doesn't have any real drawbacks as a bit of robustness against broken
145+ // host installs.
146+ //
147+ // FAR bug: https://pagure.io/fedora-asahi/remix-bugs/issue/11
148+ //
149+ // (Although even after that's closed, we won't be able to drop this for a while because
150+ // existing installs may be affected.)
151+ if !exists ( "/etc/hostname" ) ? {
152+ place_etc ( "hostname" , Some ( "placeholder-hostname" ) ) ?;
153+ }
154+
139155 mount2 (
140156 Some ( "binfmt_misc" ) ,
141157 "/proc/sys/fs/binfmt_misc" ,
You can’t perform that action at this time.
0 commit comments