### Summary

There is some inconsistent code for checking if systemd exists between the service module and the service_facts module:

https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/service.py#L480

and 

https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/service_facts.py#L246

This causes some odd behavior when using the docker systemctl replacement script: https://github.com/gdraheim/docker-systemctl-replacement

The advice when using this script is to create the canary directory /run/systemd/system but when using service_facts module no service facts are collected as the canary folder check is not present so it goes on to inspect the contents of /proc/1/comm, which in this situation is "systemctl" instead of "systemd".  

Ideally both modules would use the exact same code to check for systemd.  And to help make this work with the docker systemctl replacement script it would be great if the canary folder check could be added to service_facts module.

Note, docker-systemctl-replacement is a recommendation for using systemctl commands inside containers such as for molecule testing as systemd inside containers are difficult to configure correctly (I can attest to this!).  We use molecule to validate our AWS AMI packer builds which use ansible, since we are creating machine images we have to interact with systemctl for our unit tests to verify as service was installed and running etc.

### Issue Type

Bug Report

### Component Name

lib/ansible/modules/service_facts.py

### Ansible Version

```console
$ ansible --version

ansible [core 2.15.0]
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /root/.local/lib/python3.9/site-packages/ansible
  ansible collection location = /root/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/bin/ansible
  python version = 3.9.16 (main, Dec 21 2022, 10:57:18) [GCC 8.5.0 20210514 (Red Hat 8.5.0-17)] (/usr/bin/python3.9)
  jinja version = 3.0.3
  libyaml = True
```


### Configuration

```console
# if using a version older than ansible-core 2.12 you should omit the '-t all'
$ ansible-config dump --only-changed -t all

CONFIG_FILE() = /etc/ansible/ansible.cfg
DEFAULT_VAULT_PASSWORD_FILE(env: ANSIBLE_VAULT_PASSWORD_FILE) = /root/.ansible/.pvault
```


### OS / Environment

# cat /etc/os-release
NAME="Red Hat Enterprise Linux"
VERSION="8.8 (Ootpa)"
ID="rhel"
ID_LIKE="fedora"
VERSION_ID="8.8"
PLATFORM_ID="platform:el8"
PRETTY_NAME="Red Hat Enterprise Linux 8.8 (Ootpa)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:redhat:enterprise_linux:8::baseos"
HOME_URL="https://www.redhat.com/"
DOCUMENTATION_URL="https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8"
BUG_REPORT_URL="https://bugzilla.redhat.com/"

REDHAT_BUGZILLA_PRODUCT="Red Hat Enterprise Linux 8"
REDHAT_BUGZILLA_PRODUCT_VERSION=8.8
REDHAT_SUPPORT_PRODUCT="Red Hat Enterprise Linux"
REDHAT_SUPPORT_PRODUCT_VERSION="8.8"


### Steps to Reproduce

<!--- Paste example playbooks or commands between quotes below -->
```yaml (paste below)

```

create a container that uses the docker-systemctl-replacement script:

```

# wget https://raw.githubusercontent.com/gdraheim/docker-systemctl-replacement/master/files/docker/systemctl.py 
# then add this to Dockerfile

COPY systemctl.py /usr/bin/systemctl
RUN chmod 755 /usr/bin/systemctl
RUN mkdir /run/systemd/system/

CMD ["/usr/bin/systemctl"]
```

Build container and run, /proc/1/comm is now systemctl instead of systemd but the canary dir /run/systemd/system is present per https://github.com/gdraheim/docker-systemctl-replacement/blob/master/SERVICE-MANAGER.md

from within the container try to use the service_facts module:

```
    - name: "Collect facts about system services."
      service_facts:
      register: services_state

    - debug:
        msg:
          "service_facts: ": "{{ services_state }}"
```

output:

```
TASK [Collect facts about system services.] ************************************
skipping: [aws-amzn2-gold-ami]

TASK [debug] *******************************************************************
ok: [aws-amzn2-gold-ami] => {
    "msg": {
        "service_facts: ": {
            "changed": false,
            "failed": false,
            "msg": "Failed to find any services. This can be due to privileges or some other configuration issue.",
            "skipped": true
        }
    }
}
```

### Expected Results

If I add the check for the canary folders to service_facts.py I get the expected results:

```
TASK [Collect facts about system services.] ************************************
ok: [aws-amzn2-gold-ami]

TASK [debug] *******************************************************************
ok: [aws-amzn2-gold-ami] => {
    "msg": {
        "service_facts: ": {
            "ansible_facts": {
                "services": {
                    "README.service": {
                        "name": "README.service",
                        "source": "systemd",
                        "state": "stopped",
                        "status": "disabled"
                    },
                    "amazon-cloudwatch-agent.service": {
                        "name": "amazon-cloudwatch-agent.service",
                        "source": "systemd",
                        "state": "stopped",
                        "status": "enabled"
                    },
<snip>
```

### Actual Results

```console
TASK [Collect facts about system services.] ************************************
skipping: [aws-amzn2-gold-ami]

TASK [debug] *******************************************************************
ok: [aws-amzn2-gold-ami] => {
    "msg": {
        "service_facts: ": {
            "changed": false,
            "failed": false,
            "msg": "Failed to find any services. This can be due to privileges or some other configuration issue.",
            "skipped": true
        }
    }
}
```
```


### Code of Conduct

- [X] I agree to follow the Ansible Code of Conduct
status = self.get_sunos_svcs_status()
        
        
        if status == 'online':
            self.running = True
        else:
            self.running = False
    def get_sunos_svcs_status(self):
        rc, stdout, stderr = self.execute_command("%s %s" % (self.svcs_cmd, self.name))
        if rc == 1:
            if stderr:
                self.module.fail_json(msg=stderr)
            else:
                self.module.fail_json(msg=stdout)
        lines = stdout.rstrip("\n").split("\n")
        status = lines[-1].split(" ")[0]
        
        
        return status
    def service_enable(self):
        
        rc, stdout, stderr = self.execute_command("%s -l %s" % (self.svcs_cmd, self.name))
        if rc != 0:
            if stderr:
                self.module.fail_json(msg=stderr)
            else:
                self.module.fail_json(msg=stdout)
        enabled = False
        temporary = False