Commit Graph

2084 Commits (72a13d83539a4df7c0f126b5854642e210c506b0)
 

Author SHA1 Message Date
Charles Hall 72a13d8353 Merge branch 'flake-compat' into 'next'
support non-flake users

See merge request famedly/conduit!581
7 months ago
Raito Bezarius 3a63f9dfb6
feat: support non-flake users
This uses flakes-compat to read the `flake.nix` and expose it
to non-flake users.

Signed-off-by: Raito Bezarius <masterancpp@gmail.com>
7 months ago
Timo Kösters f4f2d05b5b Merge branch 'update-ring' into 'next'
update ring to ^0.17

See merge request famedly/conduit!580
7 months ago
Charles Hall c3c7bcb2ed Merge branch 'publish-oci-image' into 'next'
Publish oci image to the gitlab registry

See merge request famedly/conduit!570
7 months ago
Samuel Meenzen d6c57f9b2e Publish oci image to the gitlab registry 7 months ago
Charles Hall 7fb9e99649
update ring and jsonwebtoken to remove ring ^0.16 7 months ago
Charles Hall 1274b48ebb
run `cargo update`
`IndexMap::remove` was deprecated in favor of explicitly named methods.
I assume that we actually needed to be using `shift_remove`, otherwise
we probably wouldn't be bothering with `indexmap` here in the first
place. I wonder if this fixes any bugs lol
7 months ago
Charles Hall 0a281e81a5 Merge branch 'fix-oci-image-cross' into 'next'
pass pkgsCrossStatic to mkOciImage, not pkgsHost

See merge request famedly/conduit!579
7 months ago
Charles Hall a43bde69fa
pass pkgsCrossStatic to mkOciImage, not pkgsHost
This fixes a bug where the aarch64 OCI image had metadata saying it was
an x86_64 OCI image. On top of that, I think the metadata was actually
right (aside from Conduit's binary): since all other packages were being
pulled from `pkgsHost`, an OCI image cross compiled for aarch64 from a
different architecture would result in unexecutable binaries (e.g. tini)
since they were compiled for the completely wrong architecture.
7 months ago
Charles Hall 986343877c Merge branch 'artifact-links' into 'next'
update DEPLOY.md with new build links

See merge request famedly/conduit!578
7 months ago
Charles Hall 2d47710b55
update DEPLOY.md with new build links 7 months ago
Charles Hall 10542a1d70 Merge branch 'use-upstream-crane' into 'next'
switch crane input back to upstream

See merge request famedly/conduit!576
7 months ago
Charles Hall c167f7a6ad
switch crane input back to upstream
Thanks to the crane maintainer to fixing my issue in a way that doesn't
suck, unlike my attempt in the fork we were briefly using.
7 months ago
Charles Hall 5787a70bab Merge branch 'fix-complement' into 'next'
make complement (mostly) work again

See merge request famedly/conduit!575
7 months ago
Charles Hall cf8f1f2546
make a bunch of changes so complement works again
Well, kinda. It crashed on me after 10 minutes because the tests timed
out like in <https://github.com/matrix-org/complement/issues/394>.
Sounds like this means it's a them problem though.

I want to use Nix to build this image instead in the future but this
will at least make it work for now and give me a reference for while I'm
porting it. I also want to make Conduit natively understand Complement's
requirements instead of `sed`ing a bunch of stuff and needing a reverse
proxy in the container. Should be more reliable that way.

I'm not making this run in CI until the above stuff is addressed and
until I can decide on a way to pin the revision of Complement being
tested against.
7 months ago
Charles Hall 3c2fc4a4c6 Merge branch 'oci-image-ca-certs' into 'next'
add ca certificates to the OCI image

See merge request famedly/conduit!574
7 months ago
Charles Hall dffd771e7c
add ca certificates to the OCI image
Without this, checking the authority of TLS certificates fails, making
Conduit (rightly) refuse to connect to anything.
7 months ago
Charles Hall 4da8c7e282 Merge branch 'docker-tag' into 'next'
change docker tag back to `next`

See merge request famedly/conduit!573
7 months ago
Charles Hall 0df5d18fd6
change docker tag back to `next`
I misunderstood what the general meaning of the `latest` tag was.
7 months ago
Charles Hall 825ceac1c3 Merge branch 'update-rust' into 'next'
update rust toolchain

See merge request famedly/conduit!572
7 months ago
Charles Hall 3e389256f5
switch lint config to `manifest-lint` feature
I removed some lint configuration in the process:

* `#[allow(clippy::suspicious_else_formatting)]` because nothing is
  currently triggering it.
* `#[warn(clippy::future_not_send)]` because some stuff under
  `src/lib.rs` is. And also like, auto-trait leakage generally means
  this isn't a problem, and if things really need to be `Send`, then
  you'll probably know to mark it manually.
* `#[warn(rust_2018_idioms)]` and replaced it with
  `explicit-outlives-requirements = "warn"` which is the most useful
  lint in that group that isn't enabled by default.
7 months ago
Charles Hall a7892a28ec
refer directly to stdenv since it's in scope 7 months ago
Charles Hall 9453dbc740
update rust toolchain
It comes with a bunch of new lints (yay!) so I fixed them all so CI will
keep working.

Also apparently something about linking changed because I had to change
the checks for deciding the linker flags for static x86_64 builds to
keep working.
7 months ago
Charles Hall bf48c10d28 Merge branch 'cross' into 'next'
cross compile static binaries for x86_64 and aarch64

See merge request famedly/conduit!569
7 months ago
Charles Hall 7c1a3e41d9
add package to build an aarch64 oci image
And build it as an artifact in CI.
7 months ago
Charles Hall 2a04a361e0
break oci image builder into a function
Now it can be reused for different `pkgs` and `package`s.
7 months ago
Charles Hall 0e8e4f1083
add static cross to aarch64-unknown-linux-musl 7 months ago
Charles Hall 81ae579b25
add static cross to x86_64-unknown-linux-musl 7 months ago
Charles Hall 3a3cafe912
preempt cross problems by using my crane fork
I imagine this will get fixed/merged upstream in the near future.
7 months ago
Charles Hall d29591d47d
group packages in attrset literal
This will make generating packages for cross possible.
7 months ago
Charles Hall 67d280dd2e
factor package expression into a function
We'll need to call it repeatedly to make packages for cross.
7 months ago
Charles Hall 3ac9be5a78
add x86_64-unknown-linux-gnu
This is probably the most common target and usually doesn't involve
cross compilation.
7 months ago
Charles Hall 52954f7a11
use fromToolchainFile
I *think* this will make it easier to pull in extra rustc targets.
7 months ago
Charles Hall 692a31620d
make let bindings take pkgs as an argument
Again, will make cross compilation easier to set up.
7 months ago
Charles Hall cf4015b830
rename pkgs to pkgsHost
This will make organizing cross compilation easier.
7 months ago
Charles Hall 9cef03127b
remove `with` for `nativeBuildInputs`
It's going to get more involved and that `with` was too specific.
7 months ago
Charles Hall 249fc7769d
don't bother with mold
For now, at least. I suspect it will make cross compilation more
difficult.
7 months ago
Charles Hall 5cc53c9e14
push oci image and x86_64-*-gnu build to bin cache
This will allow most Nix users to use the `default` package and without
having to build from source. And also allows any weirdos to get the OCI
image from the Nix binary cache if they want. No idea why that would be
desireable though lol
7 months ago
Charles Hall bdc46f6392
add script to build and push to binary cache
This is even useful for local development, as you can pre-populate the
binary cache before running CI (assuming you have the token). Also, it
being in a script makes it easier to test.

We've added attic as a flake input even though the flake itself doesn't
use it so that we can use `--inputs-from .` in Nix commands to reference
a locked version of attic. This helps with reproducibility and caching,
and to makes it easy to update attic because it's part of the normal
flake lifecycle.
7 months ago
Charles Hall 6ae776218c
add our own binary cache
The machine I'm hosting this on doesn't have incredible upload speeds
but it should be good enough?
7 months ago
Charles Hall bd2b146d5d
add crane binary cache
This way we don't need to build e.g. crane-utils every time.
7 months ago
Charles Hall f7cc4fb3bb
state artifacts' targets and rename artifacts
This will make it more obvious what's what and be more internally
consistent.
7 months ago
Charles Hall ca198c51fa Merge branch 'reqwest-follow-up' into 'next'
move resolver logic into the resolver

See merge request famedly/conduit!571
7 months ago
Charles Hall fe86d28428
move resolver logic into the resolver
Honestly not sure why it wasn't done like this before. This code is much
less awkward to follow and more compartmentalized.

These changes were mainly motivated by a clippy lint triggering on the
original code, which then made me wonder if I could get rid of some of
the `Box`ing. Turns out I could, and this is the result of that.
7 months ago
Timo Kösters c86f9a5c5b Merge branch 'pr_upstream_reqwest' into 'next'
Use upstream `reqwest` instead of vendored one

See merge request famedly/conduit!527
7 months ago
Timo Kösters e0358a9de5 Merge branch 'send_push_to_invited_user' into 'next'
feat: send push notification on invite to invited user and etc

Closes #399

See merge request famedly/conduit!559
7 months ago
Tobias Bucher 69d0003222 Use upstream `reqwest` instead of vendored one
This uses the `ClientBuilder::dns_resolver` function that was added in
reqwest 0.11.13, instead of the homebrew `ClientBuilder::resolve_fn`.
7 months ago
Timo Kösters 5cf9f3df48 Merge branch 'lints' into 'next'
fix CI

See merge request famedly/conduit!564
7 months ago
Charles Hall 0b7ed5adc9
add debian package building in ci
This uses a separate step and docker image, which I'm not a huge fan of.
At least I could get this to work for now, but I won't be shocked when
it breaks later. I know, I know, fixing this kind of problem is the
exact reason I bothered to do this, but I was really struggling to do
better here. Maybe I can take a second pass at this later.

Also, this explicitly names the caches, because without this, various
things related to linking will break.
7 months ago
Charles Hall 4de54db305
redo docker image and build it in ci 7 months ago