Giter VIP home page Giter VIP logo

Comments (7)

corneldamian avatar corneldamian commented on August 25, 2024

Had the same problem and i didn't had RootDirectory. Without RootDirectory i had the same problem with the working dir, even if i've removed the "

from service.

kardianos avatar kardianos commented on August 25, 2024

Thanks for the report. I need to look into systemd unit files more, again.

from service.

tsharma14 avatar tsharma14 commented on August 25, 2024

Hi,
Can you please let me know the progress on this bug, as I am facing the same issue. I am setting some value in working directory alone but it is not reflecting. Can you please share the alternative way to set the PWD value in systemd service file.

Thanks

from service.

kardianos avatar kardianos commented on August 25, 2024

I have not yet looked into this. Thanks for the ping. I'll research this later this week hopefully.

from service.

tsharma14 avatar tsharma14 commented on August 25, 2024

Can you please provide some alternative approach for this. As my service is not running properly due to this. I need to change the current working directory to some other dir in service file. which will enable my server to pick the correct path using PWD.

from service.

dach384 avatar dach384 commented on August 25, 2024

Any update on this?

from service.

corford avatar corford commented on August 25, 2024

I don't know for RootDirectory but WorkingDirectory doesn't support double quotes (at least with the version of systemd that's present on Ubuntu 16.04). The solution is to escape the path with systemd-escape --path and prepend a leading '/' to the result.

WorkingDirectory="/var/path with spaces in it/bin" [ DOES NOT work ]

WorkingDirectory=/var-path\x20with\x20spaces\x20in\x20it-bin [ DOES work ]

More info here:
https://www.freedesktop.org/software/systemd/man/systemd-escape.html
https://serverfault.com/a/792831/173055
https://unix.stackexchange.com/a/242028

from service.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.