Gusted and Gusted
513e79832a
Use correct log level for CheckCanonicalDomain ( #162 )
...
- Currently any error generated by requesting the `.domains` file of a repository would be logged under the info log level, which isn't the correct log level when we exclude the not found error.
- Use warn log level if the error isn't the not found error.
Co-authored-by: Gusted <postmaster@gusted.xyz >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/162
Reviewed-by: Otto <otto@codeberg.org >
2023-01-22 18:52:21 +00:00
98d198d419
Safely get certificate's leaf ( #150 )
...
- It's not guaranteed that `tls.X509KeyPair` will set `c.Leaf`.
- This patch fixes this by using a wrapper that parses the leaf
certificate(in bytes) if `c.Leaf` wasn't set.
- Resolves #149
Co-authored-by: Gusted <postmaster@gusted.xyz >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/150
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2023-01-04 04:51:27 +00:00
f2f943c0d8
Remove unnecessary conversion ( #139 )
...
- Remove unnecessary type conversion.
- Enforce via CI
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/139
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-11-15 16:15:11 +01:00
3c61a39864
Enable http/2 support ( #137 )
...
As per [the documentation](https://pkg.go.dev/net/http#Serve ), it doesn't enable HTTP2 by-default, unless we enable it via the `NextProtos` option.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/137
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-11-12 22:25:20 +01:00
bf9a08e1fd
Fatal on ACME Client creation failure ( #133 )
...
- For production(*cough* Codeberg *cough*), it's important to not use
mock certs. So fail right from the start if this is the case and not try
to "handle it gracefully", as it would break production.
- Resolves #131
CC @6543
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/133
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-11-07 16:27:37 +01:00
091e6c8ed9
Add explicit logging in GetBranchTimestamp ( #130 )
...
- Logs are currently indicating that it's returning `nil` in valid
scenarios, therefor this patch adds extra logging in this code to
better understand what it is doing in this function.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/130
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-09-18 16:13:27 +02:00
2a730b2439
Update README ( #128 )
...
- Update readme accordingly to the https://codeberg.org/Codeberg/pages-server/commit/876a53d9a245c11c58b61617052f7f2281d16358
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/128
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-09-13 23:26:45 +02:00
8f2699407d
Make verbose checks in tryBranch ( #127 )
...
- It's likely that the tryBranch is returning false when it should be returning true, make these logs more verbose so they show up on production logs.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/127
Reviewed-by: 6543 <6543@obermui.de >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-09-13 23:06:31 +02:00
1ae50735a1
Add host to handler logging ( #123 )
...
- Add the host to the Handler's logging fields, so you don't just see the path, but also which domain was being requested.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/123
Reviewed-by: 6543 <6543@noreply.codeberg.org >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-08-13 18:03:31 +02:00
f72bbfd85f
Fix just dev ( #121 )
...
- Use the correct log level command, since 876a53d9a2
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/121
Reviewed-by: 6543 <6543@noreply.codeberg.org >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-08-12 05:24:05 +02:00
876a53d9a2
Improve logging ( #116 )
...
- Actually log useful information at their respective log level.
- Add logs in hot-paths to be able to deep-dive and debug specific requests (see server/handler.go)
- Add more information to existing fields(e.g. the host that the user is visiting, this was noted by @fnetX).
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/116
Reviewed-by: 6543 <6543@noreply.codeberg.org >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-08-12 05:06:26 +02:00
fd24b4a2bc
Pass logger to fasthttp ( #98 )
...
- Use a logger with `FASTHTTP` prefix as fasthttp's logger so it's easy to see what fasthttp is logging in console/journal.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/98
Reviewed-by: 6543 <6543@noreply.codeberg.org >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-07-12 15:32:48 +02:00
48a49f69a7
Increase concurrent connections to default value ( #99 )
...
Use the default value of `256 * 1024` for the concurrency limit, this will mean that the server will be able to handle more connections.
Co-authored-by: Gusted <williamzijl7@hotmail.com >
Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/99
Reviewed-by: 6543 <6543@noreply.codeberg.org >
Co-authored-by: Gusted <gusted@noreply.codeberg.org >
Co-committed-by: Gusted <gusted@noreply.codeberg.org >
2022-07-03 13:20:02 +02:00