Git Product home page Git Product logo

weathermen / soundstorm Goto Github PK

View Code? Open in Web Editor NEW
31.0 1.0 3.0 11.63 MB

The Federated Social Audio Platform

Home Page: https://docs.soundstorm.social

License: GNU General Public License v3.0

Ruby 75.25% Dockerfile 0.61% JavaScript 5.54% HTML 2.50% Shell 0.47% Makefile 1.00% SCSS 3.84% Haml 10.80%
gnu-social mastodon docker activity-stream webfinger social-network activitypub music audio ruby-on-rails

soundstorm's Introduction

Soundstorm

Tests Status Build Status Release Status Test Coverage Maintainability

The Federated Social Music Platform.

Soundstorm is an audio-oriented federated social network that speaks ActivityPub. Users can upload their own music, comment on others' tracks, and like/follow/mention just as in a regular social network. Since it speaks the same language as federated platforms like Mastodon, Soundstorm can send new track upload posts to users' followers on the fediverse, allowing them to gain a greater reach than a conventional social audio service.

Installation

Soundstorm is distributed as a Docker image for deployment ease. The reference instance, https://soundstorm.social, uses Amazon ECS for deployment, but the image is self-contained and can be run on any infrastructure. This image runs in RAILS_ENV=production mode by default, and comes pre-loaded with compiled assets and everything you'll need to run a Soundstorm instance in production.

First, pull down the latest production image:

docker pull weathermen/soundstorm

Create a .env file in the local dir for your configuration:

SOUNDSTORM_HOST=your.soundstorm.domain
DATABASE_URL=postgres://[email protected]:5432
REDIS_URL=rediss://[email protected]:6379
CDN_URL=https://cdn.soundstorm.domain
SMTP_USERNAME=your-smtp-server-user
SMTP_PASSWORD=your-smtp-server-password
SMTP_HOST=smtp.server.if.not.using.sendgrid.net
RAILS_SERVE_STATIC_FILES=true

Create the database, set up its schema, and load in seed data:

docker run --rm -it \
           --env-file .env \
           --env SOUNDSTORM_ADMIN_USERNAME=your-username \
           --env SOUNDSTORM_ADMIN_PASSWORD=your-password \
           --env [email protected] \
           weathermen/soundstorm \
           rails db:setup

You can now start the app server using the default container command. Make sure you have a Docker Network created so the container can talk to other neighboring containers:

docker network create soundstorm
docker create --env-file .env --network soundstorm weathermen/soundstorm

You'll still need to proxy requests from an HTTP server to the app server in order to process and terminate SSL. The soundstorm image does not come with SSL certificates built in, you'll need to either obtain one yourself or use the Caddy server to obtain them for you via LetsEncrypt.

Here's an example Caddyfile you can use:

your.soundstorm.host {
  log stdout
  errors stderr
  tls {
    dns route53
  }
  root /srv/public


  proxy / http://web:3000 {
    fail_timeout 300s
    transparent
    websocket
    header_upstream X-Forwarded-Ssl on
  }
}

Start the Caddy server like this:

docker pull abiosoft/caddy
docker create \
  --volume $(pwd)/Caddyfile:/etc/Caddyfile \
  --volume $HOME/.caddy:/root/.caddy \
  --publish 80:80 \
  --publish 443:443 \
  --network soundstorm
  abisoft/caddy

Development

The above goes into installing Soundstorm for real-world use, but you may also want to contribute to the project in some way. Developing on Soundstorm also requires the use of Docker.

First, make sure your $COMPOSE_FILE is set, so that development-level configuration is included whenever docker-compose is in use:

export COMPOSE_FILE="docker-compose.yml:docker-compose.development.yml"

Next, set up the database:

docker-compose run --rm web rails db:setup

You can now start all services:

docker-compose up

Once the web app loads, browse to http://localhost:3000 and log in with username admin and password Password1!. This is configurable by setting $SOUNDSTORM_ADMIN_USERNAME and $SOUNDSTORM_ADMIN_PASSWORD as environment variables when running db:setup.

For more information on making contributions to this project, read the [contributing guide][].

Deployment

Soundstorm can be easily deployed to your Docker Machine with the provided production configuration:

source .env # see "Installation" above
docker-machine create soundstorm
eval "$(docker-machine env soundstorm)"
docker-compose -f docker-compose.yml -f docker-compose.production.yml up

However, https://soundstorm.social, our reference implementation, is hosted on [Heroku][]. The make deploy task performs the commands needed to deploy the local production images you've already built to the Heroku platform. It uses the docker CLI to push images to Heroku's container registry, and the heroku CLI to start those new containers in the production environment.

soundstorm's People

Contributors

dependabot[bot] avatar tubbo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

soundstorm's Issues

Project status?

Hi! Looks like you have a fairly complete AP implementation here. I was looking to add the project to the Feneas AP watchlist, but that depends on project status.

Is the project still alive? (If not I might still add to the "It's dead, Jim" section of the list).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.