Compare commits

...

104 Commits

Author SHA1 Message Date
391bb6faeb Use ructe static file support to serve static files with hashes and caching 2022-08-21 13:48:03 +02:00
c93c83f004 Merge pull request #473 from vbrandl/dependabot/cargo/serde-1.0.143
chore(deps): Bump serde from 1.0.142 to 1.0.143
2022-08-18 14:08:25 +02:00
e82037c23b chore(deps): Bump serde from 1.0.142 to 1.0.143
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.142 to 1.0.143.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.142...v1.0.143)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-09 04:13:44 +00:00
ecbc63f522 Merge pull request #468 from vbrandl/dependabot/cargo/tracing-0.1.36
chore(deps): Bump tracing from 0.1.35 to 0.1.36
2022-08-04 12:49:57 +02:00
315eb514f4 chore(deps): Bump tracing from 0.1.35 to 0.1.36
Bumps [tracing](https://github.com/tokio-rs/tracing) from 0.1.35 to 0.1.36.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-0.1.35...tracing-0.1.36)

---
updated-dependencies:
- dependency-name: tracing
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 10:40:55 +00:00
9139c8f005 Merge pull request #470 from vbrandl/dependabot/cargo/config-0.13.2
chore(deps): Bump config from 0.13.1 to 0.13.2
2022-08-04 12:39:48 +02:00
96ded8a0a8 Merge pull request #471 from vbrandl/dependabot/cargo/serde-1.0.142
chore(deps): Bump serde from 1.0.140 to 1.0.142
2022-08-04 12:39:25 +02:00
15692cbb08 Merge pull request #472 from vbrandl/dependabot/cargo/serde_json-1.0.83
chore(deps): Bump serde_json from 1.0.82 to 1.0.83
2022-08-04 12:38:59 +02:00
98d80faf3a chore(deps): Bump serde_json from 1.0.82 to 1.0.83
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.82 to 1.0.83.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.82...v1.0.83)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 04:14:04 +00:00
a0cb623dc6 chore(deps): Bump serde from 1.0.140 to 1.0.142
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.140 to 1.0.142.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.140...v1.0.142)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-04 04:13:56 +00:00
28582e58e0 chore(deps): Bump config from 0.13.1 to 0.13.2
Bumps [config](https://github.com/mehcode/config-rs) from 0.13.1 to 0.13.2.
- [Release notes](https://github.com/mehcode/config-rs/releases)
- [Changelog](https://github.com/mehcode/config-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mehcode/config-rs/compare/0.13.1...0.13.2)

---
updated-dependencies:
- dependency-name: config
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-03 04:12:43 +00:00
e79e1e2634 Merge pull request #467 from vbrandl/dependabot/cargo/bytes-1.2.1
chore(deps): Bump bytes from 1.1.0 to 1.2.1
2022-07-30 17:16:13 +02:00
097a1affcf Merge pull request #462 from vbrandl/dependabot/cargo/tracing-subscriber-0.3.15
chore(deps): Bump tracing-subscriber from 0.3.14 to 0.3.15
2022-07-30 17:07:41 +02:00
df022f538c chore(deps): Bump bytes from 1.1.0 to 1.2.1
Bumps [bytes](https://github.com/tokio-rs/bytes) from 1.1.0 to 1.2.1.
- [Release notes](https://github.com/tokio-rs/bytes/releases)
- [Changelog](https://github.com/tokio-rs/bytes/blob/master/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/bytes/commits)

---
updated-dependencies:
- dependency-name: bytes
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-30 15:07:38 +00:00
b4327ff28f Merge pull request #463 from vbrandl/dependabot/cargo/serde-1.0.140
chore(deps): Bump serde from 1.0.139 to 1.0.140
2022-07-30 17:07:31 +02:00
38a837bc70 Merge pull request #464 from vbrandl/dependabot/cargo/vergen-7.3.1
chore(deps): Bump vergen from 7.2.1 to 7.3.1
2022-07-30 17:07:17 +02:00
743fe98d1b Merge pull request #465 from vbrandl/dependabot/cargo/tokio-1.20.1
chore(deps): Bump tokio from 1.20.0 to 1.20.1
2022-07-30 17:07:02 +02:00
d0e2f21339 Merge pull request #466 from vbrandl/dependabot/cargo/git2-0.15.0
chore(deps): Bump git2 from 0.14.4 to 0.15.0
2022-07-30 17:06:31 +02:00
ebe844d305 chore(deps): Bump git2 from 0.14.4 to 0.15.0
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.14.4 to 0.15.0.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Commits](https://github.com/rust-lang/git2-rs/compare/0.14.4...git2-curl-0.15.0)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-29 04:16:42 +00:00
c0119ccc97 chore(deps): Bump tokio from 1.20.0 to 1.20.1
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.20.0 to 1.20.1.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.20.0...tokio-1.20.1)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-26 04:17:03 +00:00
6ae96e9b33 chore(deps): Bump vergen from 7.2.1 to 7.3.1
Bumps [vergen](https://github.com/rustyhorde/vergen) from 7.2.1 to 7.3.1.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/7.2.1...7.3.1)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-22 04:20:57 +00:00
85bd714eb8 chore(deps): Bump serde from 1.0.139 to 1.0.140
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.139 to 1.0.140.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.139...v1.0.140)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-21 04:21:57 +00:00
4d63a3cb0b chore(deps): Bump tracing-subscriber from 0.3.14 to 0.3.15
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.14 to 0.3.15.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.14...tracing-subscriber-0.3.15)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-21 04:21:43 +00:00
5d7d06abef Merge pull request #460 from vbrandl/dependabot/cargo/tokio-1.20.0
chore(deps): Bump tokio from 1.19.2 to 1.20.0
2022-07-15 13:16:54 +02:00
a84885a2ca Merge pull request #459 from vbrandl/dependabot/cargo/serde-1.0.139
chore(deps): Bump serde from 1.0.138 to 1.0.139
2022-07-15 13:16:06 +02:00
ee1de29158 chore(deps): Bump tokio from 1.19.2 to 1.20.0
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.19.2 to 1.20.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.19.2...tokio-1.20.0)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-14 04:15:59 +00:00
e48279c6d8 chore(deps): Bump serde from 1.0.138 to 1.0.139
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.138 to 1.0.139.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.138...v1.0.139)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-12 04:18:20 +00:00
3df296e542 Merge pull request #454 from vbrandl/dependabot/cargo/tracing-actix-web-0.6.0
chore(deps): Bump tracing-actix-web from 0.5.1 to 0.6.0
2022-07-06 20:24:35 +02:00
a65f8d9d72 Merge pull request #455 from vbrandl/dependabot/cargo/serde_json-1.0.82
chore(deps): Bump serde_json from 1.0.81 to 1.0.82
2022-07-06 19:58:10 +02:00
ec04b0a76f Merge pull request #457 from vbrandl/dependabot/cargo/serde-1.0.138
chore(deps): Bump serde from 1.0.137 to 1.0.138
2022-07-06 19:57:57 +02:00
5387265a3e chore(deps): Bump tracing-actix-web from 0.5.1 to 0.6.0
Bumps [tracing-actix-web](https://github.com/LukeMathWalker/tracing-actix-web) from 0.5.1 to 0.6.0.
- [Release notes](https://github.com/LukeMathWalker/tracing-actix-web/releases)
- [Commits](https://github.com/LukeMathWalker/tracing-actix-web/compare/v0.5.1...v0.6.0)

---
updated-dependencies:
- dependency-name: tracing-actix-web
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-06 17:57:42 +00:00
0379d4bfc0 Merge pull request #458 from vbrandl/dependabot/cargo/tracing-subscriber-0.3.14
chore(deps): Bump tracing-subscriber from 0.3.11 to 0.3.14
2022-07-06 19:56:34 +02:00
7e1b86ace1 chore(deps): Bump tracing-subscriber from 0.3.11 to 0.3.14
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.11 to 0.3.14.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.11...tracing-subscriber-0.3.14)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-04 04:17:13 +00:00
f000dbd27c chore(deps): Bump serde from 1.0.137 to 1.0.138
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.137 to 1.0.138.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.137...v1.0.138)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-04 04:17:06 +00:00
3fd245da4a chore(deps): Bump serde_json from 1.0.81 to 1.0.82
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.81 to 1.0.82.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.81...v1.0.82)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-30 04:20:49 +00:00
6f292796a4 Merge pull request #453 from vbrandl/dependabot/cargo/tracing-bunyan-formatter-0.3.3
chore(deps): Bump tracing-bunyan-formatter from 0.3.2 to 0.3.3
2022-06-27 10:59:08 +02:00
95bc3491ec chore(deps): Bump tracing-bunyan-formatter from 0.3.2 to 0.3.3
Bumps [tracing-bunyan-formatter](https://github.com/LukeMathWalker/tracing-bunyan-formatter) from 0.3.2 to 0.3.3.
- [Release notes](https://github.com/LukeMathWalker/tracing-bunyan-formatter/releases)
- [Commits](https://github.com/LukeMathWalker/tracing-bunyan-formatter/compare/v0.3.2...v0.3.3)

---
updated-dependencies:
- dependency-name: tracing-bunyan-formatter
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-27 04:12:20 +00:00
9b961032aa chore: Update dependencies
Some checks failed
continuous-integration/drone/push Build is failing
2022-06-16 13:34:20 +02:00
32a2cc7132 chore: Bump version number (v0.22.4)
Some checks failed
continuous-integration/drone/tag Build is failing
continuous-integration/drone/push Build is failing
2022-06-16 12:32:54 +02:00
aeb1293067 Merge pull request #452 from vbrandl/dependabot/cargo/reqwest-0.11.11
Some checks failed
continuous-integration/drone/push Build is failing
chore(deps): Bump reqwest from 0.11.10 to 0.11.11
2022-06-16 12:10:52 +02:00
fd70162033 chore(deps): Bump reqwest from 0.11.10 to 0.11.11
Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.10 to 0.11.11.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.10...v0.11.11)

---
updated-dependencies:
- dependency-name: reqwest
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-14 04:22:08 +00:00
fa93e0e8b7 Merge pull request #449 from vbrandl/dependabot/cargo/tokio-1.19.2
Bump tokio from 1.18.2 to 1.19.2
2022-06-13 11:13:49 +02:00
33b215f1e5 Merge pull request #450 from vbrandl/dependabot/cargo/vergen-7.2.1
Bump vergen from 7.2.0 to 7.2.1
2022-06-13 11:13:39 +02:00
4029216a18 Merge pull request #451 from vbrandl/dependabot/cargo/actix-web-4.1.0
Bump actix-web from 4.0.1 to 4.1.0
2022-06-13 11:13:29 +02:00
c67fcd84ca Bump actix-web from 4.0.1 to 4.1.0
Bumps [actix-web](https://github.com/actix/actix-web) from 4.0.1 to 4.1.0.
- [Release notes](https://github.com/actix/actix-web/releases)
- [Changelog](https://github.com/actix/actix-web/blob/master/CHANGES.md)
- [Commits](https://github.com/actix/actix-web/compare/web-v4.0.1...web-v4.1.0)

---
updated-dependencies:
- dependency-name: actix-web
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-13 04:16:57 +00:00
f6492890ae Bump vergen from 7.2.0 to 7.2.1
Bumps [vergen](https://github.com/rustyhorde/vergen) from 7.2.0 to 7.2.1.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/7.2.0...7.2.1)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-08 04:13:26 +00:00
901b492641 Bump tokio from 1.18.2 to 1.19.2
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.18.2 to 1.19.2.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/commits)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-07 04:14:50 +00:00
1fe916deb0 chore: Bump version number (v0.22.3)
Some checks failed
continuous-integration/drone/tag Build is failing
continuous-integration/drone/push Build is failing
2022-05-27 20:57:38 +02:00
cf30970784 Merge pull request #447 from vbrandl/dependabot/cargo/vergen-7.2.0
Some checks failed
continuous-integration/drone/push Build is failing
Bump vergen from 7.0.0 to 7.2.0
2022-05-27 08:40:03 +02:00
59e12f6a08 Bump vergen from 7.0.0 to 7.2.0
Bumps [vergen](https://github.com/rustyhorde/vergen) from 7.0.0 to 7.2.0.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/7.0.0...7.2.0)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-27 06:24:26 +00:00
8fb4f75cc4 Merge pull request #441 from vbrandl/dependabot/cargo/serde-1.0.137
Bump serde from 1.0.136 to 1.0.137
2022-05-27 08:22:55 +02:00
dd3767a73c Merge pull request #443 from vbrandl/dependabot/cargo/serde_json-1.0.81
Bump serde_json from 1.0.79 to 1.0.81
2022-05-27 08:22:45 +02:00
aa92d67637 Merge pull request #444 from vbrandl/dependabot/cargo/tokio-1.18.2
Bump tokio from 1.18.0 to 1.18.2
2022-05-27 08:22:34 +02:00
5dd8415c50 Merge pull request #446 from vbrandl/dependabot/cargo/git2-0.14.4
Bump git2 from 0.14.2 to 0.14.4
2022-05-27 08:22:24 +02:00
9e0fdebe0e Bump git2 from 0.14.2 to 0.14.4
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.14.2 to 0.14.4.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Commits](https://github.com/rust-lang/git2-rs/compare/0.14.2...0.14.4)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-24 04:16:11 +00:00
778499c582 Bump tokio from 1.18.0 to 1.18.2
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.18.0 to 1.18.2.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.18.0...tokio-1.18.2)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-09 04:23:04 +00:00
e08d2f897d Bump serde_json from 1.0.79 to 1.0.81
Bumps [serde_json](https://github.com/serde-rs/json) from 1.0.79 to 1.0.81.
- [Release notes](https://github.com/serde-rs/json/releases)
- [Commits](https://github.com/serde-rs/json/compare/v1.0.79...v1.0.81)

---
updated-dependencies:
- dependency-name: serde_json
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-04 04:14:30 +00:00
b77e837022 Bump serde from 1.0.136 to 1.0.137
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.136 to 1.0.137.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.136...v1.0.137)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-05-02 04:16:13 +00:00
4cd26b6582 Merge pull request #438 from vbrandl/dependabot/cargo/tracing-log-0.1.3
All checks were successful
continuous-integration/drone/push Build is passing
Bump tracing-log from 0.1.2 to 0.1.3
2022-04-28 12:53:35 +02:00
74f6552f55 Merge pull request #437 from vbrandl/dependabot/cargo/tracing-0.1.34
Bump tracing from 0.1.33 to 0.1.34
2022-04-28 12:53:29 +02:00
528e2a6211 Merge pull request #439 from vbrandl/dependabot/cargo/tokio-1.18.0
Bump tokio from 1.17.0 to 1.18.0
2022-04-28 12:53:14 +02:00
9f66b8fa94 Bump tokio from 1.17.0 to 1.18.0
Bumps [tokio](https://github.com/tokio-rs/tokio) from 1.17.0 to 1.18.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.17.0...tokio-1.18.0)

---
updated-dependencies:
- dependency-name: tokio
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-28 04:13:27 +00:00
bd0df932eb Bump tracing-log from 0.1.2 to 0.1.3
Bumps [tracing-log](https://github.com/tokio-rs/tracing) from 0.1.2 to 0.1.3.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-log-0.1.2...tracing-log-0.1.3)

---
updated-dependencies:
- dependency-name: tracing-log
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-22 04:14:49 +00:00
0ab62a7427 Bump tracing from 0.1.33 to 0.1.34
Bumps [tracing](https://github.com/tokio-rs/tracing) from 0.1.33 to 0.1.34.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-0.1.33...tracing-0.1.34)

---
updated-dependencies:
- dependency-name: tracing
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-15 04:16:58 +00:00
b84475f035 chore: Bump version number (v0.22.2)
All checks were successful
continuous-integration/drone/tag Build is passing
continuous-integration/drone/push Build is passing
2022-04-14 11:08:40 +02:00
678307d342 Merge pull request #434 from vbrandl/dependabot/cargo/tracing-0.1.33
Bump tracing from 0.1.32 to 0.1.33
2022-04-14 10:54:58 +02:00
71dc615e53 Merge pull request #435 from vbrandl/dependabot/cargo/tracing-subscriber-0.3.11
Bump tracing-subscriber from 0.3.10 to 0.3.11
2022-04-14 10:54:42 +02:00
1ed56fe02b Merge pull request #436 from vbrandl/dependabot/cargo/config-0.13.1
Bump config from 0.13.0 to 0.13.1
2022-04-14 10:54:27 +02:00
a44f366906 Bump config from 0.13.0 to 0.13.1
Bumps [config](https://github.com/mehcode/config-rs) from 0.13.0 to 0.13.1.
- [Release notes](https://github.com/mehcode/config-rs/releases)
- [Changelog](https://github.com/mehcode/config-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mehcode/config-rs/compare/0.13.0...0.13.1)

---
updated-dependencies:
- dependency-name: config
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-14 04:14:40 +00:00
8e63b399f2 Bump tracing-subscriber from 0.3.10 to 0.3.11
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.10 to 0.3.11.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.10...tracing-subscriber-0.3.11)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-11 04:17:10 +00:00
076ece939b Bump tracing from 0.1.32 to 0.1.33
Bumps [tracing](https://github.com/tokio-rs/tracing) from 0.1.32 to 0.1.33.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-0.1.32...tracing-0.1.33)

---
updated-dependencies:
- dependency-name: tracing
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-11 04:17:01 +00:00
efaac97bff Merge pull request #433 from vbrandl/dependabot/cargo/config-0.13.0
All checks were successful
continuous-integration/drone/push Build is passing
Bump config from 0.12.0 to 0.13.0
2022-04-07 20:37:06 +02:00
238be58ce8 Merge pull request #432 from vbrandl/dependabot/cargo/tracing-subscriber-0.3.10
Bump tracing-subscriber from 0.3.9 to 0.3.10
2022-04-07 20:36:52 +02:00
0749de5edd Bump config from 0.12.0 to 0.13.0
Bumps [config](https://github.com/mehcode/config-rs) from 0.12.0 to 0.13.0.
- [Release notes](https://github.com/mehcode/config-rs/releases)
- [Changelog](https://github.com/mehcode/config-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mehcode/config-rs/compare/0.12.0...0.13.0)

---
updated-dependencies:
- dependency-name: config
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-04 04:17:51 +00:00
88fb585f6a Bump tracing-subscriber from 0.3.9 to 0.3.10
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.9 to 0.3.10.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.9...tracing-subscriber-0.3.10)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-04 04:17:41 +00:00
f6f29e7b46 Merge pull request #431 from vbrandl/dependabot/cargo/reqwest-0.11.10
All checks were successful
continuous-integration/drone/push Build is passing
Bump reqwest from 0.11.9 to 0.11.10
2022-03-15 11:06:07 +01:00
7db9de5ff0 Bump reqwest from 0.11.9 to 0.11.10
Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.9 to 0.11.10.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.9...v0.11.10)

---
updated-dependencies:
- dependency-name: reqwest
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-15 04:15:54 +00:00
aad237e0b3 Merge pull request #430 from vbrandl/dependabot/cargo/git2-0.14.2
Bump git2 from 0.14.1 to 0.14.2
2022-03-11 16:27:59 +01:00
c3d4b0d156 Bump git2 from 0.14.1 to 0.14.2
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.14.1 to 0.14.2.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Commits](https://github.com/rust-lang/git2-rs/compare/git2-curl-0.14.1...0.14.2)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-11 04:15:31 +00:00
a4974b136b chore: Bump version number (v0.22.1)
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
2022-03-10 13:09:45 +01:00
c3fe019cf1 No need to ignore these advisories 2022-03-10 13:09:14 +01:00
c5fbe731aa Merge pull request #429 from vbrandl/dependabot/cargo/vergen-7.0.0
Bump vergen from 6.0.2 to 7.0.0
2022-03-10 13:07:09 +01:00
6c14a60f7e Bump vergen from 6.0.2 to 7.0.0
Bumps [vergen](https://github.com/rustyhorde/vergen) from 6.0.2 to 7.0.0.
- [Release notes](https://github.com/rustyhorde/vergen/releases)
- [Commits](https://github.com/rustyhorde/vergen/compare/6.0.2...7.0.0)

---
updated-dependencies:
- dependency-name: vergen
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-10 04:16:17 +00:00
90e801507c chore: Bump version number (v0.22.0)
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
2022-03-09 19:03:10 +01:00
ed42395070 chore: Update actix-web and tracing 2022-03-09 18:57:54 +01:00
470bc028f1 chore: Update dependencies 2022-03-09 18:55:23 +01:00
d869657105 Merge pull request #428 from vbrandl/dependabot/cargo/actix-rt-2.7.0
All checks were successful
continuous-integration/drone/push Build is passing
Bump actix-rt from 2.6.0 to 2.7.0
2022-03-09 18:21:09 +01:00
4148b8e460 Merge pull request #427 from vbrandl/dependabot/cargo/awc-3.0.0
Bump awc from 3.0.0-beta.21 to 3.0.0
2022-03-09 18:20:51 +01:00
b4c4add0fc Merge pull request #426 from vbrandl/dependabot/cargo/tracing-actix-web-0.5.1
Bump tracing-actix-web from 0.5.0 to 0.5.1
2022-03-09 18:20:22 +01:00
fbaea42d11 Bump actix-rt from 2.6.0 to 2.7.0
Bumps [actix-rt](https://github.com/actix/actix-net) from 2.6.0 to 2.7.0.
- [Release notes](https://github.com/actix/actix-net/releases)
- [Commits](https://github.com/actix/actix-net/compare/rt-v2.6.0...rt-v2.7.0)

---
updated-dependencies:
- dependency-name: actix-rt
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-09 04:22:56 +00:00
659c531640 Bump awc from 3.0.0-beta.21 to 3.0.0
Bumps [awc](https://github.com/actix/actix-web) from 3.0.0-beta.21 to 3.0.0.
- [Release notes](https://github.com/actix/actix-web/releases)
- [Changelog](https://github.com/actix/actix-web/blob/master/CHANGES.md)
- [Commits](https://github.com/actix/actix-web/compare/awc-v3.0.0-beta.21...awc-v3.0.0)

---
updated-dependencies:
- dependency-name: awc
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-09 04:22:51 +00:00
5222e5bf27 Bump tracing-actix-web from 0.5.0 to 0.5.1
Bumps [tracing-actix-web](https://github.com/LukeMathWalker/tracing-actix-web) from 0.5.0 to 0.5.1.
- [Release notes](https://github.com/LukeMathWalker/tracing-actix-web/releases)
- [Commits](https://github.com/LukeMathWalker/tracing-actix-web/compare/v0.5.0...v0.5.1)

---
updated-dependencies:
- dependency-name: tracing-actix-web
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-02 04:20:11 +00:00
7758066eff Merge pull request #425 from vbrandl/dependabot/cargo/git2-0.14.1
Bump git2 from 0.14.0 to 0.14.1
2022-03-01 11:32:59 +01:00
ab4519afbb Merge pull request #424 from vbrandl/dependabot/cargo/tracing-actix-web-0.5.0
Bump tracing-actix-web from 0.5.0-rc.3 to 0.5.0
2022-03-01 11:32:32 +01:00
0714f56d57 Bump git2 from 0.14.0 to 0.14.1
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.14.0 to 0.14.1.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Commits](https://github.com/rust-lang/git2-rs/compare/git2-curl-0.14.0...git2-curl-0.14.1)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-01 04:18:31 +00:00
663af56fcc Bump tracing-actix-web from 0.5.0-rc.3 to 0.5.0
Bumps [tracing-actix-web](https://github.com/LukeMathWalker/tracing-actix-web) from 0.5.0-rc.3 to 0.5.0.
- [Release notes](https://github.com/LukeMathWalker/tracing-actix-web/releases)
- [Commits](https://github.com/LukeMathWalker/tracing-actix-web/compare/v0.5.0-rc.3...v0.5.0)

---
updated-dependencies:
- dependency-name: tracing-actix-web
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-28 04:22:28 +00:00
d92860e825 chore: Bump version number (v0.21.3)
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing
2022-02-26 16:34:07 +01:00
6ac19fe898 Merge branch 'remove-nix' 2022-02-26 16:28:18 +01:00
75fd905547 Merge pull request #422 from vbrandl/dependabot/cargo/config-0.12.0
Bump config from 0.11.0 to 0.12.0
2022-02-26 16:28:03 +01:00
3df814c64c Remove (unused) nix build (for now) and add direnv/lorri setup 2022-02-26 16:27:57 +01:00
84f4aa9be3 Migrate to config v0.12.0
All checks were successful
continuous-integration/drone/push Build is passing
2022-02-26 16:22:36 +01:00
0a518ab331 Bump config from 0.11.0 to 0.12.0
Bumps [config](https://github.com/mehcode/config-rs) from 0.11.0 to 0.12.0.
- [Release notes](https://github.com/mehcode/config-rs/releases)
- [Changelog](https://github.com/mehcode/config-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mehcode/config-rs/compare/0.11.0...0.12.0)

---
updated-dependencies:
- dependency-name: config
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-26 15:02:08 +00:00
5caed6729a Merge pull request #423 from vbrandl/dependabot/cargo/git2-0.14.0
Bump git2 from 0.13.25 to 0.14.0
2022-02-26 15:59:12 +01:00
7846872aaa Bump git2 from 0.13.25 to 0.14.0
Bumps [git2](https://github.com/rust-lang/git2-rs) from 0.13.25 to 0.14.0.
- [Release notes](https://github.com/rust-lang/git2-rs/releases)
- [Commits](https://github.com/rust-lang/git2-rs/compare/0.13.25...git2-curl-0.14.0)

---
updated-dependencies:
- dependency-name: git2
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-02-25 04:15:36 +00:00
16 changed files with 541 additions and 4133 deletions

View File

@ -1,3 +1 @@
[advisories]
# TODO: check if chrono fixed this
ignore = [ "RUSTSEC-2020-0159", "RUSTSEC-2020-0071" ]

1
.envrc Normal file
View File

@ -0,0 +1 @@
eval "$(lorri direnv)"

887
Cargo.lock generated

File diff suppressed because it is too large Load Diff

3357
Cargo.nix

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
[package]
name = "hoc"
version = "0.21.2"
version = "0.22.4"
authors = ["Valentin Brandl <vbrandl@riseup.net>"]
edition = "2018"
build = "build.rs"
@ -13,34 +13,35 @@ path = "src/main.rs"
name = "hoc"
[dependencies]
actix-rt = "2.6.0"
actix-web = "4.0.0-rc.3"
actix-rt = "2.7.0"
actix-web = "4.1.0"
badge = "0.3.0"
bytes = "1.1.0"
config = { version = "0.11.0", features = ["toml"] }
bytes = "1.2.1"
config = { version = "0.13.2", features = ["toml"] }
dotenv = "0.15.0"
futures = "0.3.21"
git2 = "0.13.25"
git2 = "0.15.0"
lazy_static = "1.4.0"
mime = "0.3"
number_prefix = "0.4.0"
openssl-probe = "0.1.5"
reqwest = "0.11.9"
serde = "1.0.136"
serde_derive = "1.0.136"
serde_json = "1.0.79"
tracing = "0.1.31"
tracing-actix-web = "0.5.0-rc.3"
tracing-bunyan-formatter = "0.3.2"
reqwest = "0.11.11"
serde = "1.0.143"
serde_derive = "1.0.137"
serde_json = "1.0.83"
tracing = "0.1.36"
tracing-actix-web = "0.6.0"
tracing-bunyan-formatter = "0.3.3"
tracing-futures = "0.2.5"
tracing-log = "0.1.2"
tracing-subscriber = { version = "0.3.9", features = ["registry", "env-filter"] }
tracing-log = "0.1.3"
tracing-subscriber = { version = "0.3.15", features = ["registry", "env-filter"] }
[build-dependencies]
ructe = "0.14.0"
vergen = { version = "6.0.2", default-features = false, features = ["git"] }
ructe = { version = "0.14.0", features = ["mime03"] }
vergen = { version = "7.3.1", default-features = false, features = ["git"] }
[dev-dependencies]
awc = "3.0.0-beta.21"
awc = "3.0.0"
ructe = "0.14.0"
tempfile = "3.3.0"
tokio = "1.17.0"
tokio = "1.20.1"

View File

@ -8,5 +8,8 @@ fn main() -> Result<(), RucteError> {
let mut config = Config::default();
*config.git_mut().sha_kind_mut() = ShaKind::Short;
vergen(config).expect("Unable to generate static repo info");
Ructe::from_env()?.compile_templates("templates")
let mut ructe = Ructe::from_env()?;
let mut statics = ructe.statics()?;
statics.add_files("static")?;
ructe.compile_templates("templates")
}

View File

@ -1 +0,0 @@
{}

View File

@ -1,56 +0,0 @@
{ sources ? import ./nix/sources.nix
, system ? builtins.currentSystem
}:
let
rustOverlay = import "${sources.nixpkgs-mozilla}/rust-overlay.nix";
cargo2nixOverlay = import "${sources.cargo2nix}/overlay";
pkgs = import sources.nixpkgs {
# pkgs = import <nixpkgs> {
inherit system;
overlays = [ cargo2nixOverlay rustOverlay ];
};
rustPkgs = pkgs.rustBuilder.makePackageSet' {
rustChannel = "stable";
packageFun = import ./Cargo.nix;
localPatterns =
[
''^(src|tests)(/.*)?''
''[^/]*\.(rs|toml)$''
# include other directory from the project repository
''^templates(/.*)?''
''^static(/.*)?''
''^.git.*(/.*)?''
];
# packageOverrides
};
in
rec {
inherit rustPkgs;
shell = pkgs.mkShell {
inputsFrom = pkgs.lib.mapAttrsToList (_: pkg: pkg { }) rustPkgs.noBuild.workspace;
nativeBuildInputs = with rustPkgs; [ cargo rustc ];
};
package = (rustPkgs.workspace.hoc {}).overrideAttrs (drv: {
buildInputs = drv.buildInputs or [ ] ++ [ pkgs.git ];
});
dockerImage =
pkgs.dockerTools.buildImage {
name = "vbrandl/hits-of-code";
tag = package.version;
contents =
[
package
pkgs.cacert
pkgs.gitMinimal
];
config = {
Cmd = [ "/bin/hoc" ];
WorkingDir = "/home/hoc";
};
};
}

View File

@ -1,50 +0,0 @@
{
"cargo2nix": {
"branch": "master",
"description": "Convert a Cargo.lock to mkRustCrate statements for import in Nix",
"homepage": "",
"owner": "tenx-tech",
"repo": "cargo2nix",
"rev": "7bc062ccffc41dc7d3759b8b797e8b4f8dd23a15",
"sha256": "1z7xwk1hbp26aydsk3y07riy0ivwqss06n1470mvdl7allfcd1w5",
"type": "tarball",
"url": "https://github.com/tenx-tech/cargo2nix/archive/7bc062ccffc41dc7d3759b8b797e8b4f8dd23a15.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"niv": {
"branch": "master",
"description": "Easy dependency management for Nix projects",
"homepage": "https://github.com/nmattia/niv",
"owner": "nmattia",
"repo": "niv",
"rev": "98c74a80934123cb4c3bf3314567f67311eb711a",
"sha256": "1w8n54hapd4x9f1am33icvngkqns7m3hl9yair38yqq08ffwg0kn",
"type": "tarball",
"url": "https://github.com/nmattia/niv/archive/98c74a80934123cb4c3bf3314567f67311eb711a.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixpkgs": {
"branch": "nixpkgs-unstable",
"description": "A read-only mirror of NixOS/nixpkgs tracking the released channels. Send issues and PRs to",
"homepage": "https://github.com/NixOS/nixpkgs",
"owner": "NixOS",
"repo": "nixpkgs-channels",
"rev": "f6bfb371cba2b5a02f200c2747c1fe2c72bd782f",
"sha256": "0y3hlbyvznrpr1d2vxj2511hkjg733wdnxfaib3fgy9i9jr8ivzn",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs-channels/archive/f6bfb371cba2b5a02f200c2747c1fe2c72bd782f.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixpkgs-mozilla": {
"branch": "master",
"description": "mozilla related nixpkgs (extends nixos/nixpkgs repo)",
"homepage": null,
"owner": "mozilla",
"repo": "nixpkgs-mozilla",
"rev": "e912ed483e980dfb4666ae0ed17845c4220e5e7c",
"sha256": "08fvzb8w80bkkabc1iyhzd15f4sm7ra10jn32kfch5klgl0gj3j3",
"type": "tarball",
"url": "https://github.com/mozilla/nixpkgs-mozilla/archive/e912ed483e980dfb4666ae0ed17845c4220e5e7c.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
}
}

View File

@ -1,134 +0,0 @@
# This file has been generated by Niv.
let
#
# The fetchers. fetch_<type> fetches specs of type <type>.
#
fetch_file = pkgs: spec:
if spec.builtin or true then
builtins_fetchurl { inherit (spec) url sha256; }
else
pkgs.fetchurl { inherit (spec) url sha256; };
fetch_tarball = pkgs: spec:
if spec.builtin or true then
builtins_fetchTarball { inherit (spec) url sha256; }
else
pkgs.fetchzip { inherit (spec) url sha256; };
fetch_git = spec:
builtins.fetchGit { url = spec.repo; inherit (spec) rev ref; };
fetch_builtin-tarball = spec:
builtins.trace
''
WARNING:
The niv type "builtin-tarball" will soon be deprecated. You should
instead use `builtin = true`.
$ niv modify <package> -a type=tarball -a builtin=true
''
builtins_fetchTarball { inherit (spec) url sha256; };
fetch_builtin-url = spec:
builtins.trace
''
WARNING:
The niv type "builtin-url" will soon be deprecated. You should
instead use `builtin = true`.
$ niv modify <package> -a type=file -a builtin=true
''
(builtins_fetchurl { inherit (spec) url sha256; });
#
# Various helpers
#
# The set of packages used when specs are fetched using non-builtins.
mkPkgs = sources:
let
sourcesNixpkgs =
import (builtins_fetchTarball { inherit (sources.nixpkgs) url sha256; }) {};
hasNixpkgsPath = builtins.any (x: x.prefix == "nixpkgs") builtins.nixPath;
hasThisAsNixpkgsPath = <nixpkgs> == ./.;
in
if builtins.hasAttr "nixpkgs" sources
then sourcesNixpkgs
else if hasNixpkgsPath && ! hasThisAsNixpkgsPath then
import <nixpkgs> {}
else
abort
''
Please specify either <nixpkgs> (through -I or NIX_PATH=nixpkgs=...) or
add a package called "nixpkgs" to your sources.json.
'';
# The actual fetching function.
fetch = pkgs: name: spec:
if ! builtins.hasAttr "type" spec then
abort "ERROR: niv spec ${name} does not have a 'type' attribute"
else if spec.type == "file" then fetch_file pkgs spec
else if spec.type == "tarball" then fetch_tarball pkgs spec
else if spec.type == "git" then fetch_git spec
else if spec.type == "builtin-tarball" then fetch_builtin-tarball spec
else if spec.type == "builtin-url" then fetch_builtin-url spec
else
abort "ERROR: niv spec ${name} has unknown type ${builtins.toJSON spec.type}";
# Ports of functions for older nix versions
# a Nix version of mapAttrs if the built-in doesn't exist
mapAttrs = builtins.mapAttrs or (
f: set: with builtins;
listToAttrs (map (attr: { name = attr; value = f attr set.${attr}; }) (attrNames set))
);
# fetchTarball version that is compatible between all the versions of Nix
builtins_fetchTarball = { url, sha256 }@attrs:
let
inherit (builtins) lessThan nixVersion fetchTarball;
in
if lessThan nixVersion "1.12" then
fetchTarball { inherit url; }
else
fetchTarball attrs;
# fetchurl version that is compatible between all the versions of Nix
builtins_fetchurl = { url, sha256 }@attrs:
let
inherit (builtins) lessThan nixVersion fetchurl;
in
if lessThan nixVersion "1.12" then
fetchurl { inherit url; }
else
fetchurl attrs;
# Create the final "sources" from the config
mkSources = config:
mapAttrs (
name: spec:
if builtins.hasAttr "outPath" spec
then abort
"The values in sources.json should not have an 'outPath' attribute"
else
spec // { outPath = fetch config.pkgs name spec; }
) config.sources;
# The "config" used by the fetchers
mkConfig =
{ sourcesFile ? ./sources.json
, sources ? builtins.fromJSON (builtins.readFile sourcesFile)
, pkgs ? mkPkgs sources
}: rec {
# The sources, i.e. the attribute set of spec name to spec
inherit sources;
# The "pkgs" (evaluated nixpkgs) to use for e.g. non-builtin fetchers
inherit pkgs;
};
in
mkSources (mkConfig {}) // { __functor = _: settings: mkSources (mkConfig settings); }

View File

@ -1 +1,8 @@
with import ./. { }; shell
{ pkgs ? import <nixpkgs> {} }:
pkgs.mkShell {
buildInputs = with pkgs; [
openssl
pkg-config
];
}

View File

@ -18,21 +18,16 @@ pub struct Settings {
}
impl Settings {
#[deprecated]
pub fn new() -> Result<Self, ConfigError> {
Self::load()
}
pub fn load() -> Result<Self, ConfigError> {
let mut config = Config::new();
config
.merge(File::with_name("hoc.toml").required(false))?
.merge(Environment::with_prefix("hoc"))?
Config::builder()
.add_source(File::with_name("hoc.toml").required(false))
.add_source(Environment::with_prefix("hoc"))
.set_default("repodir", "./repos")?
.set_default("cachedir", "./cache")?
.set_default("workers", 4)?
.set_default("port", 8080)?
.set_default("host", "0.0.0.0")?;
config.try_into()
.set_default("host", "0.0.0.0")?
.build()?
.try_deserialize()
}
}

View File

@ -23,7 +23,7 @@ use crate::{
config::Settings,
error::{Error, Result},
service::{Bitbucket, FormService, GitHub, Gitlab, Service, Sourcehut},
statics::{CLIENT, CSS, FAVICON, VERSION_INFO},
statics::{CLIENT, VERSION_INFO},
template::RepoInfo,
};
use actix_web::{
@ -46,6 +46,7 @@ use std::{
sync::atomic::Ordering,
time::{Duration, SystemTime},
};
use templates::statics::{self as template_statics, StaticFile};
use tracing::Instrument;
include!(concat!(env!("OUT_DIR"), "/templates.rs"));
@ -462,14 +463,32 @@ async fn async_p404(repo_count: web::Data<AtomicUsize>) -> Result<HttpResponse>
p404(repo_count)
}
#[get("/tacit-css.min.css")]
async fn css() -> HttpResponse {
HttpResponse::Ok().content_type("text/css").body(CSS)
/// A duration to add to current time for a far expires header.
static FAR: Duration = Duration::from_secs(180 * 24 * 60 * 60);
#[get("/static/{filename}")]
async fn static_file(
path: web::Path<String>,
repo_count: web::Data<AtomicUsize>,
) -> Result<HttpResponse> {
StaticFile::get(&path)
.map(|data| {
let far_expires = SystemTime::now() + FAR;
HttpResponse::Ok()
.insert_header(Expires(far_expires.into()))
.content_type(data.mime.clone())
.body(data.content)
})
.map(Result::Ok)
.unwrap_or_else(|| p404(repo_count))
}
#[get("/favicon.ico")]
async fn favicon32() -> HttpResponse {
HttpResponse::Ok().content_type("image/png").body(FAVICON)
let data = &template_statics::favicon32_png;
HttpResponse::Ok()
.content_type(data.mime.clone())
.body(data.content)
}
async fn start_server(listener: TcpListener, settings: Settings) -> std::io::Result<Server> {
@ -486,7 +505,7 @@ async fn start_server(listener: TcpListener, settings: Settings) -> std::io::Res
.wrap(middleware::NormalizePath::new(TrailingSlash::Trim))
.service(index)
.service(health_check)
.service(css)
.service(static_file)
.service(favicon32)
.service(generate)
.default_service(web::to(async_p404));

View File

@ -7,8 +7,6 @@ pub(crate) const VERSION_INFO: VersionInfo = VersionInfo {
commit: env!("VERGEN_GIT_SHA_SHORT"),
version: env!("CARGO_PKG_VERSION"),
};
pub(crate) const CSS: &str = include_str!("../static/tacit-css.min.css");
pub(crate) const FAVICON: &[u8] = include_bytes!("../static/favicon32.png");
lazy_static! {
pub(crate) static ref CLIENT: reqwest::Client = reqwest::Client::new();

View File

@ -1,3 +1,4 @@
@use super::statics::*;
@use crate::statics::VersionInfo;
@(title: &str, header: &str, content: Content, version_info: VersionInfo, repo_count: usize)
@ -9,7 +10,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="keywords" content="Hits-of-Code, GitHub, Badge" />
<meta name="description" content="Hits-of-Code Badges for Git repositories" />
<link rel="stylesheet" href="/tacit-css.min.css" />
<link rel="stylesheet" href="/static/@tacit_css_min_css.name" />
<title>@title</title>
</head>
<body>

80
vm.nix
View File

@ -1,80 +0,0 @@
# Nix configuration for a VM to run a custom configured Vim
#
# It is intended as an example of building a VM that builds Vim for testing
# and evaluation purposes. It does not represent a production or secure
# deployment.
{ sources ? import ./nix/sources.nix
, pkgs ? import sources.nixpkgs { }
, callPackage ? pkgs.callPackage
, config
, lib
, ...
}:
# config, pkgs, lib, ... }:
let
hoc = pkgs.callPackage ./default.nix { };
# hoc = cargoNix.rootCrate.build;
in
{
environment = {
systemPackages = with pkgs; [
(
hoc
# import ./default.nix
)
];
};
networking.hostName = "hoc"; # Define your hostname.
system.stateVersion = "19.09"; # The version of NixOS originally installed
# Set security options:
security = {
sudo = {
enable = true; # Enable sudo
wheelNeedsPassword = false; # Allow wheel members to run sudo without a passowrd
};
};
networking.firewall.allowedTCPPorts = [ 80 ];
# List services that you want to enable:
services.openssh = {
enable = true; # Enable the OpenSSH daemon.
#permitRootLogin = "yes"; # Probably want to change this in production
#challengeResponseAuthentication = true; # Probably want to change this in production
#passwordAuthentication = true; # Probably want to change this in production
openFirewall = true;
hostKeys = [
{
path = "/etc/ssh/ssh_host_ed25519_key"; # Generate a key for the vm
type = "ed25519"; # Use the current best key type
}
];
};
# Users of the Vim VM:
users.mutableUsers = false; # Remove any users not defined in here
users.users.root = {
password = "123456"; # Probably want to change this in production
};
# Misc groups:
users.groups.nixos.gid = 1000;
# NixOS users
users.users.nixos = {
isNormalUser = true;
uid = 1000;
group = "nixos";
extraGroups = [ "wheel" ];
password = "123456"; # Probably want to change this in production
};
}