Quantcast
Channel: Discourse Meta - Latest topics
Viewing all 60279 articles
Browse latest View live

Nginx, nginx, and docker

0
0

Lee_Ars wrote:

Have been banging on converting my install to Docker all day, and I'm nearly done. However, I'm at kind of a configuration quandary with how to best arrange the layer cake of web servers.

Givens for this install:

  1. The (real) server runs varnish + nginx with multiple production web sites. Varnish is on port 80 reverse-proxying to nginx, and nginx itself listens on 443 for HTTPS traffic (since varnish doesn't do that—well, that's not quite true, but that's a whole other book).

  2. The server has a single public static IP, and nginx decides which web site to serve based wholly on on http request hostname (in other words, each nginx virtual host definition has its own unique server_name parameter).

  3. Varnish must remain listening on port 80, and nginx must remain listening on port 443. Yes, I know Discourse's preferred option is to use a CDN instead of Varnish, but varnish is required for other stuff and even bypassing it entirely with pipe in its vcl file still has it playing a reverse-proxy role. So, it's in the mix even if it's "off."

With those known, how best to pass traffic to Docker?

There appear to be two options:

A) Leave nginx active inside of docker, with a multi-step reverse proxy. The flow would be requester -> varnish -> nginx (real) -> nginx (docker) -> unicorn for HTTP and requester -> nginx (real) -> nginx (docker) -> unicorn for HTTPS.

B) Don't load nginx inside of docker—only run unicorn and open up port 3000 on docker. The flow then would be requester -> varnish -> nginx (real) -> unicorn for HTTP and requester -> nginx (real) -> unicorn for HTTPS.

Pros of A are that it's simpler to install and configure and maintain (and, as @sam has noted, it lets the Discourse devs fold in updated nginx configurations as part of the normal upgrade cycle).

Cons of A are the multiple reverse proxies. I'm not terribly concerned about performance, but I am a little concerned about having that many layers in the stack and having all the client request metadata survive the trip through. I don't know if it's bad or not, and that's a little scary.

Pros of B are that it makes client-side administration easier (for me, at least), and more importantly hacks a layer out of the cake.

Cons of B are that it gets...complicated. All of the locations referenced point at paths inside the docker container, which...er, actually, come to think of it, this isn't even going to work, is it? Because public and everything in it is inaccessible inside the docker container, right?

Could use some advice here. How are you guys typically rolling out docker in production? Do you just do the double-reverse-proxy thing? I mean, I can actually use varnish to push HTTP traffic bound for the right hostname past the production nginx and directly to docker nginx, but it won't help for HTTPS.

Posts: 4

Participants: 2

Read full topic


Would like a gamer theme

0
0

Hazard wrote:

I would like a dark theme created for my FPS forum. Would be happy to pay for it, some elements I would like there to be a background image, a better logo for the site, and transparent topic lists.

Link is www.fpstalk.com

PM me and we can talk!!

PS Discourse is awesome!

Posts: 4

Participants: 2

Read full topic

What about an easier styling/theming system?

0
0

Jeff Atwood wrote:

This would really just be a "CSS generator".

How about a page that has nice color selectors and then nicely named coloring categories, like:

  • Primary background color
  • Secondary background color
  • Tertiary background color
  • Primary text color
  • Secondary text color
  • Primary link color
  • Secondary link color
  • Button background
  • Button background hover
  • Button text
  • Button text hover
  • Last poster highlight color

It doesn't need to be super detailed or advanced or able to do everything. Let people choose the colors on that page, and then click "Generate Style" which outputs a CSS page on the pre-existing Style page which they can then apply.

Most of the hours of work in theming Discourse are "replace #fff with #333, replace link colors with orange, replace #333/other dark with #ccc/other light". Having a simple styling CSS generator would get us 80% of the way there, and then we would be able to just fine-tune the colors of things.

(this text belongs to @DanYouhon but I really wanted it here for discussion and could not wait, sorry Dan!)

Posts: 18

Participants: 10

Read full topic

Documentation Request: HTTPS on Discourse/Docker

0
0

Nick Caldwell wrote:

So I had big plans to tinker with my little test setup on Digital Ocean to force Discourse to serve purely with SSL, but I must admit defeat, mainly due to a bit of an energy deficit at this point. But I'd like to get my install usable and secure for more people, so I'd really like a step-by-step guide on enabling SSL in a Docker install.

There are already tutorials on setting up a self-signed cert on a DO Ubuntu droplet, so that stage could be readily duplicated or just pointed to. Maybe something on non-self-signed certs would be useful too.

I figure it's mostly a case of altering one of the yml config files, but it's the whole "do a regex to find a bit of a config file to override" part that spooks me a bit.

Hope this isn't unreasonable, but it's probably the only serious sticking point with Discourse on Docker right now.

Posts: 8

Participants: 6

Read full topic

How about making the forum index menu "sticky"?

0
0

Erlend Sogge Heggen wrote:

I like how the topic title is stuck into the sticky menu and scrolls down with as you browse through the posts of a topic.

I'd prefer the forum index working in a similar fashion, giving me direct access to the top menu, most importantly the "create topic" button:

Posts: 10

Participants: 8

Read full topic

Undelivered Mail Returned to Sender

0
0

Hazard wrote:

I keep receiving undelivered mail emails. First it was when I changed my email to my hosted account with namecheap that matched my .com address. Now when I send test emails I receive and Undelivered Mail error.

This is the mail system at host

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

That is what I am receiving, not sure if it is on Discourse's end or my hosts end. The forums send emails to everyone else fine, but when it tried to send one to itself it doesn't work. The forums themselves are hosted at www.discoursehosting.com. The email is hosted through Namecheap.

Posts: 4

Participants: 3

Read full topic

Smileys are ugly

0
0

Iwan Gabovitch wrote:

The smiley design smilewinkfrowningsmileyblush makes heavy use of gradients which makes them unreadable at their size and unpleasant to see. See popular social networks for smileys that work (flat or weak-gradient colors).

Freely, permissively licensed options include:

I will gladly provide the required resolution, although I don't know how to replace the entire selection of icon options (I don't know how much there is).

I'm being subjective of course.

Posts: 4

Participants: 3

Read full topic

Read-only mode please!

0
0

Michael Brown wrote:

Having a read-only mode would be great in a few situations:

  • failover to standby read-only database
  • migrations (set read-only, slurp data, restore, switch DNS)
  • upgrades (could upgrade and leave the old thins up and running safely)

Please add! I'll love you forever.

Posts: 15

Participants: 5

Read full topic


Option to show reply number (position) of replied posts

0
0

Leung Aaron wrote:

When there are many replies inside a topic, it will be hard to know which position of reply post for reference .

Now the reply number is shown when searching , but it doesn't show up in the topic flow.

I think it should be better to allow admin to have an option to turn on showing each reply numbers beneath the bottom or the sides in each reply.

Posts: 3

Participants: 2

Read full topic

Help upgrading discourse instance

0
0

Jonathan Sandlund wrote:

Hi,

I have Discourse (0.9.5) up and running at Digital Ocean, but I have no clue how to properly upgrade it. (Only know html, css and a little java.) I'm looking to hire someone to help me keep up to date on the latest Discourse versions.

If interested, can you send me a message with a quote for a single upgrade? (Cost to upgrade from 0.9.5 to 0.9.6.)

Many thanks!
J

Posts: 8

Participants: 5

Read full topic

Importing phpBB into Discourse

0
0

Claus Strasburger wrote:

Forking from Import posts from Facebook group into Discourse:

I used @Sander78's codebase to build a phpBB importer for discourse. Currently, it is a bit slow and does some text sanitizing as well as removal of bbcodes.
it does produce some weird results with nested [quote] tags and i haven't added all bbcodes yet.

https://github.com/cfstras/discourse-import-phpBB

Suggestions and patches are highly welcome!

Posts: 79

Participants: 20

Read full topic

So, you want to help out with Discourse

0
0

Sam Saffron wrote:

People are wondering, how it is they can help out with Discourse.

We have seen some chattering both here and on Github.

I wanted to create a topic @eviltrout , @codinghorror and myself can keep up to date with clear ideas of little projects that would immensely help Discourse.

Ruby projects

JavaScript projects

Mixed projects

  • Improve general polish.
  • Share a link to this post dialog should provide a short link option via goo.gl API
  • Editable onebox whitelist (including admin section) currently list of whitelisted urls for oneboxes are hardcoded, some forums may want to amend this.
  • Allow logged on users to associate additional login methods (eg: login with google, then add twitter)

CSS projects

  • CSS diet, see what can be done to cut down on the css rules we have and make it easier to theme Discourse, add classed where needed, eliminate very deep selectors

General stuff:

Fix your favorite bug listed either here: http://meta.discourse.org/category/bug or on Github


If you feel like working on any of the bigger bits, be sure to let us know by replying here. If you want us to add some stuff to the list let us know.

Posts: 31

Participants: 14

Read full topic

Importing bbPress into Discourse

Configure Discourse with Amazon SES, Mailjet or Mailchimp

0
0

Anderson Santos wrote:

Hi!
Could any of you guys give me some light about how to use one of those services to send email from Discourse?

Thanks!

Posts: 4

Participants: 4

Read full topic

Using Stripe for Members only Group and Category

0
0

Jason Wojo wrote:

We are going to have a category with permissions so that only users in a certain group can access a category or possibly a few categories over time. We are planning on using Stripe as the payment gateway to try and give the user a clean on-site experience. We also have a wordpress site connected so another option is to manage the sign up via WP using Gravity forms and Stripe so we can collect some user info.

My main concern is that the workflow could become cumbersome if the user has to enter information at too many steps. Most will want to use Google or Twitter for login, and I'm not sure how to manage this and the payment workflow and information capture so it is seamless and they don't have one process for registration and another for payment that doesn't feel connected.

Does anybody have advice on the best workflow. Hopefully we will do this as a plugin other users can also use.

Option 1:

  1. User goes to Discourse site
  2. User registers with Google account
  3. User has access to open portions of site now, but must pay to be added to the members group
  4. User is prompted to pay
  5. They complete payment using Stripe and land in the category that is exclusive to the members group

Option 2:

  1. User goes to Discourse site
  2. User is prompted to make payment and does so via Stripe.js
  3. After successful payment, user sees standard Discourse registration window and registers.

Option 3:

  1. User registers on Wordpress using Gravity forms and Stripe integration
  2. WP passes code in link or somehow shares info so that user registers with Google or Twitter and is added to members group.

On the last one, I'm not sure how to make that experience smooth so the user isn't registering twice basically.

Any thoughts ideas or other options I should look at?

Posts: 3

Participants: 3

Read full topic


Nickname collision

0
0

Larry Salibra wrote:

I'm working on setting up a new discourse instance and found that I can't use the same username @larry that I'm using on Meta even if I try to register with the same email.

Upon further investigation, it seems that there's already another user with the same nick: http://www.discourse.org/users/larry

Is this a bug? I was under the impression registering on Meta reserves your nickname...

Posts: 7

Participants: 4

Read full topic

Spam-blocking URL Blacklist

0
0

Lowell Heddings wrote:

This feature might already exist in the code somewhere, but it's probably worth mentioning as an admin feature.

Over the years on the old HTG forum, we've noticed that the same exact spammers come back and manually spam the same links, over and over and over. We've also been hit by automatic bots a few times, though I'm less worried about that with Discourse. It's really the manual spam that's just tedious and consistent.

It would be useful to have a URL blacklist for spammers. Possible ideas for discussion:

  • Automatically hide and flag posts that have a blacklisted URL, so moderators can check for actual users posting the link for some unknown reason.

  • Automatic and temporary ban if the link appears in the user's first post or they post the same blacklisted link more than once. Flag alerts the moderators, or not.

The real goal, of course, is to prevent spammers from wasting people's time, especially the moderators.

Posts: 8

Participants: 5

Read full topic

Improving import and export support

0
0

Sam Saffron wrote:

Prior to launch @neil spent a fair amount of time working on an import/export system for Discourse. It has significant advantages over a standard db backup.

  • It allows you to import a backup while the site is running
  • It has robust rollback in case anything goes wrong
  • It uses a single bundle which also contains uploads

Unfortunately we have not promoted this feature well enough and most Discourse site owners are not aware of its existence.

As we near version 1.0 I feel we need to refocus and "finish off" this feature. Here is a basic list of things that should be done prior to 1.0.

  • @codinghorror we need to decide on terminology, what are things called? Backup vs Export, Restore vs Import. We need clear terminology describing this feature.

  • We need an admin UI capable of:

    • Exporting / Backing up a site
    • Viewing available local backups
    • Download of available backups (to be expanded)
    • Removal of backup sets
    • Restore of external (uploaded) backups and local backups
    • Displaying progress and logs of the backup / restore operations
  • We need the backend to support restore from "earlier" backup sets, at the moment the site being restored must be the same version as the site that was backed up. This heavily limits the usage of this feature.

After version 1.0 of the feature we can consider

  • Scheduling backups using the admin UI
  • Scheduling uploads of backups to S3 or other external services.

Why this feature is so important

Today most VPSs have a built-in backup and restore function, this easily allows you to backup and restore locally, but ties you in very hard to the initial VPS you chose. What if you decide to move from Amazon to Digital Ocean and so forth? You are easily looking at a few hours of work figuring backup and restore out.

Having a "kick ass" backup/restore story gives the Discourse community flexibility to move to another server without needing expensive and complicated process. It also allows existing communities to easily migrate to our recommended docker setup.

This feature also heavily assists people extending Discourse as you can easily download copies of sites you are working on and use them locally.

In my proposed implementation there are 2 technical hurdles:

Securely downloading backups

Having a backup hanging around in a /public/ folder (even with a hash obfuscating it) is a big security hole. If anyone gets hold of the URL you are in trouble. So when dealing with downloading these potentially big files we have 3 options:

  1. Implement rack middleware that hijacks the connections and streams a file to an authenticated admin
  2. Implement http://wiki.nginx.org/XSendfile to send the files to authenticate users
  3. Less secure "obsfucated" timing out public link

For v1 I think we should implement 2 and 3, 2 being the default but configurable with site settings.

Where to run the job, getting progress

Backup and restore jobs can take a while to run. During this time we need to tell users "something is happening" and allow "cancel". If the job runs in the web worker, unicorn will go ahead and nuke it. If you run it with a background thread you may have trouble reaching it when the load balancer sends your status http call to another front end.

To resolve this we can either place sidekiq in a "single job" mode, kick the job to sidekiq and have it pump progress into the Message Bus. Or do the same thing in a background thread or forked process.

Personally, I would like backup and restore to work even if for whatever reason sidekiq is not running. It allows you to easily migrate off problem setups. My preference is either a fork like https://github.com/discourse/docker_manager/blob/master/lib/docker_manager/upgrader.rb#L49 or a background thread.

UI concerns

Once we get terminology sorted I would like a new tab for this functionality (only visible to admin)

It should display all the available backups and have a sub tab for logs (which are populated during backup / restore). We do not need an accurate progress bar with estimated completion time for v1. However we must clearly communicate that background job is running and disable all operations during this process.

We should not tell users to visit another tab (to move the site into maint mode) for a restore, instead simply present them with a bootbox. We should always keep a backup of "previous good" setup when doing a restore, in case someone makes a mistake and restores the wrong thing.


@zogstrip will be working on this feature.

Let us know if you have any feedback or need clarification.

Posts: 12

Participants: 6

Read full topic

Get a 404 error with onebox

0
0

Matthieu wrote:

Hi,

I have some trouble with the onebox feature. It works with a youtube video or a wikipedia article but for some link I get a 404 error.

For example:

Failed to load resource: the server responded with a status of 404 (Not Found) https://forum.poppy-project.org/onebox?url=http%3A%2F%2Fgfxspeak.com%2F2014%2F02%2F03%2Fbusiness-solidworks-mechanical-conceptual%2F&refresh=false

Failed to load resource: the server responded with a status of 404 (Not Found) https://forum.poppy-project.org/onebox?url=http%3A%2F%2Fwww.journaldugeek.c…2Fsmartphone-huawei-est-le-troisieme-constructeur-mondial%2F&refresh=false

How can I fix that ?

Thanks

Posts: 4

Participants: 3

Read full topic

Ellipsis on Email field on profile is inconvenient

0
0

Patrick Klug wrote:

It would be great if the Email field on profiles (visible to Admins) doesn't use ellipsis to shorten text.

Posts: 3

Participants: 2

Read full topic

Viewing all 60279 articles
Browse latest View live




Latest Images