# Plugin hook using a private repository

**URL:** <https://meta.discourse.org/t/plugin-hook-using-a-private-repository/49923>\
**Category:** Development\
**Created:** [September 9, 2016, 7:54am UTC](https://meta.discourse.org/t/plugin-hook-using-a-private-repository/49923 "2016-09-09T07:54:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kgish](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/kgish/32/121131_2.png) [@kgish](https://meta.discourse.org/u/kgish)\
**Post date:** [September 9, 2016, 7:54am UTC](https://meta.discourse.org/t/plugin-hook-using-a-private-repository/49923/1 "2016-09-09T07:54:53Z")

</div>

Having created a discourse plug for a customer which is located in a private git repository, and added it to the hooks section of app.yml, I need to allow git access.

How do I setup the proper credentials to make it work?

---

<div class="post-metadata">

**Author:** ![mpalmer](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mpalmer/32/45740_2.png) [@mpalmer](https://meta.discourse.org/u/mpalmer)\
**Post date:** [September 9, 2016, 9:25am UTC](https://meta.discourse.org/t/plugin-hook-using-a-private-repository/49923/2 "2016-09-09T09:25:24Z")

</div>

Make a hook script that drops an SSH private key into `/root/.ssh/id_rsa`, then reference the git repo as an SSH-accessible one.

---

<div class="post-metadata">

**Author:** ![kgish](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/kgish/32/121131_2.png) [@kgish](https://meta.discourse.org/u/kgish)\
**Post date:** [September 9, 2016, 10:56am UTC](https://meta.discourse.org/t/plugin-hook-using-a-private-repository/49923/3 "2016-09-09T10:56:48Z")

</div>

Sounds good! Can you please explain in more detail to a newbie?
