parent
8128164c00
commit
ca7273fbe6
20
.forgejo/workflows/uwu.yaml
Normal file
20
.forgejo/workflows/uwu.yaml
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
on: [push]
|
||||||
|
jobs:
|
||||||
|
test:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: rust:1.67
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
apt update
|
||||||
|
apt install --yes curl wget
|
||||||
|
- name: Install Rust nightly toolchain
|
||||||
|
run: |
|
||||||
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain nightly --profile default -y
|
||||||
|
source $HOME/.cargo/env
|
||||||
|
- name: Run tests
|
||||||
|
run: cargo test --lib
|
||||||
|
|
19
Dockerfile
19
Dockerfile
|
@ -1,19 +0,0 @@
|
||||||
FROM debian:bullseye@sha256:2c7a92a41cb814c00e7d455b2bc0c90ccdb9a4ced2ffdc10e562c7a84a186032
|
|
||||||
RUN apt-get update && apt-get install -y openssh-server gcc make dpkg-dev curl
|
|
||||||
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain nightly --profile default -y
|
|
||||||
# RUN /root/.cargo/rustup default nightly
|
|
||||||
# RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-host x86_64-unknown-linux-gnu --default-toolchain nightly --profile default -y
|
|
||||||
RUN /root/.cargo/bin/rustup target add x86_64-unknown-linux-gnu
|
|
||||||
WORKDIR /root
|
|
||||||
# RUN /root/.cargo/bin/cargo init
|
|
||||||
COPY Cargo.toml /root/Cargo.toml
|
|
||||||
COPY ./src/ /root/src
|
|
||||||
# COPY ./conf/ /root/conf
|
|
||||||
# COPY ./.cargo /root/.cargo
|
|
||||||
# RUN RUSTFLAGS='-Zlocation-detail=none' /root/.cargo/bin/cargo +nightly build -Zbuild-std --target x86_64-unknown-none --release
|
|
||||||
# RUN /root/.cargo/bin/cargo +nightly build --target x86_64-unknonenown-none --release
|
|
||||||
RUN /root/.cargo/bin/cargo +nightly test --lib --release
|
|
||||||
WORKDIR /wd
|
|
||||||
RUN echo "[+] Building..."
|
|
||||||
ENTRYPOINT ["/bin/bash", "-c", "/root/.cargo/bin/cargo +nightly build --target x86_64-unknown-none --release"]
|
|
||||||
|
|
Loading…
Reference in a new issue