From 42d4cc371916db8611a6a6bc77f829454a1361df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Sun, 21 Mar 2021 21:55:47 +0100 Subject: [PATCH] heroku deployment fix & release --- heroku.yml | 4 +++- src/main.rs | 8 +------- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/heroku.yml b/heroku.yml index 05d29aa..96c1105 100644 --- a/heroku.yml +++ b/heroku.yml @@ -1,5 +1,7 @@ build: docker: - web: Dockerfile + web: + dockerfile: Dockerfile + target: production run: web: ./actix-messaging \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 8c80567..c7abf80 100644 --- a/src/main.rs +++ b/src/main.rs @@ -6,14 +6,9 @@ mod routes; use crate::{actors::chat_server::ChatServer, models::AppState}; use actix::Actor; -use actix_web::{App, HttpServer, get}; +use actix_web::{App, HttpServer}; use routes::connect; -#[get("/hi")] -async fn hi() -> &'static str { - "Hello, World!" -} - fn get_server_addr() -> String { let port = std::env::var("PORT").expect("PORT env variable not found"); format!("0.0.0.0:{}", port) @@ -27,7 +22,6 @@ async fn main() -> std::io::Result<()> { App::new() .data(AppState { chat: chat.clone() }) .service(connect) - .service(hi) }) .bind(&addr)? .run()