# Development

**URL:** https://meta.discourse.org/c/dev/7.md?page=127

[Latest](https://meta.discourse.org/latest.md) · [Categories](https://meta.discourse.org/categories.md) · [Tags](https://meta.discourse.org/tags.md)

**Page:** 128

---

## [Drupal 7 Migration Questions](https://meta.discourse.org/t/drupal-7-migration-questions/71539)

<div class="topic-metadata">

**Author:** [@j127](https://meta.discourse.org/u/j127)\
**Replies:** 8\
**Last updated:** [October 17, 2017, 7:29pm UTC](https://meta.discourse.org/t/drupal-7-migration-questions/71539 "2017-10-17T19:29:52Z")

</div>

Has anyone imported Drupal 7 passwords into Discourse? This is one area where I’m stuck on my migration. I found this plugin and this info, but am not sure how to modify it for Drupal 7. If I don’t migrate the password…

---

## [Example Code in PHP how to Create a new User](https://meta.discourse.org/t/example-code-in-php-how-to-create-a-new-user/72186)

<div class="topic-metadata">

**Author:** [@mertins-mir](https://meta.discourse.org/u/mertins-mir)\
**Replies:** 4\
**Last updated:** [October 16, 2017, 4:57pm UTC](https://meta.discourse.org/t/example-code-in-php-how-to-create-a-new-user/72186 "2017-10-16T16:57:17Z")

</div>

Hi all, I’ve got an existing User DB and I simply want to push the User into the discourse Forum. My programming language is PHP and I know how to use curl but are there any examples, how to push a new user into discour…

---

## [Discourse build is broken due to removed file?](https://meta.discourse.org/t/discourse-build-is-broken-due-to-removed-file/71925)

<div class="topic-metadata">

**Author:** [@Bas](https://meta.discourse.org/u/Bas)\
**Replies:** 11\
**Last updated:** [October 16, 2017, 12:38pm UTC](https://meta.discourse.org/t/discourse-build-is-broken-due-to-removed-file/71925 "2017-10-16T12:38:41Z")

</div>

Got an error when rebuilding (without any changes in app.yml): I, \[2017-10-12T10:23:27.710239 #13\] INFO -- : \> cd /var/www/discourse && chown -R discourse /var/www/discourse chown: cannot access '/var/www/discourse/con…

---

## [Is it possible to change HTML of header and footer and message details on the forum?](https://meta.discourse.org/t/is-it-possible-to-change-html-of-header-and-footer-and-message-details-on-the-forum/66756)

<div class="topic-metadata">

**Author:** [@klalex](https://meta.discourse.org/u/klalex)\
**Replies:** 8\
**Last updated:** [October 13, 2017, 7:09pm UTC](https://meta.discourse.org/t/is-it-possible-to-change-html-of-header-and-footer-and-message-details-on-the-forum/66756 "2017-10-13T19:09:38Z")

</div>

Is it possible to change HTML of header and footer and message details on the forum? I have a custom design that need to be implemented and customization features in admin looks very limited. Is it possible to use custom…

---

## [Approving an already-existing user through API?](https://meta.discourse.org/t/approving-an-already-existing-user-through-api/71998)

<div class="topic-metadata">

**Author:** [@Frank\_Bailey](https://meta.discourse.org/u/Frank_Bailey)\
**Replies:** 3\
**Last updated:** [October 13, 2017, 10:17am UTC](https://meta.discourse.org/t/approving-an-already-existing-user-through-api/71998 "2017-10-13T10:17:40Z")

</div>

I have created 17500 users via the Discourse API and uploaded all user avatars with the help of some very nice people here on Meta Discourse. All these users are in a “pending” state, and I would like to approve these u…

---

## [Sending emails without SMTP](https://meta.discourse.org/t/sending-emails-without-smtp/71816)

<div class="topic-metadata">

**Author:** [@simbul](https://meta.discourse.org/u/simbul)\
**Replies:** 5\
**Last updated:** [October 12, 2017, 1:04pm UTC](https://meta.discourse.org/t/sending-emails-without-smtp/71816 "2017-10-12T13:04:30Z")

</div>

Hi all. First post here :slight\_smile: We’re considering using Discourse in my company as it fits our requirements quite well. The only snag is that our preferred email platform is Salesforce Marketing Cloud (nee Exact…

---

## [API returning user ID of -1 when uploading avatar](https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784)

<div class="topic-metadata">

**Author:** [@Frank\_Bailey](https://meta.discourse.org/u/Frank_Bailey)\
**Replies:** 4\
**Last updated:** [October 11, 2017, 9:36am UTC](https://meta.discourse.org/t/api-returning-user-id-of-1-when-uploading-avatar/71784 "2017-10-11T09:36:45Z")

</div>

I’m trying to use the Dischord API to upload user avatars. I’m testing with Postman because I couldn’t get it working with curl in PHP. With Postman I can see that the POST to the API is actually succeeding, but that the…

---

## [Gitter integration for Discourse](https://meta.discourse.org/t/gitter-integration-for-discourse/65881)

<div class="topic-metadata">

**Author:** [@jafeth.diazc](https://meta.discourse.org/u/jafeth.diazc)\
**Replies:** 6\
**Last updated:** [October 11, 2017, 5:08am UTC](https://meta.discourse.org/t/gitter-integration-for-discourse/65881 "2017-10-11T05:08:47Z")

</div>

Hi all! I have been working on a Gitter integration for Discourse as an alternative service to the Slack plugin and I’d like to share the current state of it. It’s necessary to create a custom integration in each room …

---

## [Where are the instructions how to use the latest version of the widget plugin api](https://meta.discourse.org/t/where-are-the-instructions-how-to-use-the-latest-version-of-the-widget-plugin-api/71768)

<div class="topic-metadata">

**Author:** [@piratdavid](https://meta.discourse.org/u/piratdavid)\
**Replies:** 1\
**Last updated:** [October 10, 2017, 4:55pm UTC](https://meta.discourse.org/t/where-are-the-instructions-how-to-use-the-latest-version-of-the-widget-plugin-api/71768 "2017-10-10T16:55:53Z")

</div>

Hi, There’s a few things I can’t make out how to do in the later versions of the widget api. Before it was very convenient where one could just add ‘icon’, ‘label’, ‘href’ etc to for example a menu link. In particular I…

---

## [Uploading 17500 users and their avatars using PHP](https://meta.discourse.org/t/uploading-17500-users-and-their-avatars-using-php/71685)

<div class="topic-metadata">

**Author:** [@Frank\_Bailey](https://meta.discourse.org/u/Frank_Bailey)\
**Replies:** 9\
**Last updated:** [October 10, 2017, 3:56pm UTC](https://meta.discourse.org/t/uploading-17500-users-and-their-avatars-using-php/71685 "2017-10-10T15:56:50Z")

</div>

I have been tasked with moving a Ning community of 17500 users to Discourse. I have gotten the user adding part working using a modified version of the Discourse API for PHP from here https://github.com/communiteq/discou…

---

## [Docker\_dev image broken for users other than UID 1000](https://meta.discourse.org/t/docker-dev-image-broken-for-users-other-than-uid-1000/71694)

<div class="topic-metadata">

**Author:** [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Replies:** 6\
**Last updated:** [October 9, 2017, 11:07pm UTC](https://meta.discourse.org/t/docker-dev-image-broken-for-users-other-than-uid-1000/71694 "2017-10-09T23:07:10Z")

</div>

I saw recently that the docker\_dev image had been updated, and I was hoping that would solve the problems I’ve been having, but there’s some kind of permissions error: Migrating database... rake aborted! Errno::EACCES: …

---

## [Webhooks/Sidekiq issue on dev instance](https://meta.discourse.org/t/webhooks-sidekiq-issue-on-dev-instance/71129)

<div class="topic-metadata">

**Author:** [@jack2](https://meta.discourse.org/u/jack2)\
**Replies:** 18\
**Last updated:** [October 9, 2017, 2:46pm UTC](https://meta.discourse.org/t/webhooks-sidekiq-issue-on-dev-instance/71129 "2017-10-09T14:46:43Z")

</div>

I run 2 Discourse instances: a standard one (Docker) a dev one, behind a nginx proxy I’ve set up the same webhook on both instances. It works well from the standard instance, but not from the dev instance: the Ping…

---

## [How to get in touch with the project mentor](https://meta.discourse.org/t/how-to-get-in-touch-with-the-project-mentor/71637)

<div class="topic-metadata">

**Author:** [@Shreya\_Sharma1](https://meta.discourse.org/u/Shreya_Sharma1)\
**Replies:** 3\
**Last updated:** [October 9, 2017, 11:10am UTC](https://meta.discourse.org/t/how-to-get-in-touch-with-the-project-mentor/71637 "2017-10-09T11:10:56Z")

</div>

I am applying for Outreachy program this time. I need a little guidance so that I can start working on the projects I’ve selected. How to contact a mentor? Is there a mentor allotted to a project or do we need to find s…

---

## [Zero downtime rebuild discourse](https://meta.discourse.org/t/zero-downtime-rebuild-discourse/71618)

<div class="topic-metadata">

**Author:** [@eldy](https://meta.discourse.org/u/eldy)\
**Replies:** 2\
**Last updated:** [October 8, 2017, 1:53pm UTC](https://meta.discourse.org/t/zero-downtime-rebuild-discourse/71618 "2017-10-08T13:53:32Z")

</div>

I have to wait at least 5 min when I installed a plugin, I do it on a production server, means my site is affected, it will be down for 5 min for the rebuild. Anyway to achieve zero download deployment?

---

## [Outreachy Scholarship: Help/mentorship needed](https://meta.discourse.org/t/outreachy-scholarship-help-mentorship-needed/71599)

<div class="topic-metadata">

**Author:** [@mauditecandela](https://meta.discourse.org/u/mauditecandela)\
**Replies:** 2\
**Last updated:** [October 8, 2017, 10:04am UTC](https://meta.discourse.org/t/outreachy-scholarship-help-mentorship-needed/71599 "2017-10-08T10:04:41Z")

</div>

Hi everyone! My name is Candela and I am planning to apply for the Outreachy Scholarship. I was trying to do my first contribution and got a little bit stuck. :frowning: You can see my questions in the following link: I…

---

## [Discourse deployment using github or bitbucket?](https://meta.discourse.org/t/discourse-deployment-using-github-or-bitbucket/71579)

<div class="topic-metadata">

**Author:** [@eldy](https://meta.discourse.org/u/eldy)\
**Replies:** 8\
**Last updated:** [October 8, 2017, 9:47am UTC](https://meta.discourse.org/t/discourse-deployment-using-github-or-bitbucket/71579 "2017-10-08T09:47:12Z")

</div>

I think I’ve installed discourse wrongly. I simply do git clone into my server. If I want to modify the handlebar template like insert an ad, how do I do it now? I go into my server and cd to var/discourse, I can barely…

---

## [Postgresql install errors on Ubuntu 16.04](https://meta.discourse.org/t/postgresql-install-errors-on-ubuntu-16-04/70846)

<div class="topic-metadata">

**Author:** [@j127](https://meta.discourse.org/u/j127)\
**Replies:** 1\
**Last updated:** [October 8, 2017, 12:26am UTC](https://meta.discourse.org/t/postgresql-install-errors-on-ubuntu-16-04/70846 "2017-10-08T00:26:53Z")

</div>

While trying to install Discourse on my laptop (Ubuntu 16.04) using this guide, I got some errors like this: PG::InsufficientPrivilege: ERROR: permission denied to create extension "hstore" and: rails aborted! ActiveR…

---

## [Creating discourse user group with code](https://meta.discourse.org/t/creating-discourse-user-group-with-code/70228)

<div class="topic-metadata">

**Author:** [@Sudaraka](https://meta.discourse.org/u/Sudaraka)\
**Replies:** 3\
**Last updated:** [October 7, 2017, 1:34pm UTC](https://meta.discourse.org/t/creating-discourse-user-group-with-code/70228 "2017-10-07T13:34:45Z")

</div>

I need to create a discourse user group with my plugin. I used the below code and its not working. Any idea why its not working ? Thankyou default\_group = Group.new( name: 'Dumy', visibility\_level: Group…

---

## [What is the latest recommended workflow for local development? (Ubuntu 16.04)](https://meta.discourse.org/t/what-is-the-latest-recommended-workflow-for-local-development-ubuntu-16-04/71213)

<div class="topic-metadata">

**Author:** [@j127](https://meta.discourse.org/u/j127)\
**Replies:** 7\
**Last updated:** [October 6, 2017, 10:02pm UTC](https://meta.discourse.org/t/what-is-the-latest-recommended-workflow-for-local-development-ubuntu-16-04/71213 "2017-10-06T22:02:35Z")

</div>

I’ve been searching around for the ideal way to develop a discourse site on my laptop (Ubuntu 16.04), but am unsure about the most current best practices. I’m new to Rails and am having trouble figuring out how to setup …

---

## [How do to view rails errors?](https://meta.discourse.org/t/how-do-to-view-rails-errors/71477)

<div class="topic-metadata">

**Author:** [@iamphi](https://meta.discourse.org/u/iamphi)\
**Replies:** 6\
**Last updated:** [October 6, 2017, 5:49pm UTC](https://meta.discourse.org/t/how-do-to-view-rails-errors/71477 "2017-10-06T17:49:02Z")

</div>

I am writing a custom plugin to do redirects for my old vbulletin+vbseo forum urls. The import script doesn’t handle the url formats created by vbseo. I have a docker+discourse setup. I have created blank plugin with j…

---

## [User API only shows 3 badges](https://meta.discourse.org/t/user-api-only-shows-3-badges/71430)

<div class="topic-metadata">

**Author:** [@rodeezy](https://meta.discourse.org/u/rodeezy)\
**Replies:** 2\
**Last updated:** [October 5, 2017, 5:33pm UTC](https://meta.discourse.org/t/user-api-only-shows-3-badges/71430 "2017-10-05T17:33:46Z")

</div>

user\_bages endpoint does not work. In user api, only 3 of a user’s badges are shown. How can I receive all of a user’s badges?

---

## [How best to develop this frontend customization / plugin?](https://meta.discourse.org/t/how-best-to-develop-this-frontend-customization-plugin/71440)

<div class="topic-metadata">

**Author:** [@mcwumbly](https://meta.discourse.org/u/mcwumbly)\
**Replies:** 3\
**Last updated:** [October 5, 2017, 1:31pm UTC](https://meta.discourse.org/t/how-best-to-develop-this-frontend-customization-plugin/71440 "2017-10-05T13:31:45Z")

</div>

I’d like to experiment with a customization to change the UX for subscribing to topics. I’d love some pointers on how I might approach this. I’m pretty sure it’s doable as a front-end only customization. I’m unclear a…

---

## [Unable to update vagrant dev install on Windows](https://meta.discourse.org/t/unable-to-update-vagrant-dev-install-on-windows/64383)

<div class="topic-metadata">

**Author:** [@jomaxro](https://meta.discourse.org/u/jomaxro)\
**Replies:** 8\
**Last updated:** [October 2, 2017, 11:18pm UTC](https://meta.discourse.org/t/unable-to-update-vagrant-dev-install-on-windows/64383 "2017-10-02T23:18:31Z")

</div>

I’m getting the following error when attempting to update my dev install on Windows. I first did a git pull, then vagrant up, vagrant ssh, and finally bundle install. The error occurs when trying to run bundle exec rak…

---

## [When should Discourse upgrade to Rails 5?](https://meta.discourse.org/t/when-should-discourse-upgrade-to-rails-5/67123)

<div class="topic-metadata">

**Author:** [@gdpelican](https://meta.discourse.org/u/gdpelican)\
**Replies:** 48\
**Last updated:** [September 30, 2017, 12:23pm UTC](https://meta.discourse.org/t/when-should-discourse-upgrade-to-rails-5/67123 "2017-09-30T12:23:25Z")

</div>

Hey Discourse Team, This marks the 1-year-and-1-month anniversary of the Rails 5 release, it looks like 5.1.3 will be out soon (second release candidate lands today). Wondering if there have been any thoughts on upgradi…

---

## [Plugin - Get unseen topic count per tag](https://meta.discourse.org/t/plugin-get-unseen-topic-count-per-tag/70937)

<div class="topic-metadata">

**Author:** [@jack2](https://meta.discourse.org/u/jack2)\
**Replies:** 4\
**Last updated:** [September 29, 2017, 12:13pm UTC](https://meta.discourse.org/t/plugin-get-unseen-topic-count-per-tag/70937 "2017-09-29T12:13:13Z")

</div>

In my plugin, I would like to display the unseen topic count for each tag. I plan to implement this feature like this: Observe the topicTrackingState.messageCount property. Each time there’s a change, use the API to f…

---

## [Installing Plugins in Discourse Development Install](https://meta.discourse.org/t/installing-plugins-in-discourse-development-install/70902)

<div class="topic-metadata">

**Author:** [@hexa\_tech](https://meta.discourse.org/u/hexa_tech)\
**Replies:** 15\
**Last updated:** [September 29, 2017, 5:39am UTC](https://meta.discourse.org/t/installing-plugins-in-discourse-development-install/70902 "2017-09-29T05:39:39Z")

</div>

Hello All! I’m pretty new to Discourse. Could someone please give me some steps to installing plugins in the development install of Discourse? Would this be the same as the production methods? Thanks for the help! …

---

## [Trouble creating category in import script](https://meta.discourse.org/t/trouble-creating-category-in-import-script/64000)

<div class="topic-metadata">

**Author:** [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Replies:** 3\
**Last updated:** [September 28, 2017, 2:37am UTC](https://meta.discourse.org/t/trouble-creating-category-in-import-script/64000 "2017-09-28T02:37:12Z")

</div>

I’ve got an import script that was working. I changed databases that I was importing from. Now when I try to create a category, it fails, complaining about last\_post\_user\_id. The first line shows what I’m passing to cre…

---

## [No 'system' user. Is this bad?](https://meta.discourse.org/t/no-system-user-is-this-bad/70910)

<div class="topic-metadata">

**Author:** [@iamphi](https://meta.discourse.org/u/iamphi)\
**Replies:** 1\
**Last updated:** [September 28, 2017, 2:31am UTC](https://meta.discourse.org/t/no-system-user-is-this-bad/70910 "2017-09-28T02:31:00Z")

</div>

I am having trouble with importing like this case (Trouble creating category in import script) I noticed that the user table does not have a record for a ‘system’ user with id -1. Does this user need to exist in the db?…

---

## [How to avoid uploading attachments multiple times in a migration](https://meta.discourse.org/t/how-to-avoid-uploading-attachments-multiple-times-in-a-migration/70613)

<div class="topic-metadata">

**Author:** [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Replies:** 2\
**Last updated:** [September 25, 2017, 4:20pm UTC](https://meta.discourse.org/t/how-to-avoid-uploading-attachments-multiple-times-in-a-migration/70613 "2017-09-25T16:20:59Z")

</div>

The vbulletin importer currently includes only attachments that are included in \[attach\] tags in the text of the message. But sometimes there are attachments not included in the text, and they don’t get imported. I’ve f…

---

## [Importer SiteSettings recommendations](https://meta.discourse.org/t/importer-sitesettings-recommendations/70542)

<div class="topic-metadata">

**Author:** [@pfaffman](https://meta.discourse.org/u/pfaffman)\
**Replies:** 1\
**Last updated:** [September 24, 2017, 7:05am UTC](https://meta.discourse.org/t/importer-sitesettings-recommendations/70542 "2017-09-24T07:05:57Z")

</div>

I’ve done several imports recently and find it helpful to include these SiteSettings: SiteSetting.disable\_emails = true SiteSetting.login\_required = true SiteSetting.allow\_index\_in\_robots\_txt=false SiteS…

[Previous page](https://meta.discourse.org/c/dev/7.md?page=126)

[Next page](https://meta.discourse.org/c/dev/7.md?page=128)
