mirror of
https://github.com/DefectingCat/dotfiles
synced 2025-07-15 08:41:36 +00:00
update arch dev dockerfile install script
This commit is contained in:
@ -16,9 +16,10 @@ RUN rm -rf /home/${USER}/dotfiles \
|
||||
|
||||
RUN chown -R "${USER}":"${USER}" /home/"${USER}"
|
||||
USER ${USER}
|
||||
COPY --chown=${USER} . /home/${USER}/dotfiles
|
||||
RUN export USER="${USER}" \
|
||||
&& git clone https://github.com/DefectingCat/dotfiles \
|
||||
&& chmod +x /home/${USER}/dotfiles/scripts/* \
|
||||
&& /home/${USER}/dotfiles/scripts/install-yay.sh \
|
||||
&& /home/${USER}/dotfiles/scripts/install-archlinux.sh
|
||||
|
||||
WORKDIR /home/${USER}/dotfiles
|
||||
|
@ -2,3 +2,7 @@ FROM archlinux
|
||||
|
||||
ARG USER=xfy
|
||||
RUN echo "${USER}"
|
||||
|
||||
WORKDIR /home/${USER}
|
||||
COPY . .
|
||||
RUN ls
|
||||
|
@ -1,4 +1,27 @@
|
||||
FROM archlinux
|
||||
|
||||
ARG USER=xfy
|
||||
WORKDIR /app
|
||||
ARG RUNNER_VERSION=2.311.0
|
||||
|
||||
RUN useradd --groups wheel --no-create-home --shell /bin/zsh ${USER} \
|
||||
&& echo "${USER} ALL=(ALL) NOPASSWD:ALL" >/etc/sudoers.d/${USER} \
|
||||
&& chmod 0440 /etc/sudoers.d/${USER} \
|
||||
&& usermod -s "$(which zsh)" ${USER}
|
||||
WORKDIR /home/${USER}
|
||||
RUN rm -rf /home/${USER}/dotfiles \
|
||||
&& rm -rf /home/${USER}/yay
|
||||
|
||||
RUN chown -R "${USER}":"${USER}" /home/"${USER}"
|
||||
USER ${USER}
|
||||
COPY --chown=${USER} . /home/${USER}/dotfiles
|
||||
RUN export USER="${USER}" \
|
||||
&& chmod +x /home/${USER}/dotfiles/scripts/* \
|
||||
&& /home/${USER}/dotfiles/scripts/install-yay.sh
|
||||
|
||||
WORKDIR /home/${USER}/actions-runner
|
||||
RUN yay --noconfirm \
|
||||
yay -S curl \
|
||||
curl -o actions-runner-linux-x64-${RUNNER_VERSION}.tar.gz \
|
||||
-L https://github.com/actions/runner/releases/download/v${RUNNER_VERSION}/actions-runner-linux-x64-${RUNNER_VERSION}.tar.gz \
|
||||
tar xzf ./actions-runner-linux-x64-${RUNNER_VERSION}.tar.gz
|
||||
|
||||
|
@ -1,10 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
source ./install-yay.sh
|
||||
|
||||
# install yay
|
||||
install_yay
|
||||
|
||||
cd /home/"$USER"/ || exit
|
||||
|
||||
# ohmyzsh
|
||||
|
@ -1,11 +1,9 @@
|
||||
#!/bin/bash
|
||||
|
||||
install_yay() {
|
||||
cd /home/"$USER"/ || exit
|
||||
git clone https://aur.archlinux.org/yay.git
|
||||
cd /home/"$USER"/yay || exit
|
||||
makepkg -si --noconfirm
|
||||
cd /home/"$USER"/ || exit
|
||||
rm -rf yay
|
||||
echo "install yay success"
|
||||
}
|
||||
cd /home/"$USER"/ || exit
|
||||
git clone https://aur.archlinux.org/yay.git
|
||||
cd /home/"$USER"/yay || exit
|
||||
makepkg -si --noconfirm
|
||||
cd /home/"$USER"/ || exit
|
||||
rm -rf yay
|
||||
echo "install yay success"
|
||||
|
Reference in New Issue
Block a user