-
Notifications
You must be signed in to change notification settings - Fork 446
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
Upstart: source /etc/default/${{app_name}} #641
Conversation
This should fix the limitation mentioned in http://www.scala-sbt.org/sbt-native-packager/archetypes/java_server/customize.html#linux-configuration: > The server archetype adds an additional way with an etc-default file placed in src/templates, which currently only works for SystemV.
LGTM. |
@@ -27,7 +27,11 @@ end script | |||
# set the working directory of the job processes | |||
chdir ${{chdir}} | |||
|
|||
setuid ${{daemon_user}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we had that at one point in time and it didn't work for some reason. On which systems did you test this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just curious now if we are executing without sudo, unless I am wrong I think the command should be sudo bin/${{exec}}
I am seeing issues with the daemon_user not having enough permissions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ive tried this < daemon_user > is not in the sudoers file.
Also to make this work I had to do this
sudo chown ${{daemon_user}}:${{daemon_group}} -R /usr/share/${{app_name}}l/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't want to do sudo chown ${{daemon_user}}:${{daemon_group}} -R /usr/share/${{app_name}}l/
/usr/share/<app>
is generally owned by root
. If you need write access to disk you add linuxPackageMappings
with exactly the permissions you need.
Why should the daemonUser
be in the sudoers
file?
Nice :) see my one comment. IIRC we had issues with the setuid not working, but I don't remember why. Can you fix the test? |
@nafg you had time to look into this, or do you need any help? |
It was Ubuntu. I haven't had time. On Tue, Aug 11, 2015, 6:10 PM Nepomuk Seiler [email protected]
|
FYI, I updated the documentation in my PR saying that upstart specifically doesn't source |
This should fix the limitation mentioned in http://www.scala-sbt.org/sbt-native-packager/archetypes/java_server/customize.html#linux-configuration: