push_type_api 0.11.1 → 0.11.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/test/dummy/app/assets/javascripts/application.js +3 -4
- data/test/dummy/app/assets/javascripts/cable.js +1 -1
- data/test/dummy/app/assets/stylesheets/application.css +2 -2
- data/test/dummy/bin/setup +4 -0
- data/test/dummy/bin/yarn +11 -0
- data/test/dummy/config/cable.yml +1 -0
- data/test/dummy/config/database.yml +1 -1
- data/test/dummy/config/environments/development.rb +1 -1
- data/test/dummy/config/environments/production.rb +6 -1
- data/test/dummy/config/environments/test.rb +1 -1
- data/test/dummy/config/initializers/application_controller_renderer.rb +6 -4
- data/test/dummy/config/initializers/assets.rb +6 -3
- data/test/dummy/config/initializers/push_type.rb +1 -1
- data/test/dummy/config/locales/en.yml +10 -0
- data/test/dummy/config/puma.rb +16 -7
- data/test/dummy/config/secrets.yml +14 -4
- data/test/dummy/db/migrate/{20170518181701_create_push_type_users.push_type.rb → 20170922151312_create_push_type_users.push_type.rb} +0 -0
- data/test/dummy/db/migrate/{20170518181702_create_push_type_nodes.push_type.rb → 20170922151313_create_push_type_nodes.push_type.rb} +0 -0
- data/test/dummy/db/migrate/{20170518181703_create_push_type_node_hierarchies.push_type.rb → 20170922151314_create_push_type_node_hierarchies.push_type.rb} +0 -0
- data/test/dummy/db/migrate/{20170518181704_create_push_type_assets.push_type.rb → 20170922151315_create_push_type_assets.push_type.rb} +0 -0
- data/test/dummy/db/migrate/{20170518181705_add_field_store_default_values.push_type.rb → 20170922151316_add_field_store_default_values.push_type.rb} +0 -0
- data/test/dummy/db/migrate/{20170518181706_drop_legacy_push_type_taxonomies.push_type.rb → 20170922151317_drop_legacy_push_type_taxonomies.push_type.rb} +0 -0
- data/test/dummy/db/schema.rb +31 -31
- data/test/dummy/log/test.log +4313 -4148
- data/test/dummy/package.json +5 -0
- data/test/dummy/public/404.html +6 -6
- data/test/dummy/public/422.html +6 -6
- data/test/dummy/public/500.html +6 -6
- data/test/dummy/public/robots.txt +0 -4
- metadata +24 -24
- data/test/dummy/config/initializers/new_framework_defaults.rb +0 -24
- data/test/dummy/config/initializers/session_store.rb +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c7e77e344001a5753815be0d1146d5fc5e55b492
|
4
|
+
data.tar.gz: c44507269b7e72fdfcc3db7151a946e0906617b1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af45497851434e2fde756c3473c3130866fb9be54bd91bf9c668328f70cbfe755ad0cd8989278fb20c38237d9b0916892d7546fc43de659896a6e362b05251e2
|
7
|
+
data.tar.gz: 92ed7f59d08a9a0070c3dfee1f6dbf55e1a953a3607c412e503d73246bc6649b05f859094cb041901be15a20229894e6cfe928ca670facea8aeadee977fc237f
|
@@ -1,8 +1,8 @@
|
|
1
1
|
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
2
2
|
// listed below.
|
3
3
|
//
|
4
|
-
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts,
|
5
|
-
//
|
4
|
+
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, or any plugin's
|
5
|
+
// vendor/assets/javascripts directory can be referenced here using a relative path.
|
6
6
|
//
|
7
7
|
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
8
8
|
// compiled file. JavaScript code in this file should be added after the last require_* statement.
|
@@ -10,7 +10,6 @@
|
|
10
10
|
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
|
11
11
|
// about supported directives.
|
12
12
|
//
|
13
|
-
//= require
|
14
|
-
//= require jquery_ujs
|
13
|
+
//= require rails-ujs
|
15
14
|
//= require turbolinks
|
16
15
|
//= require_tree .
|
@@ -1,5 +1,5 @@
|
|
1
1
|
// Action Cable provides the framework to deal with WebSockets in Rails.
|
2
|
-
// You can generate new channels where WebSocket features live using the rails generate channel command.
|
2
|
+
// You can generate new channels where WebSocket features live using the `rails generate channel` command.
|
3
3
|
//
|
4
4
|
//= require action_cable
|
5
5
|
//= require_self
|
@@ -2,8 +2,8 @@
|
|
2
2
|
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
3
|
* listed below.
|
4
4
|
*
|
5
|
-
* Any CSS and SCSS file within this directory, lib/assets/stylesheets,
|
6
|
-
*
|
5
|
+
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, or any plugin's
|
6
|
+
* vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
7
|
*
|
8
8
|
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
9
|
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
|
data/test/dummy/bin/setup
CHANGED
@@ -18,6 +18,10 @@ chdir APP_ROOT do
|
|
18
18
|
system! 'gem install bundler --conservative'
|
19
19
|
system('bundle check') || system!('bundle install')
|
20
20
|
|
21
|
+
# Install JavaScript dependencies if using Yarn
|
22
|
+
# system('bin/yarn')
|
23
|
+
|
24
|
+
|
21
25
|
# puts "\n== Copying sample files =="
|
22
26
|
# unless File.exist?('config/database.yml')
|
23
27
|
# cp 'config/database.yml.sample', 'config/database.yml'
|
data/test/dummy/bin/yarn
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
VENDOR_PATH = File.expand_path('..', __dir__)
|
3
|
+
Dir.chdir(VENDOR_PATH) do
|
4
|
+
begin
|
5
|
+
exec "yarnpkg #{ARGV.join(" ")}"
|
6
|
+
rescue Errno::ENOENT
|
7
|
+
$stderr.puts "Yarn executable was not detected in the system."
|
8
|
+
$stderr.puts "Download Yarn at https://yarnpkg.com/en/docs/install"
|
9
|
+
exit 1
|
10
|
+
end
|
11
|
+
end
|
data/test/dummy/config/cable.yml
CHANGED
@@ -17,7 +17,7 @@
|
|
17
17
|
default: &default
|
18
18
|
adapter: postgresql
|
19
19
|
encoding: unicode
|
20
|
-
# For details on connection pooling, see
|
20
|
+
# For details on connection pooling, see Rails configuration guide
|
21
21
|
# http://guides.rubyonrails.org/configuring.html#database-pooling
|
22
22
|
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
|
23
23
|
|
@@ -18,7 +18,7 @@ Rails.application.configure do
|
|
18
18
|
|
19
19
|
config.cache_store = :memory_store
|
20
20
|
config.public_file_server.headers = {
|
21
|
-
'Cache-Control' =>
|
21
|
+
'Cache-Control' => "public, max-age=#{2.days.seconds.to_i}"
|
22
22
|
}
|
23
23
|
else
|
24
24
|
config.action_controller.perform_caching = false
|
@@ -14,6 +14,11 @@ Rails.application.configure do
|
|
14
14
|
config.consider_all_requests_local = false
|
15
15
|
config.action_controller.perform_caching = true
|
16
16
|
|
17
|
+
# Attempt to read encrypted secrets from `config/secrets.yml.enc`.
|
18
|
+
# Requires an encryption key in `ENV["RAILS_MASTER_KEY"]` or
|
19
|
+
# `config/secrets.yml.key`.
|
20
|
+
config.read_encrypted_secrets = true
|
21
|
+
|
17
22
|
# Disable serving static files from the `/public` folder by default since
|
18
23
|
# Apache or NGINX already handles this.
|
19
24
|
config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
@@ -78,7 +83,7 @@ Rails.application.configure do
|
|
78
83
|
if ENV["RAILS_LOG_TO_STDOUT"].present?
|
79
84
|
logger = ActiveSupport::Logger.new(STDOUT)
|
80
85
|
logger.formatter = config.log_formatter
|
81
|
-
config.logger
|
86
|
+
config.logger = ActiveSupport::TaggedLogging.new(logger)
|
82
87
|
end
|
83
88
|
|
84
89
|
# Do not dump schema after migrations.
|
@@ -15,7 +15,7 @@ Rails.application.configure do
|
|
15
15
|
# Configure public file server for tests with Cache-Control for performance.
|
16
16
|
config.public_file_server.enabled = true
|
17
17
|
config.public_file_server.headers = {
|
18
|
-
'Cache-Control' =>
|
18
|
+
'Cache-Control' => "public, max-age=#{1.hour.seconds.to_i}"
|
19
19
|
}
|
20
20
|
|
21
21
|
# Show full error reports and disable caching.
|
@@ -1,6 +1,8 @@
|
|
1
1
|
# Be sure to restart your server when you modify this file.
|
2
2
|
|
3
|
-
#
|
4
|
-
#
|
5
|
-
#
|
6
|
-
#
|
3
|
+
# ActiveSupport::Reloader.to_prepare do
|
4
|
+
# ApplicationController.renderer.defaults.merge!(
|
5
|
+
# http_host: 'example.org',
|
6
|
+
# https: false
|
7
|
+
# )
|
8
|
+
# end
|
@@ -3,9 +3,12 @@
|
|
3
3
|
# Version of your assets, change this if you want to expire all your assets.
|
4
4
|
Rails.application.config.assets.version = '1.0'
|
5
5
|
|
6
|
-
# Add additional assets to the asset load path
|
6
|
+
# Add additional assets to the asset load path.
|
7
7
|
# Rails.application.config.assets.paths << Emoji.images_path
|
8
|
+
# Add Yarn node_modules folder to the asset load path.
|
9
|
+
Rails.application.config.assets.paths << Rails.root.join('node_modules')
|
8
10
|
|
9
11
|
# Precompile additional assets.
|
10
|
-
# application.js, application.css, and all non-JS/CSS in app/assets
|
11
|
-
#
|
12
|
+
# application.js, application.css, and all non-JS/CSS in the app/assets
|
13
|
+
# folder are already added.
|
14
|
+
# Rails.application.config.assets.precompile += %w( admin.js admin.css )
|
@@ -45,6 +45,6 @@ PushType.setup do |config|
|
|
45
45
|
# secret_access_key: ENV['SECRET_ACCESS_KEY_ID']
|
46
46
|
# }
|
47
47
|
|
48
|
-
# config.dragonfly_secret = '
|
48
|
+
# config.dragonfly_secret = 'f3bec840c74fc35ab9319439cec043e58e833d242bf9c9e0031dc95265141f7a'
|
49
49
|
|
50
50
|
end
|
@@ -16,6 +16,16 @@
|
|
16
16
|
#
|
17
17
|
# This would use the information in config/locales/es.yml.
|
18
18
|
#
|
19
|
+
# The following keys must be escaped otherwise they will not be retrieved by
|
20
|
+
# the default I18n backend:
|
21
|
+
#
|
22
|
+
# true, false, on, off, yes, no
|
23
|
+
#
|
24
|
+
# Instead, surround them with single quotes.
|
25
|
+
#
|
26
|
+
# en:
|
27
|
+
# 'true': 'foo'
|
28
|
+
#
|
19
29
|
# To learn more, please read the Rails Internationalization guide
|
20
30
|
# available at http://guides.rubyonrails.org/i18n.html.
|
21
31
|
|
data/test/dummy/config/puma.rb
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
# Puma can serve each request in a thread from an internal thread pool.
|
2
|
-
# The `threads` method setting takes two numbers a minimum and maximum.
|
2
|
+
# The `threads` method setting takes two numbers: a minimum and maximum.
|
3
3
|
# Any libraries that use thread pools should be configured to match
|
4
4
|
# the maximum value specified for Puma. Default is set to 5 threads for minimum
|
5
|
-
# and maximum
|
5
|
+
# and maximum; this matches the default thread size of Active Record.
|
6
6
|
#
|
7
|
-
threads_count = ENV.fetch("RAILS_MAX_THREADS") { 5 }
|
7
|
+
threads_count = ENV.fetch("RAILS_MAX_THREADS") { 5 }
|
8
8
|
threads threads_count, threads_count
|
9
9
|
|
10
|
-
# Specifies the `port` that Puma will listen on to receive requests
|
10
|
+
# Specifies the `port` that Puma will listen on to receive requests; default is 3000.
|
11
11
|
#
|
12
12
|
port ENV.fetch("PORT") { 3000 }
|
13
13
|
|
@@ -32,16 +32,25 @@ environment ENV.fetch("RAILS_ENV") { "development" }
|
|
32
32
|
#
|
33
33
|
# preload_app!
|
34
34
|
|
35
|
+
# If you are preloading your application and using Active Record, it's
|
36
|
+
# recommended that you close any connections to the database before workers
|
37
|
+
# are forked to prevent connection leakage.
|
38
|
+
#
|
39
|
+
# before_fork do
|
40
|
+
# ActiveRecord::Base.connection_pool.disconnect! if defined?(ActiveRecord)
|
41
|
+
# end
|
42
|
+
|
35
43
|
# The code in the `on_worker_boot` will be called if you are using
|
36
44
|
# clustered mode by specifying a number of `workers`. After each worker
|
37
|
-
# process is booted this block will be run
|
38
|
-
# option you will want to use this block to reconnect to any threads
|
39
|
-
# or connections that may have been created at application boot, Ruby
|
45
|
+
# process is booted, this block will be run. If you are using the `preload_app!`
|
46
|
+
# option, you will want to use this block to reconnect to any threads
|
47
|
+
# or connections that may have been created at application boot, as Ruby
|
40
48
|
# cannot share connections between processes.
|
41
49
|
#
|
42
50
|
# on_worker_boot do
|
43
51
|
# ActiveRecord::Base.establish_connection if defined?(ActiveRecord)
|
44
52
|
# end
|
53
|
+
#
|
45
54
|
|
46
55
|
# Allow puma to be restarted by `rails restart` command.
|
47
56
|
plugin :tmp_restart
|
@@ -10,13 +10,23 @@
|
|
10
10
|
# Make sure the secrets in this file are kept private
|
11
11
|
# if you're sharing your code publicly.
|
12
12
|
|
13
|
+
# Shared secrets are available across all environments.
|
14
|
+
|
15
|
+
# shared:
|
16
|
+
# api_key: a1B2c3D4e5F6
|
17
|
+
|
18
|
+
# Environmental secrets are only available for that specific environment.
|
19
|
+
|
13
20
|
development:
|
14
|
-
secret_key_base:
|
21
|
+
secret_key_base: 1377fa82338520490b4c816e46b5fc373c618e640f54f511c9de5003d37c62cc2e5fda6bed06cf5fe5bc79c30a8558485bed5c10ded8b9875cbbbcdcb4bbd500
|
15
22
|
|
16
23
|
test:
|
17
|
-
secret_key_base:
|
24
|
+
secret_key_base: 0dc6f5b1dfda6b2ceee39e5c1b5cf2fe7fae6477286dffc83f2a3c9ebe3c244266511190bb357d0989cb4d524d83de408ff855f3228e604f15d1cb9ccf9e634d
|
25
|
+
|
26
|
+
# Do not keep production secrets in the unencrypted secrets file.
|
27
|
+
# Instead, either read values from the environment.
|
28
|
+
# Or, use `bin/rails secrets:setup` to configure encrypted secrets
|
29
|
+
# and move the `production:` environment over there.
|
18
30
|
|
19
|
-
# Do not keep production secrets in the repository,
|
20
|
-
# instead read values from the environment.
|
21
31
|
production:
|
22
32
|
secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/test/dummy/db/schema.rb
CHANGED
@@ -10,56 +10,56 @@
|
|
10
10
|
#
|
11
11
|
# It's strongly recommended that you check this file into your version control system.
|
12
12
|
|
13
|
-
ActiveRecord::Schema.define(version:
|
13
|
+
ActiveRecord::Schema.define(version: 20170922151317) do
|
14
14
|
|
15
15
|
# These are extensions that must be enabled in order to support this database
|
16
16
|
enable_extension "plpgsql"
|
17
17
|
enable_extension "uuid-ossp"
|
18
18
|
|
19
19
|
create_table "push_type_assets", id: :uuid, default: -> { "uuid_generate_v4()" }, force: :cascade do |t|
|
20
|
-
t.string
|
21
|
-
t.string
|
22
|
-
t.integer
|
23
|
-
t.string
|
24
|
-
t.string
|
25
|
-
t.string
|
26
|
-
t.uuid
|
27
|
-
t.datetime "created_at",
|
28
|
-
t.datetime "updated_at",
|
20
|
+
t.string "file_uid"
|
21
|
+
t.string "file_name"
|
22
|
+
t.integer "file_size"
|
23
|
+
t.string "file_ext"
|
24
|
+
t.string "mime_type"
|
25
|
+
t.string "description"
|
26
|
+
t.uuid "uploader_id"
|
27
|
+
t.datetime "created_at", null: false
|
28
|
+
t.datetime "updated_at", null: false
|
29
29
|
t.datetime "deleted_at"
|
30
30
|
end
|
31
31
|
|
32
32
|
create_table "push_type_node_hierarchies", id: false, force: :cascade do |t|
|
33
|
-
t.uuid
|
34
|
-
t.uuid
|
35
|
-
t.integer "generations",
|
36
|
-
t.index ["ancestor_id", "descendant_id", "generations"], name: "node_anc_desc_idx", unique: true
|
37
|
-
t.index ["descendant_id"], name: "node_desc_idx"
|
33
|
+
t.uuid "ancestor_id", null: false
|
34
|
+
t.uuid "descendant_id", null: false
|
35
|
+
t.integer "generations", null: false
|
36
|
+
t.index ["ancestor_id", "descendant_id", "generations"], name: "node_anc_desc_idx", unique: true
|
37
|
+
t.index ["descendant_id"], name: "node_desc_idx"
|
38
38
|
end
|
39
39
|
|
40
40
|
create_table "push_type_nodes", id: :uuid, default: -> { "uuid_generate_v4()" }, force: :cascade do |t|
|
41
|
-
t.string
|
42
|
-
t.string
|
43
|
-
t.string
|
44
|
-
t.jsonb
|
45
|
-
t.uuid
|
46
|
-
t.integer
|
47
|
-
t.integer
|
41
|
+
t.string "type"
|
42
|
+
t.string "title"
|
43
|
+
t.string "slug"
|
44
|
+
t.jsonb "field_store", default: {}, null: false
|
45
|
+
t.uuid "parent_id"
|
46
|
+
t.integer "sort_order"
|
47
|
+
t.integer "status"
|
48
48
|
t.datetime "published_at"
|
49
49
|
t.datetime "published_to"
|
50
|
-
t.uuid
|
51
|
-
t.uuid
|
52
|
-
t.datetime "created_at",
|
53
|
-
t.datetime "updated_at",
|
50
|
+
t.uuid "creator_id"
|
51
|
+
t.uuid "updater_id"
|
52
|
+
t.datetime "created_at", null: false
|
53
|
+
t.datetime "updated_at", null: false
|
54
54
|
t.datetime "deleted_at"
|
55
55
|
end
|
56
56
|
|
57
57
|
create_table "push_type_users", id: :uuid, default: -> { "uuid_generate_v4()" }, force: :cascade do |t|
|
58
|
-
t.string
|
59
|
-
t.string
|
60
|
-
t.jsonb
|
61
|
-
t.datetime "created_at",
|
62
|
-
t.datetime "updated_at",
|
58
|
+
t.string "name"
|
59
|
+
t.string "email"
|
60
|
+
t.jsonb "field_store", default: {}, null: false
|
61
|
+
t.datetime "created_at", null: false
|
62
|
+
t.datetime "updated_at", null: false
|
63
63
|
end
|
64
64
|
|
65
65
|
end
|