Open kzshantonu opened 1 year ago
Let me look into that... what method were you using to run?
In the meantime,the Cargo crate should work fine on Arm-based systems.
# Get latest version of rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install AdGuardian
cargo install adguardian
# Start the app
adguardian
what method were you using to run?
docker container
Maybe an issue with the libc, i tried the binary on an OpenWRT running adguardhome, but as adguardian is linked to the libc linker, it won't start on openwrt ( which uses musl libc). I'll see if i can build a musl version of Adguardian ( or maybe if you have time ?)
See:
root@HomeLan:~# /usr/bin/adguardian
-ash: /usr/bin/adguardian: not found
root@HomeLan:~# cd /lib
root@HomeLan:/lib# ln -s ld-musl-aarch64.so.1 ld-linux-aarch64.so.1
root@HomeLan:/lib# /usr/bin/adguardian
Error relocating /usr/bin/adguardian: __res_init: symbol not found
Error relocating /usr/bin/adguardian: gnu_get_libc_version: symbol not found
I've made you ARMv7 and ARM64 binaries, will be in the latest release: https://github.com/Lissy93/AdGuardian-Term/releases/tag/1.2.0
And I'll look into the Docker image this evening....
The Dockerfile is pretty minimal, it's more likely an issue with the way the container is built and tagged on the registry, which is done with this workflow.
If helpful, here is more info from trying to run via Docker on a Raspberry Pi:
[mrg@freya 07:33:49] ~ > docker run -it lissy93/adguardian
Unable to find image 'lissy93/adguardian:latest' locally
latest: Pulling from lissy93/adguardian
b4f5261e49b9: Pull complete
Digest: sha256:5ca0c82e0d46010579343efe7c115780ede8821a9a81e61cbb565322805171bc
Status: Downloaded newer image for lissy93/adguardian:latest
standard_init_linux.go:219: exec user process caused: exec format error
Hardware/Software:
[mrg@freya 07:41:41] ~ > docker -v
Docker version 20.10.5+dfsg1, build 55c4c88
PS. Neat looking project!
I could be wrong here, but I do not see QEMU in build-docker.yml
. IIRC, that's necessary to get multiarch working.
If anyone's more experienced with Docker and GH actions than me, I could do with some help with this one. I've played around with a few things, but haven't had much luck so far.
1.69.0-alpine
base image used for the build stage, although as far as I can see, that should be a multi-arch imageUsing the following Dockerfile on a Raspberry Pi
# Build application - Copy assets, install deps and compile binary
FROM rust:1.69.0-alpine AS builder
RUN apk add --no-cache pkgconfig openssl openssl-dev musl-dev
WORKDIR /usr/src/adguardian
COPY . .
RUN cargo build --release
# Run application - Using lightweight base, execute the binary
FROM scratch
COPY --from=builder /usr/src/adguardian/target/release/adguardian /
ENTRYPOINT ["/adguardian"]
Gives me this output:
Sending build context to Docker daemon 108kB
Step 1/8 : FROM rust:1.69.0-alpine AS builder
1.69.0-alpine: Pulling from library/rust
no matching manifest for linux/arm/v7 in the manifest list entries
That's because the arch does not exist. I think you're better off pulling latest
in the builder stage.
i have the same issue when trying to install with cargo, and when i tried to used git clone:
git clone git@github.com:Lissy93/AdGuardian-Term.git
Cloning into 'AdGuardian-Term'...
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists..
but git clone https://github.com/Lissy93/AdGuardian-Term
worked.
Also, not to be that kind of person but to use CTRL+C
or q
to quit faster would be nice as in https://github.com/Lissy93/AdGuardian-Term/issues/6
I did also noticed that Adguardian is taking alot of resources, processor at 20% compared to 3% when not using adguardian, and heat gone up a few Celsius when running adguardian.
Love the idea, just hope this will be improved in the future :)
amd64 works fine