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

API: Create systemd file so the app can run as a Linux system daemon. #2737

Open
palisadoes opened this issue Dec 4, 2024 · 11 comments
Open
Assignees
Labels

Comments

@palisadoes
Copy link
Contributor

Is your feature request related to a problem? Please describe.

For the application to be truly enterprise ready it needs to run as a Linux system daemon controlled by the systemctl command.

Describe the solution you'd like

  1. We need a systemd-talawa-api file created that can be used for this purpose
  2. You can use these files for guidance in setting this up. They are from our switchmap repo and work correctly. This will allow you to control the apps using the systemctl command
  1. The final file must be placed in a new examples/linux/systemd directory
  2. You must be able to prove that the system daemon will work using the resulting file.
    Describe alternatives you've considered
    A clear and concise description of any alternative solutions or features you've considered.

Approach to be followed (optional)

  • N/A

Additional context

  • N/A

Potential internship candidates

Please read this if you are planning to apply for a Palisadoes Foundation internship

@Rajveerchoubisa
Copy link

Hello @palisadoes , may I work on this issue?

@PurnenduMIshra129th
Copy link

@palisadoes exactly what you want the steps to run the api in linux system?

Copy link

This issue did not get any activity in the past 10 days and will be closed in 180 days if no update occurs. Please check if the develop branch has fixed it and report again or close the issue.

@github-actions github-actions bot added the no-issue-activity No issue activity label Dec 16, 2024
@PurnenduMIshra129th
Copy link

PurnenduMIshra129th commented Dec 23, 2024

@palisadoes plz assign i will do it.if @Rajveerchoubisa not working on it.

@github-actions github-actions bot removed the no-issue-activity No issue activity label Dec 24, 2024
@palisadoes
Copy link
Contributor Author

Unassigning due to inactivity and/or no submitted PR. Others need to get a chance. Please let us know whether you want to be reassigned before someone else requests assignment or select another issue.

@palisadoes palisadoes removed the unapproved Unapproved for Pull Request label Dec 24, 2024
@PurnenduMIshra129th
Copy link

@palisadoes it is solved.Now it is running as system daemon. Here is the video.

2024-12-25.18-11-09.1.mp4

@palisadoes
Copy link
Contributor Author

That's really good.

  1. Please add instructions to the INSTALLATION.md file.
  2. Place the systemd file in a new examples/linux/systemd file
  3. Submit the PR

@PurnenduMIshra129th
Copy link

@palisadoes ok will do today

@palisadoes
Copy link
Contributor Author

  1. Also, add comments to the systemd file just like in the link for switchmap. That file was structured to make it easy for the end user to configure.
  2. Document where to view log files
  3. Shouldn't it run in a prod environment?
  4. The shell script should take arguments for start / stop to make it cleaner

@PurnenduMIshra129th
Copy link

For now node env i only make for development will add for production also ,yes the script has start ,stop, restart command but not as argument but i have done like this (
sudo systemctl status talawa-api
sudo systemctl stop talawa-api
sudo systemctl start talawa-api
sudo systemctl daemon-reload
sudo systemctl restart talawa-api) this is to control the service and this command (sudo journalctl -u talawa-api.service ) to see the log files. .Is it okay to use like this?

Copy link

github-actions bot commented Jan 5, 2025

This issue did not get any activity in the past 10 days and will be closed in 180 days if no update occurs. Please check if the develop branch has fixed it and report again or close the issue.

@github-actions github-actions bot added the no-issue-activity No issue activity label Jan 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants