Commit Graph
53 Commits
Author SHA1 Message Date
Michael Brown 8959b43c17 FIX: reword generic site policy defaults (#19359)
Reword the default Terms of Service and Privacy Policy to more strongly
denote they are templates which must be customised by the forum admin.
2023-01-31 10:23:24 +01:00
Michael Brown 8bec4e1db9 FIX: remove link to site with inappropriate content
As reported on https://meta.discourse.org/t/253028, the linked site includes
language which we do not support.
2023-01-26 16:34:23 -05:00
Michael Brownandjbrw 618fb5b34d FIX: properly count DistributedMutex locking attempts
When originally introduced, `attempts` was only used in the read-only check
context.

With the introduction of the exponential backoff in cda370db, `attempts` was
also used to count loop iterations, but was left inside the if block instead of
being incremented every loop, meaning the exponential backoff was only
happening when the site was recently readonly.

Co-authored-by: jbrw <jamie.wilson@discourse.org>
2022-12-13 17:27:13 -05:00
Michael Brown 02bfac1538 FIX: do not provide advice regarding GDPR compliance (#19358) 2022-12-08 08:37:53 +08:00
Michael Brown beda4708f6 FIX: 99999 is not a valid TCP port
Future versions of redis will validate this port number causing the tests
relying on this to fail with:

```
Redis::CommandError:
ERR Invalid master port
```

Also change from an IPv4 address that might feasibly be in use to an IPv6
random ULA address that almost *certainly* won't be.
2022-06-21 14:55:19 -04:00
Michael Brown a312b9ae88 FIX: ReplyByEmailAddressValidator should leverage EmailAddressValidator
Since we already have perfectly sensible logic for validating email addresses,
let's leverage that and simplify the logic while we're at it.

Emails with spaces are no longer permitted (why were they?)
2022-02-17 21:49:22 -05:00
Michael Brown 3bf3b9a4a5 DEV: pull email address validation out to a new EmailAddressValidator
We validate the *format* of email addresses in many places with a match against
a regex, often with very slightly different syntax.

Adding a separate EmailAddressValidator simplifies the code in a few spots and
feels cleaner.

Deprecated the old location in case someone is using it in a plugin.

No functionality change is in this commit.

Note: the regex used at the moment does not support using address literals, e.g.:
* localpart@[192.168.0.1]
* localpart@[2001:db8::1]
2022-02-17 21:49:22 -05:00
Michael Brown 23d7fcf9a1 FIX: remove duplicated word from client strings 2022-01-27 14:03:45 -05:00
Michael Brown 784e929499 upload_creator: force ImageMagick to use internal SVG code to determine size
This change largely targets dev users, but it could potentially change
behaviour in production.

Jamie Wilson & I debugged a problem where "should not be larger than the
maximum thumbnail size" would fail due to timeouts.

On our systems, on ImageMagick 7.1.0-2, with inkscape installed, IM would
attempt to rasterise the svg then check the resulting filesize, causing the
test to timeout.

As of now, we haven't found a way to cause this to behave better, but have a
workaround in that forcing IM to use the internal renderer (`MSVG:`) seems to
make it perform the same on development workstations as it does in our docker
container.
2021-07-19 22:03:57 -04:00
Michael Brown 76a11e6dc9 DEV: fix test (missed a reference to master) 2021-07-19 12:47:45 -04:00
Michael Brown aa12d12c0b discourse/discourse change from 'master' to 'main': update fixture data 2021-07-19 11:46:15 -04:00
Michael Brown 5f7e60d9dc discourse/discourse change from 'master' to 'main' 2021-07-19 11:46:15 -04:00
Michael Brown dda1cd6a38 FEATURE: allow setting postgres connection variables via environment 2021-04-14 13:31:32 -04:00
Michael Brown e63a9facc7 UI: remove extra word from approval_not_required client string (#11627) 2021-01-08 12:59:23 +11:00
Michael Brown 2275d637e4 DEV: the referenced commit bc97… was rebased into 445d… (#11626) 2021-01-07 08:14:54 +11:00
Michael Brown c25dc43f54 FIX: AWS S3 errors don't necessarily include a message
* If the error doesn't have a message, the class name will help
* example:
  before: "Failed to download #{filename} because "
  after: "Failed to download #{filename} because Aws::S3::Errors::NotFound"
2020-08-12 17:00:09 -04:00
Michael Brown c8370b9c78 DEV: remove objects that do not exist in the repo from .git-blame-ignore-revs (#9904)
* a freshly cloned repo does not have these objects
2020-05-28 12:31:00 +10:00
Michael Brown d9a02d1336 Revert "Revert "Merge branch 'master' of https://github.com/discourse/discourse""
This reverts commit 20780a1eee.

* SECURITY: re-adds accidentally reverted commit:
  03d26cd6: ensure embed_url contains valid http(s) uri
* when the merge commit e62a85cf was reverted, git chose the 2660c2e2 parent to land on
  instead of the 03d26cd6 parent (which contains security fixes)
2020-05-23 00:56:13 -04:00
Michael Brown 9026c55fe4 FIX: custom SQL with a trailing comment might break BadgeGranter SQL (#9285)
For example given a custom badge with SQL:
```
SELECT 1
-- I am a comment
```

You end up with

```
FROM (SELECT 1
-- I am a comment) q
```

This fix adds newlines so you end up with the now-valid:

```
FROM (
  SELECT 1
-- I am a comment
) q
```
2020-03-27 14:16:14 -04:00
Michael Brown 74acbad505 FIX: don't break the private key when writing it out during theme import
* when importing a private theme using the themes:install rake task the SSH key is written out to a file for use by the git-clone command
* if the private key is written out without a newline at end-of-file (i.e. after it's been stripped) it's not recognized as a valid key by SSH
* so: don't strip it when writing it out, we should be fine
2020-03-10 13:20:11 -04:00
Michael Brown 904bbdb307 DOCS: Clarify what a DNS "A record" is with a link
* context: https://meta.discourse.org/t/-/141250/6
2020-02-12 16:50:56 -05:00
Michael Brown 08b286808a FIX: backups taken by pg_dump >= 11 are nonportable (#7893) 2019-07-15 18:07:44 -04:00
Michael Brown 313130a7fc Ghetto script to test if email settings work 2014-04-15 23:50:15 -04:00
Michael Brown 8bd7dbfc3e Merge branch 'ubuntu-install-notes' of github.com:bloomberg/discourse into sysadmin-docs
Conflicts:
	docs/INSTALL-ubuntu.md
2014-01-21 01:39:46 -05:00
Michael Brown f24a12967c Fix RVM install instructions
* leave what RVM put into ~/.bash_profile - it now calls ~/.profile
2014-01-10 23:05:42 -05:00
Michael Brown 6f25549668 Add process checks to kill/restart too large thins 2013-09-30 15:17:59 -04:00
Michael Brown 95c246e257 Add section for additional MIME in nginx 2013-08-16 11:49:50 -04:00
Michael Brown 8c679f4b22 Add tip for installing on Ubuntu 12.10 2013-08-16 11:49:50 -04:00
Michael Brown 1c0d55782d Add GNU screen configuration file for vagrant love 2013-08-07 00:11:38 -04:00
Michael Brown 08e41a707d Update documentation
* Change recommendation for install path to /var/www/discourse
* Fix instructions for redis-server installation
* Set yourself as system user during install
* Clarify some instructions
2013-08-07 00:06:40 -04:00
Michael Brown ddabc476bf Awesome documentation updates 2013-07-21 03:43:54 -04:00
Michael Brown 6dc5659fed docs: fix ugly linebreak issues in INSTALL-email 2013-06-26 01:22:11 -04:00
Michael Brown ecb3858283 docs: add warning to NOT use gmail for outgoing 2013-06-24 04:16:33 -04:00
Michael Brown ffba090fb7 docs: Add note on where to put local assets 2013-06-24 04:16:33 -04:00
Michael Brown c2e1e553bf docs: create configuration steps for mail 2013-06-24 04:16:25 -04:00
Michael Brown 836ebbaa8e Comment out example anti-hotlinking rules 2013-06-20 22:49:04 -04:00
Michael Brown d80b33c290 Disable log rotation for now 2013-06-18 03:05:12 -04:00
Michael Brown b0d676f2f2 fixes in logrotate.conf 2013-06-18 03:04:01 -04:00
Michael Brown 70be638f47 Update sample bluepill config and install docs 2013-06-18 02:28:30 -04:00
Michael Brown a908f00771 Documentation update: work in progress 2013-06-15 01:25:41 -04:00
Michael Brown f3fb10de03 settings: Update english description of entropy 2013-06-07 15:07:43 -04:00
Michael Brown bb77d2c38b More entropy for foreign titles
* Treat strings with non-ASCII characters as having more entropy
2013-06-07 14:47:07 -04:00
Michael Brown e53cd0b083 documentation: further improvements and TESTING! 2013-06-06 04:58:39 -04:00
Michael Brown fa965b5f92 installdocs: Update with screenshots & more
* add screenshots from Ubuntu config process
* add instructions for updating predeployed VMs
* add details on configuring mail server
* don't install test gems into prod
* no need for bundle exec
* small cleanups
2013-06-05 03:33:20 -04:00
Michael Brown 73d6014d10 documentation: merge & adapt suggestions from baus 2013-05-29 00:07:26 -04:00
Michael Brown 7fee7361c7 documentation: add instructions on updating 2013-05-28 17:46:55 -04:00
Michael Brown 17a09b5b70 Add hint on how to rebake posts 2013-05-25 00:16:43 -04:00
Michael Brown 6257c48613 Updated documentation
* added RVM option for single-user install
* clarified Web Server options
* bluepill sample config: create socket directory if it doesn't exist
* add multisite.yml.production-sample
* rename production.sample.rb (OCD)
* make two database.yml samples (one for dev, one for prod)
* fixed travis build (database.yml.sample renamed)
* fix other references to database.yml.sample
* clean up 'rvm requirements' instructions as per @mpapis
2013-05-25 00:07:45 -04:00
Michael Brown 85e6151542 install notes: pull down latest release 2013-05-21 23:02:38 -04:00
Michael Brown 49f56964ce Further modifications to installation instructions 2013-05-21 09:40:42 -04:00
Michael Brown f867bd8509 Tweaks to installation documentation 2013-05-21 09:40:42 -04:00
Michael Brown bda5fc6596 Add Ubuntu installation guide 2013-05-21 09:40:42 -04:00
Michael Brown 132ee8a8e2 message_bus: support ps on FreeBSD 2013-05-01 14:29:57 -04:00