Skip to content

Commit

Permalink
Upgrade Lucky to v1.3
Browse files Browse the repository at this point in the history
Also upgrade Crystal to v1.14.
  • Loading branch information
akadusei committed Oct 24, 2024
1 parent 517d0dc commit 693bc98
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 18 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/deploy.staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
fail-fast: false
matrix:
crystal:
- '1.12.1'
- '1.14.0'
runs-on: ubuntu-latest
continue-on-error: false
steps:
Expand Down Expand Up @@ -46,7 +46,7 @@ jobs:
# - v22.2.0
# - latest
crystal:
- '1.12.1'
- '1.14.0'
experimental:
- false
runs-on: ubuntu-latest
Expand Down Expand Up @@ -176,7 +176,7 @@ jobs:
with:
build-args: |
ALPINE_VERSION=3.20
CRYSTAL_VERSION=1.12.1
CRYSTAL_VERSION=1.14.0
NODE_VERSION=20.12
cache-from: type=gha
cache-to: type=gha,mode=max
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
fail-fast: false
matrix:
crystal:
- '1.12.1'
- '1.14.0'
runs-on: ubuntu-latest
continue-on-error: false
steps:
Expand Down Expand Up @@ -38,7 +38,7 @@ jobs:
# - v22.2.0
# - latest
crystal:
- '1.12.1'
- '1.14.0'
experimental:
- false
runs-on: ubuntu-latest
Expand Down Expand Up @@ -169,7 +169,7 @@ jobs:
build-args: |
ALPINE_VERSION=3.20
COMPILE_FLAGS=--release
CRYSTAL_VERSION=1.12.1
CRYSTAL_VERSION=1.14.0
NODE_VERSION=20.12
cache-from: type=gha
cache-to: type=gha,mode=max
Expand Down
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
crystal 1.12.1
crystal 1.14.0
nodejs 20.12.2
5 changes: 5 additions & 0 deletions config/server.cr
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,11 @@ Lucky::RequestIdHandler.configure do |settings|
}
end

Lucky::MaximumRequestSizeHandler.configure do |settings|
settings.enabled = true
settings.max_size = 10_000_000
end

private def secret_key_from_env
ENV["SECRET_KEY_BASE"]? || raise_missing_secret_key
end
Expand Down
16 changes: 8 additions & 8 deletions shard.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ shards:

avram:
git: https://github.com/luckyframework/avram.git
version: 1.2.0
version: 1.3.0

backtracer:
git: https://github.com/sija/backtracer.cr.git
Expand All @@ -18,7 +18,7 @@ shards:

carbon:
git: https://github.com/luckyframework/carbon.git
version: 0.5.1
version: 0.6.0

cron_parser:
git: https://github.com/kostya/cron_parser.git
Expand Down Expand Up @@ -54,7 +54,7 @@ shards:

exception_page:
git: https://github.com/crystal-loot/exception_page.git
version: 0.4.1
version: 0.5.0

fella:
git: https://github.com/grottopress/fella.git
Expand Down Expand Up @@ -82,11 +82,11 @@ shards:

lucille:
git: https://github.com/grottopress/lucille.git
version: 1.1.3
version: 1.2.0

lucky:
git: https://github.com/luckyframework/lucky.git
version: 1.2.0
version: 1.3.0

lucky_cache:
git: https://github.com/luckyframework/lucky_cache.git
Expand All @@ -102,7 +102,7 @@ shards:

lucky_router:
git: https://github.com/luckyframework/lucky_router.git
version: 0.5.2
version: 0.6.0

lucky_task:
git: https://github.com/luckyframework/lucky_task.git
Expand All @@ -118,7 +118,7 @@ shards:

pawn:
git: https://github.com/grottopress/pawn.git
version: 1.0.0
version: 1.0.3

pg:
git: https://github.com/will/crystal-pg.git
Expand Down Expand Up @@ -150,7 +150,7 @@ shards:

shield:
git: https://github.com/grottopress/shield.git
version: 1.2.1
version: 1.4.0

splay_tree_map:
git: https://github.com/wyhaines/splay_tree_map.cr.git
Expand Down
6 changes: 3 additions & 3 deletions shard.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ crystal: ~> 1.12
dependencies:
avram:
github: luckyframework/avram
version: ~> 1.0
version: ~> 1.3
carbon:
github: luckyframework/carbon
version: ~> 0.5.0
version: ~> 0.6.0
defense:
github: defense-cr/defense
version: ~> 0.5.0
Expand All @@ -40,7 +40,7 @@ dependencies:
version: ~> 0.2.1
lucky:
github: luckyframework/lucky
version: ~> 1.0
version: ~> 1.3
lucky_env:
github: luckyframework/lucky_env
version: ~> 0.2.0
Expand Down
1 change: 1 addition & 0 deletions spec/spec_helper.cr
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,4 @@ Avram::SchemaEnforcer.ensure_correct_column_mappings!
include Carbon::Expectations
include Lucky::RequestExpectations
include LuckyFlow::Expectations
include Avram::Expectations
1 change: 1 addition & 0 deletions src/app_server.cr
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ class AppServer < Lucky::BaseAppServer
Lucky::ErrorHandler.new(action: Errors::Show),
Defense::Handler.new,
CorsHandler.new,
Lucky::MaximumRequestSizeHandler.new,
Unslash::Handler.new(308, safe: false),
Lucky::RouteHandler.new,
Lucky::StaticCompressionHandler.new(
Expand Down

0 comments on commit 693bc98

Please sign in to comment.