# Adding a ruby controller via plugin

**URL:** <https://meta.discourse.org/t/adding-a-ruby-controller-via-plugin/60661>\
**Category:** Development\
**Created:** [2017 年4 月 8 日 20:28 UTC](https://meta.discourse.org/t/adding-a-ruby-controller-via-plugin/60661 "2017-04-08T20:28:11Z")\
**Posts on this page:** 1\
**Showing post:** 13

<div class="post-metadata">

作者： ![david](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/david/32/157490_2.png) [@david](https://meta.discourse.org/u/david)\
发布日期： [2017 年4 月 8 日 23:01 UTC](https://meta.discourse.org/t/adding-a-ruby-controller-via-plugin/60661/13 "2017-04-08T23:01:13Z")

</div>

That sounds like a possibility

I’m not sure whether things in `plugins/{name}/app/controllers` are loaded automatically. You might need to “require” them, for example:

> <https://github.com/discourse/discourse-slack-official/blob/master/plugin.rb#L25>

---

_[View the full topic](https://meta.discourse.org/t/adding-a-ruby-controller-via-plugin/60661)._
