-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
109 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Set the baud rate of the terminal line | ||
#baud="" | ||
|
||
# set the terminal type | ||
#term_type="linux" | ||
|
||
# extra options to pass to getty for this port | ||
#getty_options="" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/sbin/openrc-run | ||
|
||
supervisor=supervise-daemon | ||
port="${RC_SVCNAME#*.}" | ||
term_type="${term_type:-linux}" | ||
|
||
description="getty on terminal $port" | ||
command=/sbin/getty | ||
command_args="${getty_options} ${port} ${baud} ${term_type}" | ||
|
||
|
||
depend() { | ||
after local | ||
keyword -prefix | ||
} | ||
|
||
start_pre() { | ||
if [ "$port" = "$RC_SVCNAME" ]; then | ||
eerror "${RC_SVCNAME} cannot be started directly. You must create" | ||
eerror "symbolic links to it for the ports you want to start" | ||
eerror "getty on and add those to the appropriate runlevels." | ||
return 1 | ||
fi | ||
export EINFO_QUIET=yes | ||
} | ||
|
||
stop_pre() | ||
{ | ||
export EINFO_QUIET=yes | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters