No description
Find a file
2020-01-22 15:01:27 +01:00
.circleci Drop support for Ruby 2.4 from CircleCI (#12834) 2020-01-15 07:45:00 +01:00
.dependabot Change dependabot update schedule from live to weekly (#10949) 2019-06-04 11:23:19 +02:00
.github Merge branch 'master' into glitch-soc/merge-upstream 2019-11-20 15:36:09 +01:00
app Put a max-size on inlined images 2020-01-22 15:01:27 +01: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-01-22 14:54:33 +01:00
db Merge branch 'master' into glitch-soc/merge-upstream 2020-01-12 15:57:34 +01:00
dist Add TLS v1.3 support (#11603) 2019-08-30 07:42:50 +02:00
lib Merge branch 'master' into glitch-soc/merge-upstream 2020-01-12 15:57:34 +01: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 2019-11-20 15:36:09 +01:00
spec Merge branch 'master' into glitch-soc/merge-upstream 2020-01-12 15:57:34 +01:00
streaming Merge branch 'master' into glitch-soc/merge-upstream 2019-07-30 12:22:33 +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 Update ESLint and RuboCop in Code Climate (#12534) 2019-12-02 18:25:43 +01: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 2019-12-28 17:48:40 +01: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 Use eslint cache (#12668) 2019-12-23 07:27:55 +01:00
.gitlab-ci.yml Add GitLab CI config 2020-01-22 14:36:18 +01: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 Node.js to v8.x on nvmrc (#8023) 2018-07-15 12:29:17 +09: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 Update ESLint and RuboCop in Code Climate (#12534) 2019-12-02 18:25:43 +01:00
.ruby-version Use Ruby 2.6.5 (#12049) 2019-10-02 04:54:32 +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-01-22 14:40:47 +01: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-01-22 14:36:08 +01:00
CHANGELOG.md Update changelog for 3.0.1 (#12139) 2019-10-10 07:03:05 +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 Add healthcheck endpoint for web (#11770) 2019-09-07 02:47:51 +02:00
Dockerfile Upgrade Node v12 in Dockerfile (#12703) 2019-12-30 07:41:40 +01:00
Gemfile Merge branch 'master' into glitch-soc/merge-upstream 2020-01-20 18:31:11 +01:00
Gemfile.lock Merge branch 'master' into glitch-soc/merge-upstream 2020-01-20 18:31:11 +01: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-01-22 14:40:50 +01: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-01-22 14:36:17 +01: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 2019-03-10 16:48:44 +01:00
yarn.lock remove bundle analyzer, remove chunk hashes from css, create build.sh 2020-01-22 14:40:47 +01: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.