add init
This commit is contained in:
27
base.Dockerfile
Normal file
27
base.Dockerfile
Normal file
@@ -0,0 +1,27 @@
|
||||
FROM ubuntu:22.04
|
||||
LABEL maintainer="lingyu zeng <pylyzeng@gmail.com>"
|
||||
ENV TZ=Asia/Shanghai \
|
||||
DEBIAN_FRONTEND=noninteractive \
|
||||
PATH="/home/developer/bin:/home/developer/micromamba/bin:${PATH}" \
|
||||
CONDA_PREFIX="/home/developer/micromamba/envs/pyrosetta"
|
||||
|
||||
# Configure timezone and install necessary packages
|
||||
RUN <<EOT
|
||||
#!/bin/bash
|
||||
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;
|
||||
apt-get update;
|
||||
ln -snf /usr/share/zoneinfo/\$TZ /etc/localtime; echo \$TZ > /etc/timezone;
|
||||
apt-get install -y tzdata git zip curl wget bzip2 sudo;
|
||||
adduser --disabled-password --gecos "" developer;
|
||||
echo "developer:password" | chpasswd;
|
||||
echo "developer ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/developer;
|
||||
apt-get clean;
|
||||
rm -rf /var/lib/apt/lists/*
|
||||
EOT
|
||||
|
||||
# Switch to user developer
|
||||
USER developer
|
||||
|
||||
# Set working directory
|
||||
WORKDIR /home/developer
|
||||
Reference in New Issue
Block a user