Compare commits
13 Commits
Author | SHA1 | Date | |
---|---|---|---|
be5c4f8c45 | |||
5b6b2b333b | |||
42079b4149 | |||
cddbda97aa | |||
94ea2fe509 | |||
5c0a46baff | |||
c2b343f55e | |||
1b9fb8a8db | |||
9bc59c1106 | |||
180eca1cc6 | |||
3bb69889e6 | |||
a799e8ac78 | |||
5bafd95c27 |
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
generic/
|
||||
|
@@ -1,15 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
mountpoint -q /proc/sys/fs/binfmt_misc || \
|
||||
mount -t binfmt_misc binfmt /proc/sys/fs/binfmt_misc
|
||||
|
||||
for path in /usr/lib/binfmt.d /etc/binfmt.d /run/binfmt.d; do
|
||||
[ ! -d $path ] && continue
|
||||
[ -z "$(ls $path)" ] && continue
|
||||
grep -h "^:" $path/* | \
|
||||
while read -r line; do
|
||||
reg=${line#*:}
|
||||
[ -e /proc/sys/fs/binfmt_misc/${reg%%:*} ] && echo -1 > /proc/sys/fs/binfmt_misc/${reg%%:*}
|
||||
printf "%s" "$line" > /proc/sys/fs/binfmt_misc/register
|
||||
done
|
||||
done
|
@@ -1,2 +1,2 @@
|
||||
#!/bin/execlineb -P
|
||||
exec sh /etc/s6/sv/binfmt/shell_up
|
||||
exec sh /usr/lib/artix/binfmt.sh
|
||||
|
9
dbus-cg/down
Normal file
9
dbus-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/dbus.conf
|
||||
importas -uD "dbus" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
dbus-cg/type
Normal file
1
dbus-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
dbus-cg/up
Normal file
7
dbus-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/dbus.conf
|
||||
importas -uD "dbus" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
1
dbus-log/consumer-for
Normal file
1
dbus-log/consumer-for
Normal file
@@ -0,0 +1 @@
|
||||
dbus-srv
|
1
dbus-log/notification-fd
Normal file
1
dbus-log/notification-fd
Normal file
@@ -0,0 +1 @@
|
||||
3
|
1
dbus-log/pipeline-name
Normal file
1
dbus-log/pipeline-name
Normal file
@@ -0,0 +1 @@
|
||||
dbus
|
9
dbus-log/run
Normal file
9
dbus-log/run
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
envfile /etc/s6/config/dbus.conf
|
||||
importas -sCuD "n3 s2000000 T" DIRECTIVES DIRECTIVES
|
||||
ifelse { test -w /var/log } {
|
||||
foreground { install -d -o s6log -g s6log /var/log/dbus }
|
||||
s6-setuidgid s6log exec -c s6-log -d3 -b -- ${DIRECTIVES} /var/log/dbus
|
||||
}
|
||||
foreground { install -d -o s6log -g s6log /run/log/dbus }
|
||||
s6-setuidgid s6log exec -c s6-log -d3 -b -- ${DIRECTIVES} /run/log/dbus
|
1
dbus-log/type
Normal file
1
dbus-log/type
Normal file
@@ -0,0 +1 @@
|
||||
longrun
|
0
dbus-srv/dependencies.d/dbus-cg
Normal file
0
dbus-srv/dependencies.d/dbus-cg
Normal file
1
dbus-srv/notification-fd
Normal file
1
dbus-srv/notification-fd
Normal file
@@ -0,0 +1 @@
|
||||
3
|
1
dbus-srv/producer-for
Normal file
1
dbus-srv/producer-for
Normal file
@@ -0,0 +1 @@
|
||||
dbus-log
|
11
dbus-srv/run
Normal file
11
dbus-srv/run
Normal file
@@ -0,0 +1,11 @@
|
||||
#!/bin/execlineb -P
|
||||
foreground { dbus-uuidgen --ensure=/etc/machine-id }
|
||||
foreground { install -m755 -g 81 -o 81 -d /run/dbus }
|
||||
foreground {
|
||||
envfile /etc/s6/config/dbus.conf
|
||||
importas -uD "no" DBUS_UUIDGEN DBUS_UUIDGEN
|
||||
if { test ${DBUS_UUIDGEN} = "yes" }
|
||||
redirfd -w 1 /etc/machine-id dbus-uuidgen
|
||||
}
|
||||
fdmove -c 2 1
|
||||
exec dbus-daemon --system --nofork --nopidfile --print-pid=3
|
1
dbus-srv/type
Normal file
1
dbus-srv/type
Normal file
@@ -0,0 +1 @@
|
||||
longrun
|
42
dbus.conf
Normal file
42
dbus.conf
Normal file
@@ -0,0 +1,42 @@
|
||||
# Set to "yes" to regenerate the dbus machine id everytime the service
|
||||
# is brought up. The dbus documentation only expects the machine id to
|
||||
# persist during one boot session however systemd says it must persist
|
||||
# across every boot (i.e. never change). While many applications only
|
||||
# care if the machine-id is consistent during runtime, there are some
|
||||
# that do expect it to always stay the same.
|
||||
DBUS_UUIDGEN="no"
|
||||
|
||||
# This configures the directives used for s6-log in the log service.
|
||||
DIRECTIVES="n3 s2000000 T"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
9
elogind-cg/down
Normal file
9
elogind-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/elogind.conf
|
||||
importas -uD "elogind" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
elogind-cg/type
Normal file
1
elogind-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
elogind-cg/up
Normal file
7
elogind-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/elogind.conf
|
||||
importas -uD "elogind" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
31
elogind.conf
Normal file
31
elogind.conf
Normal file
@@ -0,0 +1,31 @@
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
0
elogind/dependencies.d/dbus
Normal file
0
elogind/dependencies.d/dbus
Normal file
0
elogind/dependencies.d/elogind-cg
Normal file
0
elogind/dependencies.d/elogind-cg
Normal file
2
elogind/run
Normal file
2
elogind/run
Normal file
@@ -0,0 +1,2 @@
|
||||
#!/bin/execlineb -P
|
||||
exec /usr/lib/elogind/elogind
|
1
elogind/type
Normal file
1
elogind/type
Normal file
@@ -0,0 +1 @@
|
||||
longrun
|
@@ -1,19 +0,0 @@
|
||||
#!/bin/sh
|
||||
# This is run by the kernel after the last task is removed from a
|
||||
# control group in the openrc hierarchy.
|
||||
|
||||
# Copyright (c) 2007-2015 The OpenRC Authors.
|
||||
# See the Authors file at the top-level directory of this distribution and
|
||||
# https://github.com/OpenRC/openrc/blob/master/AUTHORS
|
||||
#
|
||||
# This file is part of OpenRC. It is subject to the license terms in
|
||||
# the LICENSE file found in the top-level directory of this
|
||||
# distribution and at https://github.com/OpenRC/openrc/blob/master/LICENSE
|
||||
# This file may not be copied, modified, propagated, or distributed
|
||||
# except according to the terms contained in the LICENSE file.
|
||||
|
||||
cgroup=/sys/fs/cgroup/openrc
|
||||
PATH=/bin:/usr/bin:/sbin:/usr/sbin
|
||||
if [ -d ${cgroup}/"$1" ]; then
|
||||
rmdir ${cgroup}/"$1"
|
||||
fi
|
@@ -1,119 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
CGROUP_OPTS=nodev,noexec,nosuid
|
||||
CGROUP_MODE="$1"
|
||||
CGROUP_CONTROLLERS="$2"
|
||||
HAVE_CONTROLLER1_GROUPS="$3"
|
||||
|
||||
if [ $CGROUP_CONTROLLERS = "none" ]; then
|
||||
CGROUP_CONTROLLERS=""
|
||||
fi
|
||||
|
||||
cgroup2_find_path() {
|
||||
if grep -qw cgroup2 /proc/filesystems; then
|
||||
case "${CGROUP_MODE}" in
|
||||
hybrid) printf "/sys/fs/cgroup/unified" ;;
|
||||
unified) printf "/sys/fs/cgroup" ;;
|
||||
esac
|
||||
fi
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroup1_base() {
|
||||
grep -qw cgroup /proc/filesystems || return 0
|
||||
if ! mountpoint -q /sys/fs/cgroup; then
|
||||
local opts="${CGROUP_OPTS},mode=755,size=${rc_cgroupsize:-10m}"
|
||||
mount -n -t tmpfs -o "${opts}" cgroup_root /sys/fs/cgroup
|
||||
fi
|
||||
|
||||
if ! mountpoint -q /sys/fs/cgroup/openrc; then
|
||||
local agent="/etc/s6/sv/mount-cgroups/cgroup-release-agent.sh"
|
||||
mkdir /sys/fs/cgroup/openrc
|
||||
mount -n -t cgroup -o none,${CGROUP_OPTS},name=openrc,release_agent="$agent" openrc /sys/fs/cgroup/openrc
|
||||
printf 1 > /sys/fs/cgroup/openrc/notify_on_release
|
||||
fi
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroup1_controllers() {
|
||||
${HAVE_CONTROLLER1_GROUPS} && [ -e /proc/cgroups ] && grep -qw cgroup /proc/filesystems || return 0
|
||||
while read -r name _ _ enabled _; do
|
||||
case "${enabled}" in
|
||||
1) if mountpoint -q "/sys/fs/cgroup/${name}";then continue;fi
|
||||
local x
|
||||
for x in $CGROUP_CONTROLLERS; do
|
||||
[ "${name}" = "blkio" ] && [ "${x}" = "io" ] &&
|
||||
continue 2
|
||||
[ "${name}" = "${x}" ] &&
|
||||
continue 2
|
||||
done
|
||||
mkdir "/sys/fs/cgroup/${name}"
|
||||
mount -n -t cgroup -o "${CGROUP_OPTS},${name}" "${name}" "/sys/fs/cgroup/${name}"
|
||||
;;
|
||||
esac
|
||||
done < /proc/cgroups
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroup2_base() {
|
||||
grep -qw cgroup2 /proc/filesystems || return 0
|
||||
local base
|
||||
base="$(cgroup2_find_path)"
|
||||
mkdir -p "${base}"
|
||||
mount -t cgroup2 none -o "${CGROUP_OPTS},nsdelegate" "${base}" 2> /dev/null ||
|
||||
mount -t cgroup2 none -o "${CGROUP_OPTS}" "${base}"
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroup2_controllers() {
|
||||
grep -qw cgroup2 /proc/filesystems || return 0
|
||||
local active cgroup_path x
|
||||
cgroup_path="$(cgroup2_find_path)"
|
||||
[ -z "${cgroup_path}" ] && return 0
|
||||
[ ! -e "${cgroup_path}/cgroup.controllers" ] && return 0
|
||||
[ ! -e "${cgroup_path}/cgroup.subtree_control" ] && return 0
|
||||
read -r active < "${cgroup_path}/cgroup.controllers"
|
||||
for x in ${active}; do
|
||||
echo "+${x}" > "${cgroup_path}/cgroup.subtree_control"
|
||||
done
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroups_hybrid() {
|
||||
cgroup1_base
|
||||
cgroup2_base
|
||||
cgroup2_controllers
|
||||
cgroup1_controllers
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroups_legacy() {
|
||||
cgroup1_base
|
||||
cgroup1_controllers
|
||||
return 0
|
||||
}
|
||||
|
||||
cgroups_unified() {
|
||||
cgroup2_base
|
||||
cgroup2_controllers
|
||||
return 0
|
||||
}
|
||||
|
||||
mount_cgroups() {
|
||||
case "${CGROUP_MODE}" in
|
||||
hybrid) cgroups_hybrid ;;
|
||||
legacy) cgroups_legacy ;;
|
||||
unified) cgroups_unified ;;
|
||||
esac
|
||||
return 0
|
||||
}
|
||||
|
||||
mount_cgs() {
|
||||
if [ -d /sys/fs/cgroup ];then
|
||||
mount_cgroups
|
||||
return 0
|
||||
fi
|
||||
return 1
|
||||
}
|
||||
|
||||
mount_cgs
|
@@ -3,4 +3,4 @@ envfile /etc/s6/config/mount-cgroups.conf
|
||||
importas -uD "unified" CGROUP_MODE CGROUP_MODE
|
||||
importas -uD "none" CGROUP_CONTROLLERS CGROUP_CONTROLLERS
|
||||
importas -uD "true" HAVE_CONTROLLER1_GROUPS HAVE_CONTROLLER1_GROUPS
|
||||
exec sh /etc/s6/sv/mount-cgroups/shell_up $CGROUP_MODE $CGROUP_CONTROLLERS $HAVE_CONTROLLER1_GROUPS
|
||||
exec sh /usr/lib/artix/mount-cgroups.sh $CGROUP_MODE $CGROUP_CONTROLLERS $HAVE_CONTROLLER1_GROUPS
|
||||
|
9
tty1-cg/down
Normal file
9
tty1-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty1.conf
|
||||
importas -uD "tty1" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty1-cg/type
Normal file
1
tty1-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty1-cg/up
Normal file
7
tty1-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty1.conf
|
||||
importas -uD "tty1" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty1.conf
32
tty1.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty1/dependencies.d/tty1-cg
Normal file
0
tty1/dependencies.d/tty1-cg
Normal file
9
tty2-cg/down
Normal file
9
tty2-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty2.conf
|
||||
importas -uD "tty2" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty2-cg/type
Normal file
1
tty2-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty2-cg/up
Normal file
7
tty2-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty2.conf
|
||||
importas -uD "tty2" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty2.conf
32
tty2.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty2/dependencies.d/tty2-cg
Normal file
0
tty2/dependencies.d/tty2-cg
Normal file
9
tty3-cg/down
Normal file
9
tty3-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty3.conf
|
||||
importas -uD "tty3" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty3-cg/type
Normal file
1
tty3-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty3-cg/up
Normal file
7
tty3-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty3.conf
|
||||
importas -uD "tty3" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty3.conf
32
tty3.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty3/dependencies.d/tty3-cg
Normal file
0
tty3/dependencies.d/tty3-cg
Normal file
9
tty4-cg/down
Normal file
9
tty4-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty4.conf
|
||||
importas -uD "tty4" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty4-cg/type
Normal file
1
tty4-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty4-cg/up
Normal file
7
tty4-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty4.conf
|
||||
importas -uD "tty4" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty4.conf
32
tty4.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty4/dependencies.d/tty4-cg
Normal file
0
tty4/dependencies.d/tty4-cg
Normal file
9
tty5-cg/down
Normal file
9
tty5-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty5.conf
|
||||
importas -uD "tty5" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty5-cg/type
Normal file
1
tty5-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty5-cg/up
Normal file
7
tty5-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty5.conf
|
||||
importas -uD "tty5" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty5.conf
32
tty5.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty5/dependencies.d/tty5-cg
Normal file
0
tty5/dependencies.d/tty5-cg
Normal file
9
tty6-cg/down
Normal file
9
tty6-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty6.conf
|
||||
importas -uD "tty6" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
tty6-cg/type
Normal file
1
tty6-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
tty6-cg/up
Normal file
7
tty6-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/tty6.conf
|
||||
importas -uD "tty6" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
32
tty6.conf
32
tty6.conf
@@ -6,3 +6,35 @@ ARGS=""
|
||||
|
||||
# Getty program to use.
|
||||
GETTY="agetty"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
0
tty6/dependencies.d/tty6-cg
Normal file
0
tty6/dependencies.d/tty6-cg
Normal file
32
ttyS.conf
32
ttyS.conf
@@ -10,3 +10,35 @@ GETTY="agetty"
|
||||
# Serial tty address and baud rate
|
||||
TTY="ttyAMA0"
|
||||
BAUD_RATE="115200"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
9
udevd-cg/down
Normal file
9
udevd-cg/down
Normal file
@@ -0,0 +1,9 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/udevd.conf
|
||||
importas -uD "udevd" SV_NAME
|
||||
importas -uD "" SV_CG_SEND_SIGHUP
|
||||
importas -uD "" SV_CG_TIMEOUT_STOPSEC
|
||||
importas -uD "" SV_CG_SEND_SIGKILL
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh down $SV_NAME $SV_CG_SEND_SIGHUP $SV_CG_TIMEOUT_STOPSEC $SV_CG_SEND_SIGKILL
|
1
udevd-cg/type
Normal file
1
udevd-cg/type
Normal file
@@ -0,0 +1 @@
|
||||
oneshot
|
7
udevd-cg/up
Normal file
7
udevd-cg/up
Normal file
@@ -0,0 +1,7 @@
|
||||
#!/bin/execlineb -P
|
||||
|
||||
envfile /etc/s6/config/udevd.conf
|
||||
importas -uD "udevd" SV_NAME
|
||||
importas -uD "" SV_CG_SETTINGS
|
||||
|
||||
exec sh /usr/lib/artix/sv-cg.sh up $SV_NAME $SV_CG_SETTINGS
|
0
udevd-srv/dependencies.d/udevd-cg
Normal file
0
udevd-srv/dependencies.d/udevd-cg
Normal file
32
udevd.conf
32
udevd.conf
@@ -1,2 +1,34 @@
|
||||
# This configures the directives used for s6-log in the log service.
|
||||
DIRECTIVES="n3 s6000000 T"
|
||||
|
||||
# This variable contains the cgroups version 2 settings for your services.
|
||||
# If this is set in this file, the settings will apply to all services.
|
||||
# If you want different settings for each service, place the settings in
|
||||
# /etc/conf.d/foo for service foo.
|
||||
# The format is to specify the setting and value followed by a newline.
|
||||
# Multiple settings and values can be specified.
|
||||
# For example, you would use this to set the maximum memory and maximum
|
||||
# number of pids for a service.
|
||||
#SV_CG_SETTINGS="
|
||||
#memory.max 10485760
|
||||
#pids.max max
|
||||
#"
|
||||
#
|
||||
# For more information about the adjustments that can be made with
|
||||
# cgroups version 2, see Documentation/cgroups-v2.txt in the linux kernel
|
||||
# source tree.
|
||||
#SV_CG_SETTINGS=""
|
||||
|
||||
# If this is yes, we will send sighup to the processes in the cgroup
|
||||
# immediately after stopsig and sigcont.
|
||||
#SV_CG_SEND_SIGHUP="NO"
|
||||
|
||||
# This is the amount of time in seconds that we delay after sending sigcont
|
||||
# and optionally sighup, before we optionally send sigkill to all
|
||||
# processes in the # cgroup.
|
||||
# The default is 90 seconds.
|
||||
#SV_CG_TIMEOUT_STOPSEC="90"
|
||||
|
||||
# If this is set to no, we do not send sigkill to all processes in the
|
||||
# cgroup.
|
||||
#SV_CG_SEND_SIGKILL="YES"
|
||||
|
Reference in New Issue
Block a user