Commit Graph

97 Commits

Author SHA1 Message Date
dependabot[bot] 5897ef7cab
Bump github.com/writeas/import from 0.2.0 to 0.2.1
Bumps [github.com/writeas/import](https://github.com/writeas/import) from 0.2.0 to 0.2.1.
- [Release notes](https://github.com/writeas/import/releases)
- [Commits](https://github.com/writeas/import/compare/v0.2.0...v0.2.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:26 +00:00
dependabot[bot] 99b2f41aa1
Bump github.com/go-sql-driver/mysql from 1.4.1 to 1.5.0
Bumps [github.com/go-sql-driver/mysql](https://github.com/go-sql-driver/mysql) from 1.4.1 to 1.5.0.
- [Release notes](https://github.com/go-sql-driver/mysql/releases)
- [Changelog](https://github.com/go-sql-driver/mysql/blob/master/CHANGELOG.md)
- [Commits](https://github.com/go-sql-driver/mysql/compare/v1.4.1...v1.5.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:24 +00:00
dependabot[bot] 94094ed16d
Bump github.com/guregu/null
Bumps [github.com/guregu/null](https://github.com/guregu/null) from 3.4.0+incompatible to 3.5.0+incompatible.
- [Release notes](https://github.com/guregu/null/releases)
- [Commits](https://github.com/guregu/null/compare/v3.4.0...v3.5.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:19 +00:00
dependabot[bot] f278eccd14
Bump gopkg.in/ini.v1 from 1.55.0 to 1.57.0
Bumps [gopkg.in/ini.v1](https://github.com/go-ini/ini) from 1.55.0 to 1.57.0.
- [Release notes](https://github.com/go-ini/ini/releases)
- [Commits](https://github.com/go-ini/ini/compare/v1.55.0...v1.57.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:13 +00:00
dependabot[bot] 267c9df1c4
Bump github.com/stretchr/testify from 1.6.0 to 1.6.1
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.0 to 1.6.1.
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.6.0...v1.6.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:06 +00:00
dependabot[bot] b569144624
Bump github.com/microcosm-cc/bluemonday from 1.0.2 to 1.0.3
Bumps [github.com/microcosm-cc/bluemonday](https://github.com/microcosm-cc/bluemonday) from 1.0.2 to 1.0.3.
- [Release notes](https://github.com/microcosm-cc/bluemonday/releases)
- [Commits](https://github.com/microcosm-cc/bluemonday/compare/v1.0.2...v1.0.3)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:01:01 +00:00
dependabot[bot] 3d80b46bdc
Bump github.com/hashicorp/go-multierror from 1.0.0 to 1.1.0
Bumps [github.com/hashicorp/go-multierror](https://github.com/hashicorp/go-multierror) from 1.0.0 to 1.1.0.
- [Release notes](https://github.com/hashicorp/go-multierror/releases)
- [Commits](https://github.com/hashicorp/go-multierror/compare/v1.0.0...v1.1.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:00:57 +00:00
dependabot[bot] cfaaffdc6c
Bump github.com/gorilla/feeds from 1.1.0 to 1.1.1
Bumps [github.com/gorilla/feeds](https://github.com/gorilla/feeds) from 1.1.0 to 1.1.1.
- [Release notes](https://github.com/gorilla/feeds/releases)
- [Commits](https://github.com/gorilla/feeds/compare/v1.1.0...v1.1.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-07-28 16:00:55 +00:00
Matt Baer 6dbc753ecb Merge branch 'develop' into gopher 2020-07-23 11:47:49 -04:00
Matt Baer 1451fc1369 Use latest version of go-gopher library 2020-07-23 11:46:00 -04:00
Matt Baer dc7b5df90e Update saturday library to support number+letter hashtags
Previously, a hashtag like #100DaysToOffload wouldn't automatically turn
into a clickable link. This fixes that by updating to the latest version
of the satuday library.
2020-04-28 10:50:51 -04:00
Matt Baer 0c6d3e45e4 Update Go modules 2020-04-21 13:04:19 -04:00
Matt Baer 9f1dd7a138 Use latest writeas/activityserve library
This fixes a 500 error / panic caused by ActivityPub actors without an
`inbox` or `outbox` attribute.
2020-04-09 13:00:29 -04:00
Matt Baer d6cb178eb6 Use writeas/impart v1.1.1
This doesn't change the actual underlying dependency; it simply uses the
current, most recent tag for the impart library.
2020-03-28 13:30:44 -04:00
Nick Gerakines 048e8a5e13
Added error messaging when user attempts to attach a slack account to a user that already has the slack account attached. Added GitLab to settings page as oauth option. 2020-03-20 18:07:35 -04:00
Matt Baer 6aa8de3a4b Add Gopher support
This adds gopher support to WriteFreely -- both single- and multi-user
instances. It is off by default, but can be enabled with the new
`gopher_port` config value in the `[server]` section.

When enabled, multi-user instances will show all public blogs at
gopher://[host]:[gopher_port]/ -- otherwise, blogs are accessible at
gopher://[host]:[gopher_port]/[blog]/

This is just a proof of concept for now. We still need to handle some
edge cases and different configurations, like private instances.

Ref T559
2020-03-01 20:12:47 -05:00
Matti R b0f0de3dde
go mod tidy 2020-02-10 01:57:57 -05:00
Matti R 6173405794
switch to use urfave/cli for cli, which allows for auto-manpage generation and bash complete 2020-02-10 01:46:58 -05:00
Matt Baer 42467fc9c1 Merge branch 'develop' into acme-v2 2020-02-09 13:32:45 -05:00
Matt Baer 68d63d3fef Merge branch 'develop' into activitypub-mentions 2020-02-08 11:51:18 -05:00
Matt Baer fec0eb2a0b
Merge pull request #251 from writeas/fix-memory-leak
Fix memory leak
2020-02-05 16:04:45 +01:00
Matt Baer 6e36868e92
Merge pull request #239 from techknowlogick/switch-xgo
Switch to a maintained fork of XGO
2020-02-05 14:56:22 +01:00
Matti R 0ed3059bd7
add xgo to go mod 2020-01-31 16:34:36 -05:00
Matt Baer 8fce34b70b Tidy up Go mod files 2020-01-29 05:24:22 -05:00
Matt Baer ae1a892be0 Upgrade gorilla/sessions to v1.2.0
This gets rid of the gorilla/context dependency, which might have been
causing a memory leak.

We noticed some serious memory leakage on Write.as that seemed to point
to this library. One heap snapshot:

      flat  flat%   sum%        cum   cum%
  259.13MB 30.41% 30.41%   268.13MB 31.46%  net/textproto.(*Reader).ReadMIMEHeader
  105.71MB 12.40% 42.81%   105.71MB 12.40%  github.com/gorilla/context.Set
   78.53MB  9.21% 52.03%   125.53MB 14.73%  github.com/gorilla/sessions.(*Registry).Get
   55.51MB  6.51% 58.54%    82.52MB  9.68%  net/http.(*Request).WithContext
   38.01MB  4.46% 63.00%    38.01MB  4.46%  github.com/gorilla/mux.extractVars
      35MB  4.11% 67.11%       53MB  6.22%  context.WithCancel
   34.50MB  4.05% 71.16%    34.50MB  4.05%  context.WithValue
      27MB  3.17% 74.32%       27MB  3.17%  net/http.cloneURL
      26MB  3.05% 77.38%       26MB  3.05%  github.com/gorilla/sessions.NewSession
      18MB  2.11% 79.49%       18MB  2.11%  context.(*cancelCtx).Done
   16.50MB  1.94% 81.42%    16.50MB  1.94%  syscall.anyToSockaddr
      14MB  1.64% 83.07%       47MB  5.52%  github.com/gorilla/sessions.(*CookieStore).New
   13.50MB  1.58% 84.65%    51.51MB  6.04%  github.com/gorilla/mux.(*Route).Match
   11.67MB  1.37% 86.02%    13.21MB  1.55%  regexp.(*Regexp).replaceAll
    9.72MB  1.14% 87.16%    22.94MB  2.69%  regexp.(*Regexp).ReplaceAllString
    9.50MB  1.11% 88.28%   115.21MB 13.52%  github.com/gorilla/sessions.GetRegistry

With the help of these articles, we tracked it down to this dependency,
and upgraded the library, which seems to have completely fixed the issue
so far:

https://rover.rocks/golang-memory-leak/
https://medium.com/@walterwu_22843/golang-memory-leak-while-handling-huge-amount-of-http-request-35cc970cb75e

This should fix #133
2020-01-29 04:56:23 -05:00
Matti R 80cffbb3ec
update golang.org/x/crypto vendor to use acme v2
also run go mod tidy to clean up module files
2020-01-14 12:46:52 -05:00
Matt Baer be76f865a4 Merge branch 'develop' into import-text 2020-01-07 16:35:23 -05:00
Nick Gerakines 2aea9560bc Merged T710-oauth-slack into oauth-wrapper. 2020-01-02 16:19:26 -05:00
Matt Baer af23e28d05 Pass OAuth requests through new OAuth handler
This gives us our standard logging and passes around errors with
impart.HTTPError.

Ref T705
2019-12-30 18:14:01 -05:00
Nick Gerakines 13121cb266 Merging T705-oauth into T710-oauth-slack. T705,T710 2019-12-27 13:40:11 -05:00
Nick Gerakines bf3b6a5ba0 Unit tests, integration testing, and code cleanup for oauth support. Part of T705. 2019-12-23 14:30:32 -05:00
Nick Gerakines 7a0863f71b Added oauth handlers and tests with mocks. Part of T705. 2019-12-19 11:51:19 -05:00
Matt Baer 181af8c5c8 Update httpsig and activityserve
This fixes activityserve crashes caused by mentioning WriteFreely
instances.
2019-11-27 16:37:52 -05:00
Matt Baer af6e5dea3a Merge branch 'develop' into import-text 2019-11-26 17:41:29 -05:00
Matt Baer d8df15855c Merge branch 'develop' into activitypub-mentions 2019-11-26 13:19:20 -05:00
Matt Baer d4206cd5f8 Move to web-core v1.2.0 2019-11-11 23:19:34 +09:00
Michael Demetriou 972ec00c58 Update dependencies and add a comment 2019-10-11 10:33:51 +03:00
Michael Demetriou dccfae7a61 Mentioning pleroma accounts works! Mastodon still needs the type to b
be Note to work but I will open an issue for them and see what their
reaction will be.
2019-10-08 15:58:19 +03:00
Rob Loranger feba200916
remove gogs/gogs/pkg/tool dependency
this borrows some code from github.com/gogs/gogs/pkg/tool to avoid
pulling it in as a dependency, along with many other indirect deps.
2019-09-11 12:50:04 -07:00
Rob Loranger d9bf8ab6cc
update to wfimport v0.2.0
now checking for and returning invalid content type errors
2019-08-26 14:53:05 -07:00
Rob Loranger 42a2219335
add ui back to target release linux 2019-08-22 10:48:58 -07:00
Rob Loranger cbc9c6725a
include imported created time
this updates to parse the time from the imported file, using v0.1.1 of
the wfimport library
2019-08-21 14:43:05 -07:00
Rob Loranger ee4fe2f4ad
add basic text file imports
this adds basic support for importing files as blog posts.

.txt and .md are supported at this time and the
collection is selectable, defaulting to draft.

if a collection is specified the post is federated.
2019-08-16 14:27:24 -07:00
Matt Baer 41062728f5 Fix go-sitemap-generator overriding GOMAXPROCs
This upgrades the library to v2, which lets you specify that GOMAXPROCs
should always be the max number of CPUs -- and then sets it to that.

One side effect of this is that images are no longer listed in sitemaps.
I'm somehow at a loss on how to build and append the images array we
need, with the library's latest changes.

Fixes #86
2019-07-20 19:47:13 -04:00
Rob Loranger 6ff136455c
Add go-bindata as a module dependency
This adds https://github.com/jteeuwen/go-bindata as a module dependency
as the make target 'build' will result in it's addition.
2019-05-17 16:22:44 -07:00
Matt Baer 07ab0cdb9c Add `invites` flag in NodeInfo
This indicates whether or not invites are enabled on this instance. It
requires an upgrade to writefreely/go-nodeinfo v1.2.0
2019-04-11 20:37:01 -04:00
Matt Baer 2cee0dee2a Support Go modules 2019-02-11 10:30:31 -05:00