Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add sed for systemd service #611

Open
wants to merge 1 commit into
base: testing
Choose a base branch
from
Open

Conversation

f4iey
Copy link

@f4iey f4iey commented Feb 7, 2022

Added sed so that the username is automatically set in auto_rx.service
Admitting the script is run by the right user (not as root)
I just tested and it worked fine for me

add sed so that the username is *automatically set* in `auto_rx.service`
Admitting the script is run by the right user (not as root)
I just tested and it worked fine for me
@joyel24
Copy link

joyel24 commented Apr 30, 2023

It should be merged in my opinion !

@@ -82,4 +82,7 @@ cp ../demod/mod/meisei100mod .
cp ../demod/mod/imet54mod .
cp ../demod/mod/mp3h1mod .

# Match user name in systemd service: no more need to use a text editor
sed -i "s/pi/$(whoami)/g" auto_rx.service
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO the Specifiers should be used here %h specifically

https://www.freedesktop.org/software/systemd/man/latest/systemd.unit.html#Specifiers

to make it more generic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants