No description
Find a file
2020-05-20 08:00:02 +02:00
.circleci Fix the circleci packages for Buster. (#13583) 2020-05-01 23:45:40 +02:00
.dependabot Increase dependabot dependencies scope from security-only. (#13400) 2020-04-06 09:43:55 +02:00
.github Merge branch 'master' into glitch-soc/merge-upstream 2019-11-20 15:36:09 +01:00
app Revert: Resize images before upload in web UI to reduce bandwidth 2020-05-20 08:00:02 +02:00
bin Bump webpacker from 3.5.5 to 4.0.2 (#10277) 2019-03-15 15:05:31 +01:00
config config/webpack/production.js: Remove caching in OfflinePlugin (introduced in 0692991b5) 2020-05-20 08:00:02 +02:00
db Merge branch 'master' into glitch-soc/merge-upstream 2020-05-13 22:11:49 +02:00
dist Update nginx.conf (#13066) 2020-03-08 16:04:25 +01:00
lib Merge branch 'master' into glitch-soc/merge-upstream 2020-05-14 18:49:10 +02:00
log Initial commit 2016-02-20 22:53:20 +01:00
nanobox Resync Nanobox files with the 2.9.0 release (#11083) 2019-06-14 14:52:31 +02:00
public Merge branch 'master' into glitch-soc/merge-upstream 2020-05-10 16:19:56 +02:00
spec Merge branch 'master' into glitch-soc/merge-upstream 2020-05-13 22:11:49 +02:00
streaming Merge branch 'master' into glitch-soc/merge-upstream 2020-05-10 16:19:56 +02:00
vendor Increase files checked by ESLint (#9705) 2019-01-04 11:28:38 +01:00
.buildpacks Add ffmpeg buildpack for scalingo (#8500) 2018-08-29 01:21:23 +02:00
.codeclimate.yml Bump rubocop from 0.79.0 to 0.82.0 (#13677) 2020-05-08 20:24:26 +02:00
.dockerignore Add .bundle to .dockerignore (#7895) 2018-06-26 20:33:29 +02:00
.editorconfig Add final newline to locale files (#2890) 2017-05-07 19:55:47 +02:00
.env.nanobox Fix sample SAML_ACS_URL, SAML_ISSUER (#12669) 2019-12-23 18:12:22 +01:00
.env.production.sample Merge branch 'master' into glitch-soc/merge-upstream 2020-05-10 16:19:56 +02:00
.env.test Bump webpacker from 4.0.7 to 4.2.0 (#12416) 2019-11-20 17:56:11 +01:00
.env.vagrant fix vagrant connection error (#12180) 2019-10-24 22:47:24 +02:00
.eslintignore Increase files checked by ESLint (#9705) 2019-01-04 11:28:38 +01:00
.eslintrc.js Refactor icons in web UI to use Icon component (#9951) 2019-02-01 00:14:05 +01:00
.foreman Replace sprockets/browserify with Webpack (#2617) 2017-05-03 02:04:16 +02:00
.gitattributes Add .gitattributes file to avoid unwanted CRLF (#3954) 2017-06-26 13:15:24 +02:00
.gitignore Add new vagrant log files to .gitignore (#13442) 2020-04-12 13:37:34 +02:00
.gitlab-ci.yml Add GitLab CI config 2020-05-20 07:58:08 +02:00
.gitmodules Rename themes -> flavours ? ? 2017-12-03 23:26:40 -08:00
.haml-lint.yml Added haml-lint and fix warnings (#2773) 2017-05-08 03:35:25 +02:00
.nanoignore Remove Storybook (#4397) 2017-07-27 22:30:27 +02:00
.nvmrc Upgrade .nvmrc to Node.js 12 (#12906) 2020-01-21 12:42:13 +01:00
.profile Add ffmpeg and dependent packages as well as LD_LIBRARY_PATHs (#3276) 2017-05-24 17:57:33 +02:00
.rspec Adding a Mention model, test stubs 2016-02-25 00:17:01 +01:00
.rubocop.yml fix rubocop errors (#13690) 2020-05-10 16:42:48 +02:00
.ruby-version Update .ruby-version (#13395) 2020-04-05 13:58:43 +02:00
.sass-lint.yml Fix sass-lint config (#10982) 2019-06-06 18:51:46 +02:00
.slugignore Remove Storybook (#4397) 2017-07-27 22:30:27 +02:00
.yarnclean Replace from scss-lint to sass-lint (#10958) 2019-06-04 17:23:18 +02:00
app.json Remove deprecated config from Heroku and Scalingo (#11925) 2019-09-23 12:11:59 +02:00
Aptfile Adjust Aptfile for Heroku-18 stack (#8588) 2018-09-09 02:10:58 +02:00
AUTHORS.md Update AUTHORS.md (#12096) 2019-10-07 04:36:32 +02:00
babel.config.js Remove unnecessary dependencies (#12533) 2019-12-02 13:38:53 +01:00
boxfile.yml Correct the Nanobox deploy hooks for order and context (#12663) 2019-12-22 08:55:27 +01:00
build.sh remove bundle analyzer, remove chunk hashes from css, create build.sh 2020-05-20 07:59:57 +02:00
Capfile remove capistrano/faster_assets from Capfile (#2737) 2017-05-03 12:14:52 +02:00
Changelog-mastofe.txt Changelog-mastofe.txt: Init distribution 2020-05-20 07:58:06 +02:00
CHANGELOG.md Bump version to 3.1.4 (#13750) 2020-05-14 07:46:11 +02:00
CODE_OF_CONDUCT.md Change e-mail contact for CoC enforcement 2019-06-06 17:42:07 +02:00
config.ru Fix rubocop issues, introduce usage of frozen literal to improve performance 2016-11-15 16:56:29 +01:00
CONTRIBUTING.md Merge branch 'master' into glitch-soc/merge-upstream 2019-11-20 15:36:09 +01:00
crowdin.yml Update Crowdin configuration file 2019-09-14 11:40:13 +02:00
docker-compose.yml increase the postgres container shm_size from 64mb to 256mb (#13451) 2020-04-12 16:41:54 +02:00
Dockerfile [Security] Update Dockerfile for Ruby 2.6.6 (#13393) 2020-04-05 12:52:07 +02:00
Gemfile Merge branch 'master' into glitch-soc/merge-upstream 2020-05-13 22:11:49 +02:00
Gemfile.lock Merge branch 'master' into glitch-soc/merge-upstream 2020-05-13 22:11:49 +02:00
ide-helper.js Add JS IDE helper (#13012) 2020-04-27 17:19:53 +02:00
LICENSE Fix #49 - License changed from GPL-2.0 to AGPL-3.0 2016-09-21 23:04:34 +02:00
package.json package.json: Add description field 2020-05-20 07:59:59 +02:00
postcss.config.js Increase files checked by ESLint (#9705) 2019-01-04 11:28:38 +01:00
priv-config TOR federation (#7875) 2018-06-26 20:34:12 +02:00
Procfile Bind servers to 0.0.0.0 in Procfile (#11378) 2019-07-22 06:16:30 +02:00
Procfile.dev Fix Procfile on OS X (#6748) 2018-03-12 03:50:40 +01:00
Rakefile Initial commit 2016-02-20 22:53:20 +01:00
README.md README.md: full rewrite for pleroma 2020-05-20 07:58:08 +02:00
scalingo.json Remove deprecated config from Heroku and Scalingo (#11925) 2019-09-23 12:11:59 +02:00
Vagrantfile Merge branch 'master' into glitch-soc/merge-upstream 2020-04-04 21:47:37 +02:00
yarn.lock remove bundle analyzer, remove chunk hashes from css, create build.sh 2020-05-20 07:59:57 +02:00

Mastodon Frontend, Glitch-soc + Pleroma Edition

Here is a distribution of the glitch-soc frontend for pleroma. Everything from the upstream repository is kept and rebased on for easy updates, this does screws up on Merge Requests so theyll be treated as a patchset if done here.

Fork vs. Distribution

This repository is not a fork of glitch-soc, there is only a few patches on it that are kept and designed to be easily removable if it needs to (for example when upstream does one of our features on their side too). This also means that there is no merge, only one big rebase to get the patches up-to-date. See the Development section for more information.

Deployement

Fetching CI artifacts

Pleroma (backend) has a shell script in installation/download-mastofe-build.sh which can be used to get a build from the CI artifacts, by default it will install the one from rebase/glitch-soc into instance/static (so you can revert to the bundled frontend by removing it and it is free from git conflicts), this behaviour can be changed by modifying the first lines of the script.

Updating the bundle

This is what you want to do to update the mastofe bundled with pleroma.

  • Run build.sh at the root of this repo, you can set the TARGET environment variable if pleroma isnt at ../pleroma (default value of TARGET)
  • Go to pleroma repo:
    • git add priv/static/sw.js priv/static/packs
    • git commit -m "update mastofe"

Development

Branches

  • pleroma branch which get re-referenced to rebase/glitch-soc once it is stable
  • master: Same branch as upstream repository, should be updated before doing an updating rebase
  • rebase/glitch-soc: branch which rebases from upstream, used for testing

For developement/Merge Requests I would suggest to use master when you are introducing new modifications that cannot be in the upstream, and when you are changing current modifications prefer rebase/glitch-soc.

Never use pleroma as a base for Merge Requests, it is not meant to be modified directly.

Changelog

There is a Changelog-mastofe.txt file used to do the release notes for the message on tagging a new release. It is cleaned when updating from upstream (git filter-branch should be a nice friend). Changes on the behaviour of the frontend should be noted in this file together with their modification (commit at best, MR at worst).

Tools

  • Node.js
  • yarn (preferred) or npm
  • HTTP proxy (such as nginx)

nginx setup

I'll assume that you have already fired up pleroma using the installation guide. To work on the frontend while still having the backend up, use this nginx config.

server {
    listen 80;
    server_name pleroma.testing;

    location /packs {
        add_header 'Access-Control-Allow-Origin' '*';
        proxy_http_version 1.1;
        proxy_set_header Host $http_host;

        proxy_pass http://localhost:3035;
    }

    location / {
        add_header 'Access-Control-Allow-Origin' '*';
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_set_header Host $http_host;

        proxy_pass http://localhost:4000;
    }
}

Change the server_name if you like. I personally like to create a new entry in /etc/hosts and add 127.0.0.1 pleroma.testing, but you do what suits you.

Running

  • Getting the node dependencies is done with yarn install -D (or npm install if you dont have yarn)
  • Launching the frontend is done with npm run dev. It should be reachable once it finnishes compiling.