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

[Meta] Improve Deb/Rpm OpenSearch packaging in 2.x Releases #4087

Closed
20 of 24 tasks
smortex opened this issue Sep 26, 2023 · 6 comments
Closed
20 of 24 tasks

[Meta] Improve Deb/Rpm OpenSearch packaging in 2.x Releases #4087

smortex opened this issue Sep 26, 2023 · 6 comments
Assignees
Labels
bug Something isn't working deb rpm

Comments

@smortex
Copy link
Contributor

smortex commented Sep 26, 2023

Context

OpenSearch / OpenSearch Dashboard packages can be improved in several areas. Some of these improvements can arguably be considered breaking changes because they may somewhat disrupt users workflow. This PR is intended to aggregate the packaging improvement progress, see where we are and what are the next moves.

Progress

@automaticserver
Copy link

The postinst Script inside opensearch package has several problems. First it doesn't use the right abstraction tools. Never use "systemctl" or "service" or whatever directly to interact with the init system. For good reasons there are abstractions to handle implementation details of the currrent init system.

Please use:

  • invoke-rc.d to start/stop/restart service
  • update-rc.d to enable/disable a service

https://www.debian.org/doc/debian-policy/ch-opersys.html#running-init-scripts

They does always the RIGHT thing, even if a system administrator changes his init system. You can rely on them and save code inside postinst.

@prudhvigodithi prudhvigodithi changed the title [Meta] Improve OpenSearch packaging [Meta] Improve Deb/Rpm OpenSearch packaging Nov 27, 2023
@peterzhuamazon
Copy link
Member

The postinst Script inside opensearch package has several problems. First it doesn't use the right abstraction tools. Never use "systemctl" or "service" or whatever directly to interact with the init system. For good reasons there are abstractions to handle implementation details of the currrent init system.

Please use:

* invoke-rc.d to start/stop/restart service

* update-rc.d to enable/disable a service

https://www.debian.org/doc/debian-policy/ch-opersys.html#running-init-scripts

They does always the RIGHT thing, even if a system administrator changes his init system. You can rely on them and save code inside postinst.

That is a good callout @automaticserver we will look into those abstractions.
Thanks.

@automaticserver
Copy link

Please have a look at my newly created proposal: #4243. E.g. there would be no need to implicitly use the abstractions as debhelper would generate those parts in the maintainer script the correct way automatically.

/dm

@peterzhuamazon peterzhuamazon self-assigned this Mar 13, 2024
@peterzhuamazon peterzhuamazon changed the title [Meta] Improve Deb/Rpm OpenSearch packaging [Meta] Improve Deb/Rpm OpenSearch packaging in 2.x Releases Apr 22, 2024
@peterzhuamazon
Copy link
Member

We will close the bugs related to 2.x, and will move some issues to track in the next possible major version.

@peterzhuamazon
Copy link
Member

A new meta issue for the next major version release will be created later.

@peterzhuamazon
Copy link
Member

Closing for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working deb rpm
Projects
Development

No branches or pull requests

5 participants