Browse Source

Allow live user to control audio and scan wi-fi

master
crims0n 4 years ago
parent
commit
6397d4c5cb
  1. 4
      linux-live/buildconfig
  2. 2
      linux-live/config
  3. 1
      linux-live/minioslib
  4. 172
      linux-live/modules/03-xfce-desktop/install
  5. 6
      linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.NetworkManager.pkla
  6. 8
      linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.consolekit.pkla
  7. 2
      linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.upower.pkla

4
linux-live/buildconfig

@ -4,7 +4,7 @@
DISTRIBUTION_TYPE="debian"
#
DISTRIBUTION="buster"
DISTRIBUTION="bullseye"
#
DISTRIBUTION_ARCH="amd64"
@ -16,7 +16,7 @@ DISTRIBUTION_VARIANT="minbase"
DISTRIBUTION_URL="http://ftp.ru.debian.org/debian/"
#
PACKAGE_VARIANT="minimal"
PACKAGE_VARIANT="standard"
#
LOGPATH="/var/log"

2
linux-live/config

@ -15,7 +15,7 @@
LIVEKITNAME="minios"
#
COMP_TYPE="lz4"
COMP_TYPE="xz"
# Kernel file, will be copied to your Live Kit
# Your kernel must support aufs and squashfs. Debian Jessie's kernel is ready

1
linux-live/minioslib

@ -1047,6 +1047,7 @@ function chroot_configure() {
echo live:evil | chpasswd >>$OUTPUT 2>&1
addgroup live adm >>$OUTPUT 2>&1
addgroup live sudo >>$OUTPUT 2>&1
addgroup live audio >>$OUTPUT 2>&1
(cd /linux-live/basesystem/01-core/rootcopy && cp --parents -afr * /)

172
linux-live/modules/03-xfce-desktop/install

@ -47,7 +47,7 @@ if grep xfce4-whiskermenu-plugin $SCRIPT_DIR/$PACKAGE_VARIANT.list >>$OUTPUT 2>&
echo "favorites=xfce4-terminal-emulator.desktop,xfce4-file-manager.desktop,xfce4-web-browser.desktop,xfce4-mail-reader.desktop" >/root/.config/xfce4/panel/whiskermenu-1.rc
echo "favorites=xfce4-terminal-emulator.desktop,xfce4-file-manager.desktop,xfce4-web-browser.desktop,xfce4-mail-reader.desktop" >/home/live/.config/xfce4/panel/whiskermenu-1.rc
fi
read -r -d WHISKERMENU '' <<EOF
cat <<EOF >>/etc/skel/.config/xfce4/panel/whiskermenu-1.rc
recent=
button-icon=/usr/share/pixmaps/MiniOS-white.svg
button-single-row=false
@ -129,9 +129,173 @@ regex=true
EOF
echo $WHISKERMENU >>/etc/skel/.config/xfce4/panel/whiskermenu-1.rc
echo $WHISKERMENU >>/root/.config/xfce4/panel/whiskermenu-1.rc
echo $WHISKERMENU >>/home/live/.config/xfce4/panel/whiskermenu-1.rc
cat <<EOF >>/root/.config/xfce4/panel/whiskermenu-1.rc
recent=
button-icon=/usr/share/pixmaps/MiniOS-white.svg
button-single-row=false
show-button-title=false
show-button-icon=true
launcher-show-name=true
launcher-show-description=false
launcher-show-tooltip=true
item-icon-size=2
hover-switch-category=false
category-show-name=true
category-icon-size=1
load-hierarchy=false
view-as-icons=false
default-category=0
recent-items-max=10
favorites-in-recent=true
position-search-alternate=true
position-commands-alternate=false
position-categories-alternate=true
stay-on-focus-out=false
confirm-session-command=true
menu-width=450
menu-height=500
menu-opacity=100
command-settings=xfce4-settings-manager
show-command-settings=false
command-lockscreen=xflock4
show-command-lockscreen=false
command-switchuser=dm-tool switch-to-greeter
show-command-switchuser=false
command-logoutuser=xfce4-session-logout --logout --fast
show-command-logoutuser=false
command-restart=xfce4-session-logout --reboot --fast
show-command-restart=false
command-shutdown=xfce4-session-logout --halt --fast
show-command-shutdown=false
command-suspend=xfce4-session-logout --suspend
show-command-suspend=false
command-hibernate=xfce4-session-logout --hibernate
show-command-hibernate=false
command-logout=xfce4-session-logout
show-command-logout=true
command-menueditor=menulibre
show-command-menueditor=true
command-profile=mugshot
show-command-profile=true
search-actions=5
[action0]
name=Man Pages
pattern=#
command=exo-open --launch TerminalEmulator man %s
regex=false
[action1]
name=Web Search
pattern=?
command=exo-open --launch WebBrowser https://duckduckgo.com/?q=%u
regex=false
[action2]
name=Wikipedia
pattern=!w
command=exo-open --launch WebBrowser https://en.wikipedia.org/wiki/%u
regex=false
[action3]
name=Run in Terminal
pattern=!
command=exo-open --launch TerminalEmulator %s
regex=false
[action4]
name=Open URI
pattern=^(file|http|https):\\/\\/(.*)$
command=exo-open \\0
regex=true
EOF
cat <<EOF >>/home/live/.config/xfce4/panel/whiskermenu-1.rc
recent=
button-icon=/usr/share/pixmaps/MiniOS-white.svg
button-single-row=false
show-button-title=false
show-button-icon=true
launcher-show-name=true
launcher-show-description=false
launcher-show-tooltip=true
item-icon-size=2
hover-switch-category=false
category-show-name=true
category-icon-size=1
load-hierarchy=false
view-as-icons=false
default-category=0
recent-items-max=10
favorites-in-recent=true
position-search-alternate=true
position-commands-alternate=false
position-categories-alternate=true
stay-on-focus-out=false
confirm-session-command=true
menu-width=450
menu-height=500
menu-opacity=100
command-settings=xfce4-settings-manager
show-command-settings=false
command-lockscreen=xflock4
show-command-lockscreen=false
command-switchuser=dm-tool switch-to-greeter
show-command-switchuser=false
command-logoutuser=xfce4-session-logout --logout --fast
show-command-logoutuser=false
command-restart=xfce4-session-logout --reboot --fast
show-command-restart=false
command-shutdown=xfce4-session-logout --halt --fast
show-command-shutdown=false
command-suspend=xfce4-session-logout --suspend
show-command-suspend=false
command-hibernate=xfce4-session-logout --hibernate
show-command-hibernate=false
command-logout=xfce4-session-logout
show-command-logout=true
command-menueditor=menulibre
show-command-menueditor=true
command-profile=mugshot
show-command-profile=true
search-actions=5
[action0]
name=Man Pages
pattern=#
command=exo-open --launch TerminalEmulator man %s
regex=false
[action1]
name=Web Search
pattern=?
command=exo-open --launch WebBrowser https://duckduckgo.com/?q=%u
regex=false
[action2]
name=Wikipedia
pattern=!w
command=exo-open --launch WebBrowser https://en.wikipedia.org/wiki/%u
regex=false
[action3]
name=Run in Terminal
pattern=!
command=exo-open --launch TerminalEmulator %s
regex=false
[action4]
name=Open URI
pattern=^(file|http|https):\\/\\/(.*)$
command=exo-open \\0
regex=true
EOF
#echo $WHISKERMENU >>/etc/skel/.config/xfce4/panel/whiskermenu-1.rc
#echo $WHISKERMENU >>/root/.config/xfce4/panel/whiskermenu-1.rc
#echo $WHISKERMENU >>/home/live/.config/xfce4/panel/whiskermenu-1.rc
else
#read -r -d MINIMAL_PANEL '' <<EOF
cat <<EOF >/etc/skel/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-panel.xml

6
linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.NetworkManager.pkla

@ -0,0 +1,6 @@
[Wifi Scan]
Identity=unix-user:adm
Action=org.freedesktop.NetworkManager.wifi.scan
ResultAny=yes
ResultInactive=yes
ResultActive=yes

8
linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.consolekit.pkla

@ -1,26 +1,26 @@
[Local restart]
Identity=unix-group:power
Identity=unix-group:adm
Action=org.freedesktop.consolekit.system.restart
ResultAny=yes
ResultInactive=no
ResultActive=yes
[Local shutdown]
Identity=unix-group:power
Identity=unix-group:adm
Action=org.freedesktop.consolekit.system.stop
ResultAny=yes
ResultInactive=no
ResultActive=yes
[Local restart - multiple]
Identity=unix-group:power
Identity=unix-group:adm
Action=org.freedesktop.consolekit.system.restart-multiple-users
ResultAny=yes
ResultInactive=no
ResultActive=yes
[Local shutdown - multiple]
Identity=unix-group:power
Identity=unix-group:adm
Action=org.freedesktop.consolekit.system.stop-multiple-users
ResultAny=yes
ResultInactive=no

2
linux-live/modules/03-xfce-desktop/rootcopy/etc/polkit-1/localauthority/50-local.d/org.freedesktop.upower.pkla

@ -1,5 +1,5 @@
[Local Users]
Identity=unix-group:power
Identity=unix-group:adm
Action=org.freedesktop.upower.*
ResultAny=yes
ResultInactive=no

Loading…
Cancel
Save