# Kan ik een runit-service toevoegen in een plugin?

**URL:** <https://meta.discourse.org/t/can-i-add-an-runit-service-in-a-plugin/205086>\
**Category:** Development\
**Created:** [3 oktober 2021 om 12:14 UTC](https://meta.discourse.org/t/can-i-add-an-runit-service-in-a-plugin/205086 "2021-10-03T12:14:51Z")\
**Posts on this page:** 1\
**Showing post:** 6

<div class="post-metadata">

**Author:** ![schleifer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/schleifer/32/86416_2.png) [@schleifer](https://meta.discourse.org/u/schleifer)\
**Post date:** [8 oktober 2021 om 07:47 UTC](https://meta.discourse.org/t/can-i-add-an-runit-service-in-a-plugin/205086/6 "2021-10-08T07:47:22Z")

</div>

> [@spirobel](#):
>
> if it is possible to add an runit service in a plugin?

It is not. Inside the container all plugin code runs as the `discourse` user. That user does not have sufficient permissions (inside the container again) to control runit services.

> [@spirobel](#):
>
> If thats not possible I would be glad to hear about your strategies to deal with this kind of issue

Run the process in another Docker container on the same hardware. It should listen on a local TCP port. Export the URL to connect to the other service in the [`env:`](https://github.com/discourse/discourse_docker/blob/ee061f17a9926e41dd4ea13334246939db10ea59/samples/standalone.yml#L39) block in `app.yaml`, e.g.:

```plaintext
env:
    CUSTOM_SERVICE_URL: 'localhost:5309'

```

Have the plugin find the connection string via `ENV["CUSTOM_SERVICE_URL"]`

---

_[View the full topic](https://meta.discourse.org/t/can-i-add-an-runit-service-in-a-plugin/205086)._
