New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mastodon #24600

Closed
chris-martin opened this Issue Apr 3, 2017 · 18 comments

Comments

Projects
None yet
9 participants
@chris-martin
Contributor

chris-martin commented Apr 3, 2017

There's a lot of talk on Mastodon about wanting more people to run servers. The current recommended deploy environment is Docker. It'd be nice if we could provide NixOS support. I've already seen several of y'all on Mastodon, so we ought to be able to get this done 😃 I may work on this myself if I find time.

@Profpatsch

This comment has been minimized.

Member

Profpatsch commented Apr 6, 2017

Any update?

@chris-martin

This comment has been minimized.

Contributor

chris-martin commented Apr 6, 2017

Not from me, I've been spending all my time shooting the shit on Mastodon.

@fpletz

This comment has been minimized.

Member

fpletz commented Apr 6, 2017

It's on my immediate todo-list. Probably this weekend.

As it's a rails app and I've already done lots of rails nixos modules, it should be easy. If anyone wants to beat me, just look at the gitlab or frab module.

@ashkitten

This comment has been minimized.

Contributor

ashkitten commented Apr 9, 2017

This would be really neat! How's it coming along?

@fpletz

This comment has been minimized.

Member

fpletz commented Apr 9, 2017

Unfortunately it's little bit more complicated because it needs lots of NodeJS dependencies for the frontend stuff and node2nix fails to produce working nix expressions. Also, some gems need overrides because they won't build either.

@ashkitten

This comment has been minimized.

Contributor

ashkitten commented Apr 9, 2017

Ah that sucks. Let me know if there's anything I can do to help, but i'm just a newbie to NixOS really.

@chris-martin

This comment has been minimized.

Contributor

chris-martin commented Apr 11, 2017

Is it feasible to half-ass the JS/Ruby dependencies by just pulling them at runtime when the server starts?

@chris-martin

This comment has been minimized.

Contributor

chris-martin commented Apr 14, 2017

Just tried running node2nix 1.2.0 on Mastodon master.

error: ‘buildNodePackage’ at /home/chris/code/mastodon/node-env.nix:198:22 called without required argument ‘version’, at /home/chris/code/mastodon/node-packages.nix:16677:13

Line 16677. Wow. That seems like... a lot of output.

@taohansen

This comment has been minimized.

taohansen commented Apr 20, 2017

Where are we on this? Can I help?

@paperdigits

This comment has been minimized.

Contributor

paperdigits commented May 18, 2017

Is there an update to this? I'd be awesome to deploy mastodon on Nix!

@erictapen

This comment has been minimized.

Contributor

erictapen commented Feb 6, 2018

I think I'm doing some progress on this. I can't reproduce the failing node2nix anymore and I managed to build the ruby environment (took some overrides as @fpletz suggested).

My progress is currently here.

I never really tested running the server yet, as there is quite a lot to do before that works. But I think, that the dependencies are almost in place.

Biggest pain point atm is the Node environment. I basically copied the approach from base-16-builder. That builds, but what bothers me is

Would be nice if someone with more NodeJS domain knowledge would look onto that.

@andir

This comment has been minimized.

Member

andir commented Feb 6, 2018

Do you know what would be required to test that using VM tests?

I was thinking of having 2 mastodon instances and maybe using API-clients to post and fetch messages?

@erictapen

This comment has been minimized.

Contributor

erictapen commented Feb 6, 2018

I never looked into NixOS VM tests, but iirc Mastodon would be well suited for that. One could test federation and client-server-communication as you described.

This would definitely depend on a working service expression. Additionally there needs to be a way to create users from the command line (I'm sure there is) and a Mastodon CLI client (there are some).

@erictapen

This comment has been minimized.

Contributor

erictapen commented Mar 27, 2018

I made the mistake to take a break in the development. In that time, Nixpkgs moved considerably as well as Mastodon. The package doesn't even build anymore.

This might be too complex for my current state of knowledge of Ruby and Node. I give up.

I rebased my progress ontop of nixos-unstable and added a minor fix. Maybe someone else has luck with it:

https://github.com/erictapen/nixpkgs/tree/mastodon

If I ever try to package a Fediverse app again, I may try Pleroma, which seems to be more leightweight.

@ghost ghost referenced this issue Apr 25, 2018

Open

Pleroma #39479

@brainrape

This comment has been minimized.

Contributor

brainrape commented Sep 3, 2018

Can we close this until someone opens a PR? Seems to have lost momentum.

@erictapen

This comment has been minimized.

Contributor

erictapen commented Sep 3, 2018

I'd think it would make sense to close it. Haven't heard of any progress in a while.

@brainrape

This comment has been minimized.

Contributor

brainrape commented Sep 13, 2018

@chris-martin Can we close this until someone opens a PR?

@chris-martin

This comment has been minimized.

Contributor

chris-martin commented Sep 13, 2018

Sounds reasonable to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment