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

Fixes #23615 - Redirect katello service #2585

Merged

Conversation

johnpmitsch
Copy link

Katello-service functionality has moved to foreman-maintain. We
can redirect katello-service there since it uses the same arguments.
Katello-service is used pretty widely in documenation and scripts,
I don't see a need to deprecate this just yet (we always can later).
I aligned the issue with foreman 1.19(katello 3.8), so katello
3.7 will still have the original katello-service script.

For plugin updates, please indicate which repos this should be built into:

  • Nightly
  • 1.18
  • 1.17
  • 1.16

See Foreman's plugin maintainer documentation for more information.


Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the package katello-service should now depend on foreman_maintain and no longer on ruby and /bin/systemctl.

@@ -1,98 +1,7 @@
#!/usr/bin/env ruby
#!/usr/bin/bash
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bash is usually found in /bin. Might be better to just depend on /bin/sh given the simplicity of the script.

@johnpmitsch
Copy link
Author

[test rpm]

@johnpmitsch
Copy link
Author

@ekohl installing this on a nightly system doesn't seem to overwrite katello-service and the old command is still there. Am I missing something in the spec file?

Katello-service functionality has moved to foreman-maintain. We
can redirect katello-service there since it uses the same arguments.
Katello-service is used pretty widely in documenation and scripts,
I don't see a need to deprecate this just yet (we always can later).
I aligned the issue with foreman 1.19(katello 3.8), so  katello
3.7 will still have the original katello-service script.
@johnpmitsch
Copy link
Author

@ekohl nvm, I was only installing katello and katello-common, which were installing katello-service from local repos. When I installed the katello-service rpm from the koji build, everything works:

Here is some example output:

[root@centos7-katello-nightly ~]# katello-service start
Redirecting to 'foreman-maintain service'
Running Start Services
================================================================================
Check if command is run as root user:                                 [OK]
--------------------------------------------------------------------------------
Start applicable services: 
Starting the following service(s):

postgresql, rh-mongodb34-mongod, qdrouterd, qpidd, squid, pulp_resource_manager, pulp_streamer, foreman-proxy, pulp_celerybeat, pulp_workers, tomcat, dynflowd, httpd, puppetserver

| All services started                                                [OK]      
--------------------------------------------------------------------------------

[root@centos7-katello-nightly ~]# katello-service start --only httpd
Redirecting to 'foreman-maintain service'
Running Start Services
================================================================================
Check if command is run as root user:                                 [OK]
--------------------------------------------------------------------------------
Start applicable services: 
Starting the following service(s):

httpd

\ All services started                                                [OK]      
--------------------------------------------------------------------------------

[root@centos7-katello-nightly ~]# katello-service stop --only httpd
Redirecting to 'foreman-maintain service'
Running Stop Services
================================================================================
Check if command is run as root user:                                 [OK]
--------------------------------------------------------------------------------
Stop applicable services: 
Stopping the following service(s):

httpd

| All services stopped                                                [OK]      
--------------------------------------------------------------------------------

[root@centos7-katello-nightly ~]# 

@sean797
Copy link
Member

sean797 commented Jun 12, 2018

Should the RPM now require /bin/sh ?

@ekohl
Copy link
Member

ekohl commented Jun 13, 2018

@sean797 that's done automatically:

Processing files: katello-service-3.8.0-2.nightly.el7.noarch
Provides: katello-service = 3.8.0-2.nightly.el7
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(FileDigests) <= 4.6.0-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Requires: /bin/sh

Copy link
Member

@sean797 sean797 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't know that @ekohl 👍 in that case ACK

@johnpmitsch johnpmitsch merged commit d9f3f54 into theforeman:rpm/develop Jun 13, 2018
@johnpmitsch johnpmitsch deleted the 23615_katello_service_redir branch June 13, 2018 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants