Skip to content

Commit

Permalink
Merge pull request #40 from Hugo-C/feature/GH-39
Browse files Browse the repository at this point in the history
GH-39 # Switch to rocket 0.5rc and rust stable
  • Loading branch information
Hugo-C authored Oct 8, 2023
2 parents 0f340ef + f090f97 commit c01e559
Show file tree
Hide file tree
Showing 14 changed files with 918 additions and 1,074 deletions.
1,470 changes: 650 additions & 820 deletions Cargo.lock

Large diffs are not rendered by default.

14 changes: 5 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,25 +1,21 @@
[package]
name = "jarm_online"
version = "0.2.0"
version = "0.2.2"
edition = "2018"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[dependencies]
rocket = "0.4"
rocket = { version = "=0.5.0-rc.3", features = ["json"] }
rust_jarm = "0.3"
serde = { version = "1.0", features = ["derive"] }
lazy_static = "1.4"
regex = "1.7"
csv = "1.2"
csv = "1.3"
openssl = { version = "~0.10.55", features = ["vendored"] } # Required for sentry
sentry = "0.31"
rocket-sentry = "0.7" # 0.8 require rocket 0.5
rocket-sentry = { git = "https://github.com/Hugo-C/rocket-sentry", branch = "master" }

[dependencies.rocket_contrib]
version = "0.4"
default-features = false
features = ["json"]

[dev-dependencies]
rstest = "0.18"
rstest = "0.18"
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM rust:1.72 as build-stage
FROM rust:1.73 as build-stage

ARG BUILD_TARGET="x86_64-unknown-linux-musl"
ARG BUILD_OPTIONS="--release --target $BUILD_TARGET"
Expand Down
17 changes: 5 additions & 12 deletions Rocket.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,12 @@
[development]
address = "localhost"
[debug]
address = "127.0.0.1"
port = 8000
workers = 2
keep_alive = 5
read_timeout = 5
write_timeout = 5
log = "normal"
log_level = "normal"
limits = { forms = 32768 }

[production]
[release]
address = "127.0.0.1"
port = 8000
workers = 2
keep_alive = 5
read_timeout = 5
write_timeout = 5
log = "normal"
log_level = "normal"
limits = { forms = 32768 }
3 changes: 1 addition & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ services:
build: .
image: jarm_online_api
container_name: jarm_online_api_container
stop_signal: SIGKILL # SIGTERM is allowed in config starting with rocket.rs 0.5
environment:
- ROCKET_ENV=production
- ROCKET_PROFILE=release
- ROCKET_SENTRY_DSN=${ROCKET_SENTRY_DSN:-https://123@deactivated.io/123}
ports:
- "8000:8000"
3 changes: 1 addition & 2 deletions docker-compose.yml.prod
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ services:
jarm_online_api:
image: hugocker/jarm_online_api
container_name: jarm_online_api_container
stop_signal: SIGKILL # SIGTERM is allowed in config starting with rocket.rs 0.5
environment:
- ROCKET_ENV=production
- ROCKET_PROFILE=release
- ROCKET_SENTRY_DSN=${ROCKET_SENTRY_DSN}
restart: unless-stopped
Loading

0 comments on commit c01e559

Please sign in to comment.