From e8f317a11439cd5e14fb7d5d3cca0b7a470be763 Mon Sep 17 00:00:00 2001 From: u1wqelpw Date: Fri, 10 Jul 2026 02:33:56 +0000 Subject: [PATCH] Add Dockerfile --- Dockerfile | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..257fb12 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,23 @@ +# Sử dụng base image Ubuntu làm nền tảng tương thích tốt với file thực thi linux-amd64 +FROM ubuntu:22.04 + +# Cài đặt curl và ca-certificates để tải file qua HTTPS bảo mật +RUN apt-get update && apt-get install -y \ + curl \ + ca-certificates \ + && rm -rf /var/lib/apt/lists/* + +# Thiết lập thư mục làm việc trong container +WORKDIR /app + +# Tải xuống phiên bản stream-server mới nhất từ GitHub Releases +RUN curl -L -o stream-server https://github.com/perpetus/stream-server/releases/latest/download/stream-server-linux-amd64 + +# Cấp quyền thực thi cho file binary vừa tải về +RUN chmod +x stream-server + +# Mở port 11470 theo yêu cầu của ứng dụng +EXPOSE 11470 + +# Lệnh khởi chạy ứng dụng khi container bắt đầu chạy +CMD ["./stream-server"] \ No newline at end of file