Commit Graph

160 Commits (main)

Author SHA1 Message Date
Elliot Chen bee6f278ba
fix: the same-storage check in the new `pre-sign` feature (#2860)
* fix: error check for the same oss-storage

* fix: conflict error2 variable in code refactor in s3.go

* chore: rename endpointUrl to endpointURL
1 year ago
Steven a16bde23f7 chore: tweak variable name 1 year ago
Aleksandr Baryshnikov fa17dce046
feat: pre-signed URL for S3 storage (#2855)
Adds automatically background refresh of all external links if they are belongs to the current blob (S3) storage. The feature is disabled by default in order to keep backward compatibility.

The background go-routine spawns once during startup and periodically signs and updates external links if that links belongs to current S3 storage.

The original idea was to sign external links on-demand, however, with current architecture it will require duplicated code in plenty of places. If do it, the changes will be quite invasive and in the end pointless: I believe, the architecture will be eventually updated to give more scalable way for pluggable storage. For example - Upload/Download interface without hard dependency on external link. There are stubs already, but I don't feel confident enough to change significant part of the application architecture.
1 year ago
Steven af646ce2de refactor: move gomark 1 year ago
Steven 55ecdae509 chore: fix auto link matcher 1 year ago
Steven 11dd23f59b chore: tweak link checks 1 year ago
Steven 309fab222e chore: implement nested blockquote 1 year ago
Steven 932f636d84 chore: update codeblock renderer 1 year ago
Steven 10d709c167 chore: fix highlight cursor 1 year ago
Steven e1977df14b chore: remove check underscores 1 year ago
Mudkip f654d3c90e
fix: encode filename when using url prefix for resources (#2829)
* fix: encode filename when using url prefix for resources

* fix: only encode the last parts of filename

* fix: encode all parts in filepath
1 year ago
Steven a316e239ce chore: implement referenced content node 1 year ago
Steven d7f02b94e5 chore: fix linter 1 year ago
Steven d165d87288 refactor: markdown parser matchers 1 year ago
Steven a620d140c5 chore: update embedded content renderers 2 years ago
Steven 89d940d9b7 feat: implement params field for embedded content node 2 years ago
Steven afe75fd9f2 chore: fix tokens split tests 2 years ago
Steven 8a34013558 feat: implement embedded memo renderer 2 years ago
Steven 7236552b6c feat: implement subscript and superscript parsers 2 years ago
Steven 7de3de5610 chore: fix go test warning 2 years ago
Steven 2856e66609 chore: fix go test 2 years ago
Steven 8ed827cd2d chore: update table node delimiter 2 years ago
Steven aecffe3402 feat: implement table parser 2 years ago
Steven 3f4b361fad feat: implement highlight parser 2 years ago
Steven fdbf2d8af2 chore: fix blockquote renderer 2 years ago
Steven 98762be1e5 feat: implement indent for list nodes 2 years ago
Steven 32d02ba022 chore: fix horizontal rule matcher 2 years ago
Steven 5449342016 fix: auto link converters 2 years ago
Steven ee13927607 chore: fix restore tag node 2 years ago
Steven ce2d37b90c chore: fix find sibling node 2 years ago
Steven 454cd4e24f feat: implement switchable task list node 2 years ago
Steven d7ed59581c chore: fix math block matcher 2 years ago
Steven d12a2b0c38 feat: implement math expression parser 2 years ago
Wen Sun 6b2eec86c2
fix: image upload failed with cloudflare R2 (#2704)
Fix image upload failed with cloudflare R2
2 years ago
Lincoln Nogueira 14b34edca3
chore: fix misuse of package path instead of filepath.path (#2684)
As stated by https://pkg.go.dev/path, "path" is mainly for URLs, "path.filepath" for file systems
2 years ago
Steven 46f7cffc7b feat: implement restore nodes 2 years ago
Steven 2a6f054876 chore: update auto link parser 2 years ago
Steven c8d7f93dca feat: implement auto link parser 2 years ago
Steven 28c0549705 feat: add markdown service 2 years ago
Steven bb42042db4 chore: implement task list parser 2 years ago
Steven e8ca2ea5a0 chore: rename renderer package 2 years ago
Steven e43a445c34 chore: implement escaping character node 2 years ago
Steven 1237643028 chore: update parser tests 2 years ago
Steven aee0e31b0a chore: update parser functions 2 years ago
Steven 47af632c79 chore: update inline parser 2 years ago
Steven 7b0ceee57b chore: update memo metadata description 2 years ago
Steven bdc867d153 fix: heading render 2 years ago
Steven 6421fbc68a chore: implement list html render 2 years ago
Steven b00443c222 chore: implement list nodes 2 years ago
Steven 6763dab4e5 chore: handle newline in block parsers 2 years ago
Steven 242f64fa8e chore: implement html render 2 years ago
Steven 3edce174d6 chore: remove unused methods 2 years ago
Steven 5266a62685 chore: implement html renderer 2 years ago
Steven 43ef9eaced chore: implement part of html renderer 2 years ago
Steven 453707d18c feat: implement gomark parsers 2 years ago
Steven b20e0097cf chore: implement part of nodes 2 years ago
Steven dd83782522 chore: add line break node 2 years ago
Steven aa3632e2ac chore: implement gomark skeleton 2 years ago
Steven bc965f6afa chore: implement webhook dispatch in api v1 2 years ago
Steven 436eb0e591 chore: tweak s3 comments 2 years ago
Hou Xiaoxuan e016244aba
fix: remove ACL when set URLPrefix (#2532) 2 years ago
Steven 5b3af827e1 chore: move common packages to internal 2 years ago
victorsch 97b434722c
fix: content sanitization in getimage endpoint (#2241) 2 years ago
Steven cd0ea6558d chore: update golangci-lint config 2 years ago
Athurg Gooth 626ff5e3a7
feat: notify by telegram while new memo create by HTTP (#2215)
* Inject telegram bot into API service

* Add support for send telegram message

* Send notification by telegram while new memo post
2 years ago
Athurg Gooth 9987337eca
fix: all ID from int to int64 to avoid 32bits machine break (#2191)
Fix all ID from int to int64 to avoid 32bits machine break
2 years ago
boojack a5b3fb2a6a
chore: move cron package to internal (#2180) 2 years ago
boojack ad1822d308
chore: update db utils (#2177) 2 years ago
YuNing Chen 409d686f7d
chore: minor cleanup (#2124) 2 years ago
boojack 723c444910
chore: update server tests (#2118) 2 years ago
Alexandr Tumaykin c5a1f4c839
feat: format message from telegram and upload attachments (#1924)
* feat: format message from telegram and download documents

* fix: remove bool in expression

* refactor: convert to markdown

* refactor: resolve remarks and add support new message types

* refactor: resolve remarks

* feat: add test for mime type

---------

Co-authored-by: Александр Тумайкин <AATumaykin@tsum.ru>
2 years ago
Athurg Gooth 4d59689126
feat: set memo visibility in telegram (#1824)
* Add telegram.Bot in MessageHandler

* Change single message handler like group messages

* Move message notify wrapper from plugin to server

* Add keyboard buttons on Telegram reply message

* Add support to telegram CallbackQuery update

* Set visibility in callbackQuery

* Change original reply message after callbackQuery

---------

Co-authored-by: Athurg Feng <athurg@gooth.org>
2 years ago
Athurg Gooth c27c6cea13
fix: failed to upload OSS with S3 SDK (#1792)
Fix failed to upload OSS with S3 SDK

Co-authored-by: Athurg Feng <athurg@gooth.org>
2 years ago
Athurg Gooth 845297ec03
refactor: change all `Robot` to `Bot` (#1767)
* Change all `Robot` to `Bot`

* Change all `r` of `Bot` to `b`

* Change `Robot` to `bot` in comments

* Fix typo

---------

Co-authored-by: Athurg Feng <athurg@gooth.org>
2 years ago
Athurg Gooth ce64894abe
feat: add telegram proxy support (#1764)
* Add support for reverse proxy of telegram API

* Add Telegram API proxy hint

---------

Co-authored-by: Athurg Feng <athurg@gooth.org>
2 years ago
Athurg Gooth 8628d1e4b2
feat: add Telegram bot config UI (#1747)
* Add retry wait for telegram.GetUpdates

* Add support to set telegram robot token from UI

* Change validator of UserSettingTelegramUserID

* Add support to set telegram user id from UI

* Fix typescript check

* Add validator for SystemSettingTelegramRobotTokenName

* Optimize error notice while config telegram params

* Change for review

* Fix telegram user id could not be empty

* Fix telegram robot could not be empty

* Fix for eslint (again)

* Update web/src/components/Settings/SystemSection.tsx

---------

Co-authored-by: Athurg Feng <athurg@gooth.org>
Co-authored-by: boojack <stevenlgtm@gmail.com>
2 years ago
Athurg Gooth 1282fe732e
feat: implement telegram bot plugin (#1740) 2 years ago
boojack a07d11e820
feat: tag parser (#1745) 2 years ago
boojack dbc85fe7e4
feat: image and link parser (#1744)
* feat: image and link parser

* chore: update
2 years ago
boojack 65890bc257
feat: implement code block parser (#1727) 2 years ago
boojack 42c653e1a4
feat: implement paragraph and italic parsers (#1725) 2 years ago
boojack 8c34be92a6
feat(gomark): add bold parser (#1724) 2 years ago
boojack fa53a2550a
feat: add heading tokenizer (#1723) 2 years ago
boojack 88799d469c
chore: initial gomark plugin (#1678)
chore: initial gomark folder
2 years ago
Alex Zhao d0c40490a7
feat: add `HostnameImmutable` to aws endpoint config (#1230)
* add config to support S3-compatible urls like minio

* add comment for HostnameImmutable

* fix linting
2 years ago
boojack c7a57191bd
feat: add jwt auth (#1441)
* feat: add jwt auth

* chore: update
2 years ago
Xudong Cai d21abfc60c
feat: add URLSuffix resource option with S3 (#1428)
* feat: add URLSuffix resource option with S3

* feat: add URLSuffix resource option with S3

* fix: eslint
2 years ago
boojack ff8851fd9f
fix: golangci-lint version (#1381)
* chore: update interface declare

* chore: update args

* chore: update

* chore: update
2 years ago
boojack 573f07ec82
feat: support messages to ask AI (#1380) 2 years ago
boojack 29f784cc20
feat: update find resource with linked memo amount (#1354)
* feat: update find resource with linked memo amount

* chore: remove unused test
2 years ago
boojack 8d88477538
chore: rename http getter package (#1349) 2 years ago
boojack ccf6af4dc3
fix: request body format in openai api (#1309) 2 years ago
Wujiao233 003161ea54
feat: support set openai api host (#1292)
* Docker

* feat: support set openai api host

* fix css

* fix eslint

* use API in backend & put host check in plugin/openai

* fix go-static-checks
2 years ago
Zeng1998 fd99c5461c
feat(s3): customize filenames via placeholders (#1285)
* feat(s3): customize filenames via placeholders

* fix go-static-checks

* add tips on the frontend

* fix eslint check

* remove yarn.lock

* remove Config.Path

* update tips

* fix

* update
2 years ago
boojack 4335897367
chore: remove metrics plugin (#1276)
* chore: remove metrics plugin

* chore: update
2 years ago
boojack 31399fe475
fix: s3 custom path (#1249) 2 years ago
boojack df04e852bf
feat: implement openai integration (#1245)
* feat: implement openai integration

* chore: update
2 years ago
Alex Zhao 9d4bb5b3af
feat: add support for s3 path (#1233)
* add support for path

* fix typo and switch positions with Path and Bucket

* using path method instead of string concatenation
2 years ago
boojack 977e7f55e5
feat: add visibility field to resource (#1185) 2 years ago
Zhizhen He 50a99e9120
fix: correct comments for exported functions and variables (#1158) 2 years ago