Migrate to MUSL
This commit is contained in:
Generated
+11
-1
@@ -1948,6 +1948,15 @@ version = "0.1.6"
|
|||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "d05e27ee213611ffe7d6348b942e8f942b37114c00cc03cec254295a4a17852e"
|
checksum = "d05e27ee213611ffe7d6348b942e8f942b37114c00cc03cec254295a4a17852e"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "openssl-src"
|
||||||
|
version = "300.5.5+3.5.5"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "3f1787d533e03597a7934fd0a765f0d28e94ecc5fb7789f8053b1e699a56f709"
|
||||||
|
dependencies = [
|
||||||
|
"cc",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "openssl-sys"
|
name = "openssl-sys"
|
||||||
version = "0.9.109"
|
version = "0.9.109"
|
||||||
@@ -1956,6 +1965,7 @@ checksum = "90096e2e47630d78b7d1c20952dc621f957103f8bc2c8359ec81290d75238571"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"cc",
|
"cc",
|
||||||
"libc",
|
"libc",
|
||||||
|
"openssl-src",
|
||||||
"pkg-config",
|
"pkg-config",
|
||||||
"vcpkg",
|
"vcpkg",
|
||||||
]
|
]
|
||||||
@@ -1996,7 +2006,7 @@ checksum = "df94ce210e5bc13cb6651479fa48d14f601d9858cfe0467f43ae157023b938d3"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "payphone"
|
name = "payphone"
|
||||||
version = "4.4.12"
|
version = "4.4.16"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"async-trait",
|
"async-trait",
|
||||||
|
|||||||
+2
-2
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "payphone"
|
name = "payphone"
|
||||||
version = "4.4.12"
|
version = "4.4.16"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
default-run = "payphone"
|
default-run = "payphone"
|
||||||
|
|
||||||
@@ -26,7 +26,7 @@ open = "5.3.2"
|
|||||||
rand = "0.9.2"
|
rand = "0.9.2"
|
||||||
rand_chacha = { version = "0.9.0", features = ["os_rng"] }
|
rand_chacha = { version = "0.9.0", features = ["os_rng"] }
|
||||||
regex = "1.11.1"
|
regex = "1.11.1"
|
||||||
reqwest = { version = "0.12.23", features = ["gzip", "brotli", "zstd"] }
|
reqwest = { version = "0.12.23", features = ["gzip", "brotli", "zstd", "native-tls-vendored"] }
|
||||||
rgb = "0.8.52"
|
rgb = "0.8.52"
|
||||||
scc = "2.3.4"
|
scc = "2.3.4"
|
||||||
scylla = { version = "1.3.1", features = ["time-03"] }
|
scylla = { version = "1.3.1", features = ["time-03"] }
|
||||||
|
|||||||
+15
-6
@@ -1,19 +1,28 @@
|
|||||||
FROM rust:latest AS builder
|
# --- Builder stage ---
|
||||||
|
FROM rust:1-bookworm AS builder
|
||||||
|
|
||||||
|
# Install musl target and musl-tools
|
||||||
|
RUN rustup target add x86_64-unknown-linux-musl \
|
||||||
|
&& apt-get update \
|
||||||
|
&& apt-get install -y musl-tools build-essential
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
COPY Cargo.toml Cargo.lock ./
|
COPY Cargo.toml Cargo.lock ./
|
||||||
|
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
RUN cargo build --release
|
# Build fully static binary
|
||||||
|
RUN cargo build --release --target x86_64-unknown-linux-musl
|
||||||
|
|
||||||
|
# --- Final stage ---
|
||||||
FROM debian:bookworm
|
FROM debian:bookworm
|
||||||
|
|
||||||
COPY --from=builder /app/target/release/payphone /usr/local/bin/payphone
|
# Copy static binary
|
||||||
|
COPY --from=builder /app/target/x86_64-unknown-linux-musl/release/payphone /usr/local/bin/payphone
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y ca-certificates
|
RUN apt-get update && apt-get install -y ca-certificates \
|
||||||
RUN update-ca-certificates
|
&& update-ca-certificates \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
ENTRYPOINT ["/usr/local/bin/payphone"]
|
ENTRYPOINT ["/usr/local/bin/payphone"]
|
||||||
CMD ["start"]
|
CMD ["start"]
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
- name: APT Update
|
||||||
|
hosts: all
|
||||||
|
become: true
|
||||||
|
tasks:
|
||||||
|
- name: Update APT package index
|
||||||
|
ansible.builtin.apt:
|
||||||
|
update_cache: yes
|
||||||
|
cache_valid_time: 3600
|
||||||
|
|
||||||
|
- name: Upgrade APT packages
|
||||||
|
ansible.builtin.apt:
|
||||||
|
upgrade: dist
|
||||||
|
autoremove: yes
|
||||||
|
autoclean: yes
|
||||||
@@ -1,31 +1,3 @@
|
|||||||
[
|
[
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
"We're running out of money to pay for next month's hosting (we have $10 out of $60). If you can and want to help Payphone stay alive, consider [donating](<https://ko-fi.com/payphonedev>). We'll have to shut down Payphone if we can't pay for the hosting. All help is greatly appreciated!"
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
|
||||||
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
|
||||||
"You can report messages using `Message > Apps > Report Message`.",
|
|
||||||
"Help us sharing Payphone to make it more active!",
|
|
||||||
"Emojis will only show if they're from a server Payphone's in.",
|
|
||||||
"You cannot send links.",
|
|
||||||
"[Vote for Payphone on top.gg](<https://top.gg/bot/1212940413795827763/vote>) to help us reach more users!",
|
|
||||||
"[Write a review](<https://top.gg/bot/1212940413795827763#reviews>) to tell everyone your opinion about Payphone!",
|
|
||||||
"Calls will be automatically hung up after 15 minutes if nobody talks.",
|
|
||||||
"You can change Payphone's prefix with `{prefix}prefix`.",
|
|
||||||
"You can use `{prefix}skip` to directly search for a new call.",
|
|
||||||
"Want to stay hidden? Use `{prefix}mask on`!",
|
|
||||||
"Did you know you can check your mask with `{prefix}mask`?",
|
|
||||||
"Do you like Payphone? Consider [making a donation](<https://ko-fi.com/payphonedev>) to help us grow Payphone (and keep it running)!",
|
|
||||||
"Using `{prefix}friendreq` is the best way to ask the other party to add you.",
|
|
||||||
"There's a secret easter egg command. Try to find it! (Hint: cat)",
|
|
||||||
"Make sure to read Payphone's [Code of Conduct](<https://payphone.nyeki.dev/code-of-conduct>). Let's keep Payphone safe and fun for everyone!",
|
|
||||||
"Did you join [Payphone's new official server](<https://discord.gg/9daSsrfTmE>) yet? We have a lot of fun stuff there!",
|
|
||||||
"How high are you on the leaderboard? Use `{prefix}leaderboard` to check it out!"
|
|
||||||
]
|
]
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
[
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Automod features are still under development! Join the [official Discord server](<https://discord.gg/9daSsrfTmE>) if you detect a bug and we'll help you out.",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"Payphone needs your help! We're running out of money to pay for next month's hosting. If you can and want to help, consider [donating](<https://ko-fi.com/payphonedev>) to help Payphone stay alive. All help is greatly appreciated!",
|
||||||
|
"You can report messages using `Message > Apps > Report Message`.",
|
||||||
|
"Help us sharing Payphone to make it more active!",
|
||||||
|
"Emojis will only show if they're from a server Payphone's in.",
|
||||||
|
"You cannot send links.",
|
||||||
|
"[Vote for Payphone on top.gg](<https://top.gg/bot/1212940413795827763/vote>) to help us reach more users!",
|
||||||
|
"[Write a review](<https://top.gg/bot/1212940413795827763#reviews>) to tell everyone your opinion about Payphone!",
|
||||||
|
"Calls will be automatically hung up after 15 minutes if nobody talks.",
|
||||||
|
"You can change Payphone's prefix with `{prefix}prefix`.",
|
||||||
|
"You can use `{prefix}skip` to directly search for a new call.",
|
||||||
|
"Want to stay hidden? Use `{prefix}mask on`!",
|
||||||
|
"Did you know you can check your mask with `{prefix}mask`?",
|
||||||
|
"Do you like Payphone? Consider [making a donation](<https://ko-fi.com/payphonedev>) to help us grow Payphone (and keep it running)!",
|
||||||
|
"Using `{prefix}friendreq` is the best way to ask the other party to add you.",
|
||||||
|
"There's a secret easter egg command. Try to find it! (Hint: cat)",
|
||||||
|
"Make sure to read Payphone's [Code of Conduct](<https://payphone.nyeki.dev/code-of-conduct>). Let's keep Payphone safe and fun for everyone!",
|
||||||
|
"Did you join [Payphone's new official server](<https://discord.gg/9daSsrfTmE>) yet? We have a lot of fun stuff there!",
|
||||||
|
"How high are you on the leaderboard? Use `{prefix}leaderboard` to check it out!"
|
||||||
|
]
|
||||||
Reference in New Issue
Block a user