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

Make logging directory configurable #2388

Closed
crimeminister opened this issue Jun 19, 2024 · 5 comments · Fixed by #2391
Closed

Make logging directory configurable #2388

crimeminister opened this issue Jun 19, 2024 · 5 comments · Fixed by #2391
Assignees

Comments

@crimeminister
Copy link

In the process of configuring systemd to run iroh, I am attempting to use a "dynamic user" to run the service. This effectively sandboxes the service by making the full filesystem read-only except for a specific "state directory" (/var/lib/iroh in my configuration). When attempting to run the service with this configuration I see the error:

Error: failed to create log directory: Read-only file system (os error 30)

I would like to configure iroh to write logs to /var/log/iroh, which I will make writable by the systemd "dynamic user" that ends up running the service. Would it be possible to expose the log output directory as a configuration knob?

@divagant-martian divagant-martian moved this to 🏗 In progress in iroh Jun 20, 2024
@divagant-martian divagant-martian self-assigned this Jun 20, 2024
@divagant-martian divagant-martian linked a pull request Jun 20, 2024 that will close this issue
4 tasks
@divagant-martian
Copy link
Contributor

@crimeminister please give #2391 a go if you have the bandwidth to do so

@matheus23
Copy link
Contributor

Do we know if there's other files read/written from iroh with non-configurable locations? We'd need to make sure everything is configurable to solve OP's use-case IIUC.

@dignifiedquire
Copy link
Contributor

Do we know if there's other files read/written from iroh with non-configurable locations?

All other files should be written into the main iroh folder, which is a single configurable place. I am surprised our logs don't go in there by default

@divagant-martian
Copy link
Contributor

divagant-martian commented Jun 21, 2024

our logs go in the iroh folder. The use case here is that he wants logs to go somewhere else instead, different to the iroh folder (/var/lib/iroh, and /var/log/iroh)

@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in iroh Jun 21, 2024
@crimeminister
Copy link
Author

Thanks for this, everyone! I appreciate the quick and helpful response.

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

Successfully merging a pull request may close this issue.

4 participants