初始化信息

This commit is contained in:
2025-10-13 18:08:02 +08:00
parent e302ebe176
commit 35a90f1635
616 changed files with 58357 additions and 25 deletions
Executable
+35
View File
@@ -0,0 +1,35 @@
FROM ubuntu:latest
# 使用阿里云源
RUN sed -i 's/ports.ubuntu.com/mirrors.aliyun.com/g' /etc/apt/sources.list && \
sed -i 's/archive.ubuntu.com/mirrors.aliyun.com/g' /etc/apt/sources.list && \
sed -i 's/security.ubuntu.com/mirrors.aliyun.com/g' /etc/apt/sources.list
# 安装必要的依赖
RUN apt-get update && apt-get install -y \
git \
wget \
unzip \
xz-utils \
zip \
libglu1-mesa \
curl \
sudo \
&& rm -rf /var/lib/apt/lists/*
# 创建非root用户
RUN useradd -ms /bin/bash flutter_user
RUN adduser flutter_user sudo
RUN echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
# 克隆Flutter并设置权限
RUN git clone https://github.com/flutter/flutter.git /flutter && \
chown -R flutter_user:flutter_user /flutter
# 设置环境变量
ENV PATH="/flutter/bin:${PATH}"
# 切换用户并配置Flutter
USER flutter_user
WORKDIR /home/flutter_user
RUN flutter config --enable-windows-desktop