forgot the dockerfile lmao
Test build / build (push) Failing after 1m25s
Details
Test build / build (push) Failing after 1m25s
Details
This commit is contained in:
parent
b521c299fd
commit
ce07c0ef3d
|
@ -0,0 +1,19 @@
|
|||
# builder
|
||||
FROM rust:1.70 as builder
|
||||
|
||||
WORKDIR /usr/src/actions-test
|
||||
COPY . .
|
||||
RUN cargo install --path .
|
||||
|
||||
# runner
|
||||
FROM debian:bullseye-slim
|
||||
|
||||
RUN apt-get update && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY --from=builder /usr/local/cargo/bin/actions-test /usr/local/bin/actions-test
|
||||
|
||||
RUN useradd -m runner
|
||||
USER runner
|
||||
|
||||
EXPOSE 8000
|
||||
CMD [ "actions-test" ]
|
|
@ -1,5 +1,3 @@
|
|||
use std::net::SocketAddr;
|
||||
|
||||
use axum::{Router, routing::get};
|
||||
|
||||
async fn index() -> &'static str {
|
||||
|
@ -10,8 +8,7 @@ async fn index() -> &'static str {
|
|||
async fn main() {
|
||||
let app = Router::new().route("/", get(index));
|
||||
|
||||
let addr = SocketAddr::from(([0, 0, 0, 0], 8997));
|
||||
axum::Server::bind(&addr)
|
||||
axum::Server::bind(&"0.0.0.0:8000".parse().unwrap())
|
||||
.serve(app.into_make_service())
|
||||
.await
|
||||
.unwrap();
|
||||
|
|
Loading…
Reference in New Issue