Skip to content

Alpine openRC multiplex service file #115

Description

@wbo2020

Consider adding an 'xray@' multiplex service file like the systemd one, no need to rewrite the custom service file by the user.
(Any path valid symbol character can be used as a separator)
very simple POSIX shell trick.

Only need to add this to the original init.d script
#!/sbin/openrc-run

config_name="${RC_SVCNAME#*@}"
configfile="/usr/local/etc/xray/${config_name}.json"
command_args="run -config=$configfile"

usage:
ln -s /etc/init.d/xray@ /etc/init.d/xray@yourconfigname_in_xray_folder
etc..

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions