superfast 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.dockerignore +47 -0
- data/.kamal/hooks/docker-setup.sample +3 -0
- data/.kamal/hooks/post-deploy.sample +14 -0
- data/.kamal/hooks/post-proxy-reboot.sample +3 -0
- data/.kamal/hooks/pre-build.sample +51 -0
- data/.kamal/hooks/pre-connect.sample +47 -0
- data/.kamal/hooks/pre-deploy.sample +109 -0
- data/.kamal/hooks/pre-proxy-reboot.sample +3 -0
- data/.kamal/secrets +17 -0
- data/.rubocop.yml +17 -0
- data/.ruby-version +1 -0
- data/CHANGELOG.md +5 -0
- data/CODE_OF_CONDUCT.md +73 -0
- data/Dockerfile +77 -0
- data/LICENSE +21 -0
- data/README.md +64 -0
- data/Rakefile +6 -0
- data/SECURITY.md +23 -0
- data/app/assets/images/.keep +0 -0
- data/app/assets/stylesheets/application.css +10 -0
- data/app/controllers/application_controller.rb +4 -0
- data/app/controllers/concerns/.keep +0 -0
- data/app/helpers/application_helper.rb +2 -0
- data/app/javascript/application.js +3 -0
- data/app/javascript/controllers/application.js +9 -0
- data/app/javascript/controllers/hello_controller.js +7 -0
- data/app/javascript/controllers/index.js +4 -0
- data/app/jobs/application_job.rb +7 -0
- data/app/mailers/application_mailer.rb +4 -0
- data/app/models/application_record.rb +3 -0
- data/app/models/concerns/.keep +0 -0
- data/app/views/layouts/application.html.erb +28 -0
- data/app/views/layouts/mailer.html.erb +13 -0
- data/app/views/layouts/mailer.text.erb +1 -0
- data/app/views/pwa/manifest.json.erb +22 -0
- data/app/views/pwa/service-worker.js +26 -0
- data/assets/fibery.png +0 -0
- data/assets/superfast.png +0 -0
- data/assets/zulip.png +0 -0
- data/bin/brakeman +7 -0
- data/bin/bundle +109 -0
- data/bin/bundle.cmd +112 -0
- data/bin/dev +2 -0
- data/bin/docker-entrypoint +14 -0
- data/bin/importmap +4 -0
- data/bin/jobs +6 -0
- data/bin/kamal +27 -0
- data/bin/kamal.cmd +30 -0
- data/bin/rails +4 -0
- data/bin/rake +4 -0
- data/bin/rubocop +8 -0
- data/bin/setup +34 -0
- data/bin/thrust +5 -0
- data/config/application.rb +27 -0
- data/config/boot.rb +4 -0
- data/config/cable.yml +17 -0
- data/config/cache.yml +16 -0
- data/config/credentials.yml.enc +1 -0
- data/config/database.yml +102 -0
- data/config/deploy.yml +116 -0
- data/config/environment.rb +5 -0
- data/config/environments/development.rb +72 -0
- data/config/environments/production.rb +91 -0
- data/config/environments/test.rb +53 -0
- data/config/importmap.rb +8 -0
- data/config/initializers/assets.rb +7 -0
- data/config/initializers/content_security_policy.rb +25 -0
- data/config/initializers/filter_parameter_logging.rb +8 -0
- data/config/initializers/inflections.rb +16 -0
- data/config/locales/en.yml +31 -0
- data/config/puma.rb +41 -0
- data/config/queue.yml +18 -0
- data/config/recurring.yml +10 -0
- data/config/routes.rb +14 -0
- data/config/storage.yml +34 -0
- data/config.ru +6 -0
- data/db/cable_schema.rb +11 -0
- data/db/cache_schema.rb +14 -0
- data/db/queue_schema.rb +129 -0
- data/db/schema.rb +17 -0
- data/db/seeds.rb +9 -0
- data/lib/superfast/version.rb +5 -0
- data/lib/superfast.rb +8 -0
- data/lib/tasks/.keep +0 -0
- data/log/.keep +0 -0
- data/public/400.html +114 -0
- data/public/404.html +114 -0
- data/public/406-unsupported-browser.html +114 -0
- data/public/422.html +114 -0
- data/public/500.html +114 -0
- data/public/icon.png +0 -0
- data/public/icon.svg +3 -0
- data/public/robots.txt +1 -0
- data/script/.keep +0 -0
- data/storage/.keep +0 -0
- data/superfast.gemspec +48 -0
- data/tmp/.keep +0 -0
- data/tmp/pids/.keep +0 -0
- data/tmp/storage/.keep +0 -0
- data/vendor/.keep +0 -0
- data/vendor/javascript/.keep +0 -0
- metadata +298 -0
@@ -0,0 +1,7 @@
|
|
1
|
+
class ApplicationJob < ActiveJob::Base
|
2
|
+
# Automatically retry jobs that encountered a deadlock
|
3
|
+
# retry_on ActiveRecord::Deadlocked
|
4
|
+
|
5
|
+
# Most jobs are safe to ignore if the underlying records are no longer available
|
6
|
+
# discard_on ActiveJob::DeserializationError
|
7
|
+
end
|
File without changes
|
@@ -0,0 +1,28 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title><%= content_for(:title) || "Superfast" %></title>
|
5
|
+
<meta name="viewport" content="width=device-width,initial-scale=1">
|
6
|
+
<meta name="apple-mobile-web-app-capable" content="yes">
|
7
|
+
<meta name="mobile-web-app-capable" content="yes">
|
8
|
+
<%= csrf_meta_tags %>
|
9
|
+
<%= csp_meta_tag %>
|
10
|
+
|
11
|
+
<%= yield :head %>
|
12
|
+
|
13
|
+
<%# Enable PWA manifest for installable apps (make sure to enable in config/routes.rb too!) %>
|
14
|
+
<%#= tag.link rel: "manifest", href: pwa_manifest_path(format: :json) %>
|
15
|
+
|
16
|
+
<link rel="icon" href="/icon.png" type="image/png">
|
17
|
+
<link rel="icon" href="/icon.svg" type="image/svg+xml">
|
18
|
+
<link rel="apple-touch-icon" href="/icon.png">
|
19
|
+
|
20
|
+
<%# Includes all stylesheet files in app/assets/stylesheets %>
|
21
|
+
<%= stylesheet_link_tag :app, "data-turbo-track": "reload" %>
|
22
|
+
<%= javascript_importmap_tags %>
|
23
|
+
</head>
|
24
|
+
|
25
|
+
<body>
|
26
|
+
<%= yield %>
|
27
|
+
</body>
|
28
|
+
</html>
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= yield %>
|
@@ -0,0 +1,22 @@
|
|
1
|
+
{
|
2
|
+
"name": "Superfast",
|
3
|
+
"icons": [
|
4
|
+
{
|
5
|
+
"src": "/icon.png",
|
6
|
+
"type": "image/png",
|
7
|
+
"sizes": "512x512"
|
8
|
+
},
|
9
|
+
{
|
10
|
+
"src": "/icon.png",
|
11
|
+
"type": "image/png",
|
12
|
+
"sizes": "512x512",
|
13
|
+
"purpose": "maskable"
|
14
|
+
}
|
15
|
+
],
|
16
|
+
"start_url": "/",
|
17
|
+
"display": "standalone",
|
18
|
+
"scope": "/",
|
19
|
+
"description": "Superfast.",
|
20
|
+
"theme_color": "red",
|
21
|
+
"background_color": "red"
|
22
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
// Add a service worker for processing Web Push notifications:
|
2
|
+
//
|
3
|
+
// self.addEventListener("push", async (event) => {
|
4
|
+
// const { title, options } = await event.data.json()
|
5
|
+
// event.waitUntil(self.registration.showNotification(title, options))
|
6
|
+
// })
|
7
|
+
//
|
8
|
+
// self.addEventListener("notificationclick", function(event) {
|
9
|
+
// event.notification.close()
|
10
|
+
// event.waitUntil(
|
11
|
+
// clients.matchAll({ type: "window" }).then((clientList) => {
|
12
|
+
// for (let i = 0; i < clientList.length; i++) {
|
13
|
+
// let client = clientList[i]
|
14
|
+
// let clientPath = (new URL(client.url)).pathname
|
15
|
+
//
|
16
|
+
// if (clientPath == event.notification.data.path && "focus" in client) {
|
17
|
+
// return client.focus()
|
18
|
+
// }
|
19
|
+
// }
|
20
|
+
//
|
21
|
+
// if (clients.openWindow) {
|
22
|
+
// return clients.openWindow(event.notification.data.path)
|
23
|
+
// }
|
24
|
+
// })
|
25
|
+
// )
|
26
|
+
// })
|
data/assets/fibery.png
ADDED
Binary file
|
Binary file
|
data/assets/zulip.png
ADDED
Binary file
|
data/bin/brakeman
ADDED
data/bin/bundle
ADDED
@@ -0,0 +1,109 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
#
|
5
|
+
# This file was generated by Bundler.
|
6
|
+
#
|
7
|
+
# The application 'bundle' is installed as part of a gem, and
|
8
|
+
# this file is here to facilitate running it.
|
9
|
+
#
|
10
|
+
|
11
|
+
require "rubygems"
|
12
|
+
|
13
|
+
m = Module.new do
|
14
|
+
module_function
|
15
|
+
|
16
|
+
def invoked_as_script?
|
17
|
+
File.expand_path($0) == File.expand_path(__FILE__)
|
18
|
+
end
|
19
|
+
|
20
|
+
def env_var_version
|
21
|
+
ENV["BUNDLER_VERSION"]
|
22
|
+
end
|
23
|
+
|
24
|
+
def cli_arg_version
|
25
|
+
return unless invoked_as_script? # don't want to hijack other binstubs
|
26
|
+
return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update`
|
27
|
+
bundler_version = nil
|
28
|
+
update_index = nil
|
29
|
+
ARGV.each_with_index do |a, i|
|
30
|
+
if update_index && update_index.succ == i && a.match?(Gem::Version::ANCHORED_VERSION_PATTERN)
|
31
|
+
bundler_version = a
|
32
|
+
end
|
33
|
+
next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/
|
34
|
+
bundler_version = $1
|
35
|
+
update_index = i
|
36
|
+
end
|
37
|
+
bundler_version
|
38
|
+
end
|
39
|
+
|
40
|
+
def gemfile
|
41
|
+
gemfile = ENV["BUNDLE_GEMFILE"]
|
42
|
+
return gemfile if gemfile && !gemfile.empty?
|
43
|
+
|
44
|
+
File.expand_path("../Gemfile", __dir__)
|
45
|
+
end
|
46
|
+
|
47
|
+
def lockfile
|
48
|
+
lockfile =
|
49
|
+
case File.basename(gemfile)
|
50
|
+
when "gems.rb" then gemfile.sub(/\.rb$/, ".locked")
|
51
|
+
else "#{gemfile}.lock"
|
52
|
+
end
|
53
|
+
File.expand_path(lockfile)
|
54
|
+
end
|
55
|
+
|
56
|
+
def lockfile_version
|
57
|
+
return unless File.file?(lockfile)
|
58
|
+
lockfile_contents = File.read(lockfile)
|
59
|
+
return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/
|
60
|
+
Regexp.last_match(1)
|
61
|
+
end
|
62
|
+
|
63
|
+
def bundler_requirement
|
64
|
+
@bundler_requirement ||=
|
65
|
+
env_var_version ||
|
66
|
+
cli_arg_version ||
|
67
|
+
bundler_requirement_for(lockfile_version)
|
68
|
+
end
|
69
|
+
|
70
|
+
def bundler_requirement_for(version)
|
71
|
+
return "#{Gem::Requirement.default}.a" unless version
|
72
|
+
|
73
|
+
bundler_gem_version = Gem::Version.new(version)
|
74
|
+
|
75
|
+
bundler_gem_version.approximate_recommendation
|
76
|
+
end
|
77
|
+
|
78
|
+
def load_bundler!
|
79
|
+
ENV["BUNDLE_GEMFILE"] ||= gemfile
|
80
|
+
|
81
|
+
activate_bundler
|
82
|
+
end
|
83
|
+
|
84
|
+
def activate_bundler
|
85
|
+
gem_error = activation_error_handling do
|
86
|
+
gem "bundler", bundler_requirement
|
87
|
+
end
|
88
|
+
return if gem_error.nil?
|
89
|
+
require_error = activation_error_handling do
|
90
|
+
require "bundler/version"
|
91
|
+
end
|
92
|
+
return if require_error.nil? && Gem::Requirement.new(bundler_requirement).satisfied_by?(Gem::Version.new(Bundler::VERSION))
|
93
|
+
warn "Activating bundler (#{bundler_requirement}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_requirement}'`"
|
94
|
+
exit 42
|
95
|
+
end
|
96
|
+
|
97
|
+
def activation_error_handling
|
98
|
+
yield
|
99
|
+
nil
|
100
|
+
rescue StandardError, LoadError => e
|
101
|
+
e
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
m.load_bundler!
|
106
|
+
|
107
|
+
if m.invoked_as_script?
|
108
|
+
load Gem.bin_path("bundler", "bundle")
|
109
|
+
end
|
data/bin/bundle.cmd
ADDED
@@ -0,0 +1,112 @@
|
|
1
|
+
@ruby -x "%~f0" %*
|
2
|
+
@exit /b %ERRORLEVEL%
|
3
|
+
|
4
|
+
#!/usr/bin/env ruby
|
5
|
+
# frozen_string_literal: true
|
6
|
+
|
7
|
+
#
|
8
|
+
# This file was generated by Bundler.
|
9
|
+
#
|
10
|
+
# The application 'bundle' is installed as part of a gem, and
|
11
|
+
# this file is here to facilitate running it.
|
12
|
+
#
|
13
|
+
|
14
|
+
require "rubygems"
|
15
|
+
|
16
|
+
m = Module.new do
|
17
|
+
module_function
|
18
|
+
|
19
|
+
def invoked_as_script?
|
20
|
+
File.expand_path($0) == File.expand_path(__FILE__)
|
21
|
+
end
|
22
|
+
|
23
|
+
def env_var_version
|
24
|
+
ENV["BUNDLER_VERSION"]
|
25
|
+
end
|
26
|
+
|
27
|
+
def cli_arg_version
|
28
|
+
return unless invoked_as_script? # don't want to hijack other binstubs
|
29
|
+
return unless "update".start_with?(ARGV.first || " ") # must be running `bundle update`
|
30
|
+
bundler_version = nil
|
31
|
+
update_index = nil
|
32
|
+
ARGV.each_with_index do |a, i|
|
33
|
+
if update_index && update_index.succ == i && a.match?(Gem::Version::ANCHORED_VERSION_PATTERN)
|
34
|
+
bundler_version = a
|
35
|
+
end
|
36
|
+
next unless a =~ /\A--bundler(?:[= ](#{Gem::Version::VERSION_PATTERN}))?\z/
|
37
|
+
bundler_version = $1
|
38
|
+
update_index = i
|
39
|
+
end
|
40
|
+
bundler_version
|
41
|
+
end
|
42
|
+
|
43
|
+
def gemfile
|
44
|
+
gemfile = ENV["BUNDLE_GEMFILE"]
|
45
|
+
return gemfile if gemfile && !gemfile.empty?
|
46
|
+
|
47
|
+
File.expand_path("../Gemfile", __dir__)
|
48
|
+
end
|
49
|
+
|
50
|
+
def lockfile
|
51
|
+
lockfile =
|
52
|
+
case File.basename(gemfile)
|
53
|
+
when "gems.rb" then gemfile.sub(/\.rb$/, ".locked")
|
54
|
+
else "#{gemfile}.lock"
|
55
|
+
end
|
56
|
+
File.expand_path(lockfile)
|
57
|
+
end
|
58
|
+
|
59
|
+
def lockfile_version
|
60
|
+
return unless File.file?(lockfile)
|
61
|
+
lockfile_contents = File.read(lockfile)
|
62
|
+
return unless lockfile_contents =~ /\n\nBUNDLED WITH\n\s{2,}(#{Gem::Version::VERSION_PATTERN})\n/
|
63
|
+
Regexp.last_match(1)
|
64
|
+
end
|
65
|
+
|
66
|
+
def bundler_requirement
|
67
|
+
@bundler_requirement ||=
|
68
|
+
env_var_version ||
|
69
|
+
cli_arg_version ||
|
70
|
+
bundler_requirement_for(lockfile_version)
|
71
|
+
end
|
72
|
+
|
73
|
+
def bundler_requirement_for(version)
|
74
|
+
return "#{Gem::Requirement.default}.a" unless version
|
75
|
+
|
76
|
+
bundler_gem_version = Gem::Version.new(version)
|
77
|
+
|
78
|
+
bundler_gem_version.approximate_recommendation
|
79
|
+
end
|
80
|
+
|
81
|
+
def load_bundler!
|
82
|
+
ENV["BUNDLE_GEMFILE"] ||= gemfile
|
83
|
+
|
84
|
+
activate_bundler
|
85
|
+
end
|
86
|
+
|
87
|
+
def activate_bundler
|
88
|
+
gem_error = activation_error_handling do
|
89
|
+
gem "bundler", bundler_requirement
|
90
|
+
end
|
91
|
+
return if gem_error.nil?
|
92
|
+
require_error = activation_error_handling do
|
93
|
+
require "bundler/version"
|
94
|
+
end
|
95
|
+
return if require_error.nil? && Gem::Requirement.new(bundler_requirement).satisfied_by?(Gem::Version.new(Bundler::VERSION))
|
96
|
+
warn "Activating bundler (#{bundler_requirement}) failed:\n#{gem_error.message}\n\nTo install the version of bundler this project requires, run `gem install bundler -v '#{bundler_requirement}'`"
|
97
|
+
exit 42
|
98
|
+
end
|
99
|
+
|
100
|
+
def activation_error_handling
|
101
|
+
yield
|
102
|
+
nil
|
103
|
+
rescue StandardError, LoadError => e
|
104
|
+
e
|
105
|
+
end
|
106
|
+
end
|
107
|
+
|
108
|
+
m.load_bundler!
|
109
|
+
|
110
|
+
if m.invoked_as_script?
|
111
|
+
load Gem.bin_path("bundler", "bundle")
|
112
|
+
end
|
data/bin/dev
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/bin/bash -e
|
2
|
+
|
3
|
+
# Enable jemalloc for reduced memory usage and latency.
|
4
|
+
if [ -z "${LD_PRELOAD+x}" ]; then
|
5
|
+
LD_PRELOAD=$(find /usr/lib -name libjemalloc.so.2 -print -quit)
|
6
|
+
export LD_PRELOAD
|
7
|
+
fi
|
8
|
+
|
9
|
+
# If running the rails server then create or migrate existing database
|
10
|
+
if [ "${@: -2:1}" == "./bin/rails" ] && [ "${@: -1:1}" == "server" ]; then
|
11
|
+
./bin/rails db:prepare
|
12
|
+
fi
|
13
|
+
|
14
|
+
exec "${@}"
|
data/bin/importmap
ADDED
data/bin/jobs
ADDED
data/bin/kamal
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
#
|
5
|
+
# This file was generated by Bundler.
|
6
|
+
#
|
7
|
+
# The application 'kamal' is installed as part of a gem, and
|
8
|
+
# this file is here to facilitate running it.
|
9
|
+
#
|
10
|
+
|
11
|
+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
|
12
|
+
|
13
|
+
bundle_binstub = File.expand_path("bundle", __dir__)
|
14
|
+
|
15
|
+
if File.file?(bundle_binstub)
|
16
|
+
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
|
17
|
+
load(bundle_binstub)
|
18
|
+
else
|
19
|
+
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
20
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
require "rubygems"
|
25
|
+
require "bundler/setup"
|
26
|
+
|
27
|
+
load Gem.bin_path("kamal", "kamal")
|
data/bin/kamal.cmd
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
@ruby -x "%~f0" %*
|
2
|
+
@exit /b %ERRORLEVEL%
|
3
|
+
|
4
|
+
#!/usr/bin/env ruby
|
5
|
+
# frozen_string_literal: true
|
6
|
+
|
7
|
+
#
|
8
|
+
# This file was generated by Bundler.
|
9
|
+
#
|
10
|
+
# The application 'kamal' is installed as part of a gem, and
|
11
|
+
# this file is here to facilitate running it.
|
12
|
+
#
|
13
|
+
|
14
|
+
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__)
|
15
|
+
|
16
|
+
bundle_binstub = File.expand_path("bundle", __dir__)
|
17
|
+
|
18
|
+
if File.file?(bundle_binstub)
|
19
|
+
if File.read(bundle_binstub, 300).include?("This file was generated by Bundler")
|
20
|
+
load(bundle_binstub)
|
21
|
+
else
|
22
|
+
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
|
23
|
+
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
|
24
|
+
end
|
25
|
+
end
|
26
|
+
|
27
|
+
require "rubygems"
|
28
|
+
require "bundler/setup"
|
29
|
+
|
30
|
+
load Gem.bin_path("kamal", "kamal")
|
data/bin/rails
ADDED
data/bin/rake
ADDED
data/bin/rubocop
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require "rubygems"
|
3
|
+
require "bundler/setup"
|
4
|
+
|
5
|
+
# explicit rubocop config increases performance slightly while avoiding config confusion.
|
6
|
+
ARGV.unshift("--config", File.expand_path("../.rubocop.yml", __dir__))
|
7
|
+
|
8
|
+
load Gem.bin_path("rubocop", "rubocop")
|
data/bin/setup
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
#!/usr/bin/env ruby.exe
|
2
|
+
require "fileutils"
|
3
|
+
|
4
|
+
APP_ROOT = File.expand_path("..", __dir__)
|
5
|
+
|
6
|
+
def system!(*args)
|
7
|
+
system(*args, exception: true)
|
8
|
+
end
|
9
|
+
|
10
|
+
FileUtils.chdir APP_ROOT do
|
11
|
+
# This script is a way to set up or update your development environment automatically.
|
12
|
+
# This script is idempotent, so that you can run it at any time and get an expectable outcome.
|
13
|
+
# Add necessary setup steps to this file.
|
14
|
+
|
15
|
+
puts "== Installing dependencies =="
|
16
|
+
system("bundle check") || system!("bundle install")
|
17
|
+
|
18
|
+
# puts "\n== Copying sample files =="
|
19
|
+
# unless File.exist?("config/database.yml")
|
20
|
+
# FileUtils.cp "config/database.yml.sample", "config/database.yml"
|
21
|
+
# end
|
22
|
+
|
23
|
+
puts "\n== Preparing database =="
|
24
|
+
system! "bin/rails db:prepare"
|
25
|
+
|
26
|
+
puts "\n== Removing old logs and tempfiles =="
|
27
|
+
system! "bin/rails log:clear tmp:clear"
|
28
|
+
|
29
|
+
unless ARGV.include?("--skip-server")
|
30
|
+
puts "\n== Starting development server =="
|
31
|
+
STDOUT.flush # flush the output before exec(2) so that it displays
|
32
|
+
exec "bin/dev"
|
33
|
+
end
|
34
|
+
end
|
data/bin/thrust
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
require_relative "boot"
|
2
|
+
|
3
|
+
require "rails/all"
|
4
|
+
|
5
|
+
# Require the gems listed in Gemfile, including any gems
|
6
|
+
# you've limited to :test, :development, or :production.
|
7
|
+
Bundler.require(*Rails.groups)
|
8
|
+
|
9
|
+
module Superfast
|
10
|
+
class Application < Rails::Application
|
11
|
+
# Initialize configuration defaults for originally generated Rails version.
|
12
|
+
config.load_defaults 8.0
|
13
|
+
|
14
|
+
# Please, add to the `ignore` list any other `lib` subdirectories that do
|
15
|
+
# not contain `.rb` files, or that should not be reloaded or eager loaded.
|
16
|
+
# Common ones are `templates`, `generators`, or `middleware`, for example.
|
17
|
+
config.autoload_lib(ignore: %w[assets tasks])
|
18
|
+
|
19
|
+
# Configuration for the application, engines, and railties goes here.
|
20
|
+
#
|
21
|
+
# These settings can be overridden in specific environments using the files
|
22
|
+
# in config/environments, which are processed later.
|
23
|
+
#
|
24
|
+
# config.time_zone = "Central Time (US & Canada)"
|
25
|
+
# config.eager_load_paths << Rails.root.join("extras")
|
26
|
+
end
|
27
|
+
end
|
data/config/boot.rb
ADDED
data/config/cable.yml
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Async adapter only works within the same process, so for manually triggering cable updates from a console,
|
2
|
+
# and seeing results in the browser, you must do so from the web console (running inside the dev process),
|
3
|
+
# not a terminal started via bin/rails console! Add "console" to any action or any ERB template view
|
4
|
+
# to make the web console appear.
|
5
|
+
development:
|
6
|
+
adapter: async
|
7
|
+
|
8
|
+
test:
|
9
|
+
adapter: test
|
10
|
+
|
11
|
+
production:
|
12
|
+
adapter: solid_cable
|
13
|
+
connects_to:
|
14
|
+
database:
|
15
|
+
writing: cable
|
16
|
+
polling_interval: 0.1.seconds
|
17
|
+
message_retention: 1.day
|
data/config/cache.yml
ADDED
@@ -0,0 +1,16 @@
|
|
1
|
+
default: &default
|
2
|
+
store_options:
|
3
|
+
# Cap age of oldest cache entry to fulfill retention policies
|
4
|
+
# max_age: <%= 60.days.to_i %>
|
5
|
+
max_size: <%= 256.megabytes %>
|
6
|
+
namespace: <%= Rails.env %>
|
7
|
+
|
8
|
+
development:
|
9
|
+
<<: *default
|
10
|
+
|
11
|
+
test:
|
12
|
+
<<: *default
|
13
|
+
|
14
|
+
production:
|
15
|
+
database: cache
|
16
|
+
<<: *default
|
@@ -0,0 +1 @@
|
|
1
|
+
iDODuyX+mVcU2cGwMpx2qxiUt3MQtfUnakwvCExnqE5hOVSpQgQ206muCrnFute6tgThCEXIeikFWlkE0ghrbrapZYr94sexZqsIiiLHTZ3Kle34Uvyhfe7YQzanwtwmwJnhwuoctD0cPMrMGQCqnuLSd+OxxGY7vuEYDHXbF0uuGGysNy/PO5S0TYi9D1R3it7PWjh1ElAqXBPw+pCib+AcuDJZshGE2pYIFyELzfLwiJm+J+7aOLH6HMw+m3kJXtEyykpiaRXBbz9MxQlIPwyPbUoVusi8VL/HjYj79Mk34bt6yDGSewQwN4hVMhKs0OB0swGvow2/wnYPzGVUFSK3pcB1bHnfrXxkzjfM9CHval4oxUtPM5OuXkhIKB6Vwo/7bi6QbAXyQV7niyXEetJcqkknidsACrpGh/qbWzHt4k+9w3Fu0jgVxq/ZmG3BRdxHjrQpn65bG8MD6r3Ph7QdsrIG0nmhQynr+n/11h8D5kAnSjBKuiqh--tAtQUcWou9/Nf9BF--5YOh2WITcNJx9Mq8DPEMsQ==
|