Merge branch 'master' into skylight
This commit is contained in:
commit
4d1217d8f9
|
@ -5,3 +5,4 @@ public/assets
|
|||
node_modules
|
||||
storybook
|
||||
neo4j
|
||||
vendor/bundle
|
||||
|
|
|
@ -1,2 +1,5 @@
|
|||
node_modules/
|
||||
.cache/
|
||||
docs/
|
||||
spec/
|
||||
storybook/
|
||||
|
|
|
@ -5,7 +5,7 @@ ENV RAILS_ENV=production \
|
|||
|
||||
WORKDIR /mastodon
|
||||
|
||||
COPY . /mastodon
|
||||
COPY Gemfile Gemfile.lock package.json yarn.lock /mastodon/
|
||||
|
||||
RUN BUILD_DEPS=" \
|
||||
postgresql-dev \
|
||||
|
@ -28,4 +28,6 @@ RUN BUILD_DEPS=" \
|
|||
&& apk del $BUILD_DEPS \
|
||||
&& rm -rf /tmp/* /var/cache/apk/*
|
||||
|
||||
COPY . /mastodon
|
||||
|
||||
VOLUME /mastodon/public/system /mastodon/public/assets
|
||||
|
|
|
@ -58,15 +58,15 @@ class FanOutOnWriteService < BaseService
|
|||
Rails.logger.debug "Delivering status #{status.id} to hashtags"
|
||||
|
||||
status.tags.pluck(:name).each do |hashtag|
|
||||
Redis.current.publish("hashtag:#{hashtag}", @payload)
|
||||
Redis.current.publish("hashtag:#{hashtag}:local", @payload) if status.local?
|
||||
Redis.current.publish("timeline:hashtag:#{hashtag}", @payload)
|
||||
Redis.current.publish("timeline:hashtag:#{hashtag}:local", @payload) if status.local?
|
||||
end
|
||||
end
|
||||
|
||||
def deliver_to_public(status)
|
||||
Rails.logger.debug "Delivering status #{status.id} to public timeline"
|
||||
|
||||
Redis.current.publish('public', @payload)
|
||||
Redis.current.publish('public:local', @payload) if status.local?
|
||||
Redis.current.publish('timeline:public', @payload)
|
||||
Redis.current.publish('timeline:public:local', @payload) if status.local?
|
||||
end
|
||||
end
|
||||
|
|
|
@ -70,14 +70,14 @@ class RemoveStatusService < BaseService
|
|||
|
||||
def remove_from_hashtags(status)
|
||||
status.tags.pluck(:name) do |hashtag|
|
||||
Redis.current.publish("hashtag:#{hashtag}", @payload)
|
||||
Redis.current.publish("hashtag:#{hashtag}:local", @payload) if status.local?
|
||||
Redis.current.publish("timeline:hashtag:#{hashtag}", @payload)
|
||||
Redis.current.publish("timeline:hashtag:#{hashtag}:local", @payload) if status.local?
|
||||
end
|
||||
end
|
||||
|
||||
def remove_from_public(status)
|
||||
Redis.current.publish('public', @payload)
|
||||
Redis.current.publish('public:local', @payload) if status.local?
|
||||
Redis.current.publish('timeline:public', @payload)
|
||||
Redis.current.publish('timeline:public:local', @payload) if status.local?
|
||||
end
|
||||
|
||||
def redis
|
||||
|
|
|
@ -46,7 +46,7 @@ class ImportWorker
|
|||
|
||||
begin
|
||||
FollowService.new.call(from_account, row[0])
|
||||
rescue Goldfinger::Error, HTTP::Error, OpenSSL::SSL::SSLError
|
||||
rescue Mastodon::NotPermittedError, ActiveRecord::RecordNotFound, Goldfinger::Error, HTTP::Error, OpenSSL::SSL::SSLError
|
||||
next
|
||||
end
|
||||
end
|
||||
|
|
|
@ -8,6 +8,6 @@ Scalingo guide
|
|||
* You can use a .scalingo.io domain, which will be simple to set up, or you can use a custom domain.
|
||||
* You will want Amazon S3 for file storage. The only exception is for development purposes, where you may not care if files are not saved. Follow a guide online for creating a free Amazon S3 bucket and Access Key, then enter the details.
|
||||
* If you want your Mastodon to be able to send emails, configure SMTP settings here (or later). Consider using [Mailgun](https://mailgun.com) or similar, who offer free plans that should suit your interests.
|
||||
3. Deploy! The app should be set up, with a working web interface and database. You can change settings and manage versions from the Heroku dashboard.
|
||||
3. Deploy! The app should be set up, with a working web interface and database. You can change settings and manage versions from the Scalingo dashboard.
|
||||
|
||||
You may need to use the `scalingo` CLI application to run `USERNAME=yourUsername rails mastodon:make_admin` to make yourself an admin.
|
||||
To make yourself an admin, you can use the `scalingo` CLI: `scalingo run -e USERNAME=yourusername rails mastodon:make_admin`.
|
||||
|
|
|
@ -17,6 +17,8 @@ To create and provision a new virtual machine for Mastodon development:
|
|||
cd mastodon
|
||||
vagrant up
|
||||
|
||||
**Note:** On Linux hosts, you will need to [enable NFS support](https://www.vagrantup.com/docs/synced-folders/nfs.html).
|
||||
|
||||
Running `vagrant up` for the first time will run provisioning, which will:
|
||||
|
||||
- Download the Ubuntu 14.04 base image, if there isn't already a copy on your machine
|
||||
|
@ -61,4 +63,4 @@ To run the `rspec` tests and `rubocop` style checker, you may either:
|
|||
|
||||
## Support/help
|
||||
|
||||
If you are confused, or having any issues with the above, the Mastodon IRC channel ( irc.freenode.net #mastodon ) is a good place to find assistance.
|
||||
If you are confused, or having any issues with the above, the Mastodon IRC channel ( irc.freenode.net #mastodon ) is a good place to find assistance.
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "Mastodon",
|
||||
"description": "A GNU Social-compatible microblogging server",
|
||||
"repository": "https://github.com/johnsudaar/mastodon",
|
||||
"repository": "https://github.com/tootsuite/mastodon",
|
||||
"logo": "https://github.com/tootsuite/mastodon/raw/master/app/assets/images/logo.png",
|
||||
"env": {
|
||||
"LOCAL_DOMAIN": {
|
||||
|
|
Reference in a new issue