diff --git a/.gitea/workflows/build_docker.yaml b/.gitea/workflows/build_docker.yaml index c01f6f5..6eb01a2 100644 --- a/.gitea/workflows/build_docker.yaml +++ b/.gitea/workflows/build_docker.yaml @@ -32,16 +32,12 @@ jobs: run: apt update && apt install nodejs pkg-config -y - name: Install docker run: curl -fsSL get.docker.com -o get-docker.sh && sh get-docker.sh - # - name: Install Rust - # uses: actions-rs/toolchain@v1 - # with: - # toolchain: nightly - # override: true - # components: rustfmt, clippy - name: Checkout Code uses: actions/checkout@v2 - name: Run migrations run: cargo install sqlx-cli && sqlx migrate run + - name: Build server binary + run: cargo build --release - name: Set up Docker Buildx uses: docker/setup-buildx-action@v1 - name: Log in to Docker Registry diff --git a/Dockerfile b/Dockerfile index 28b1a76..4faa64a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,2 +1,6 @@ FROM alpine:latest -RUN apk add htop \ No newline at end of file +ADD target/release/iot-cloud /iot-cloud + +ENV RUST_LOG=debug + +CMD [ "/iot-cloud" ] \ No newline at end of file