mirror of
https://github.com/BioArchLinux/docker.git
synced 2025-03-09 22:53:31 +00:00
init
This commit is contained in:
commit
4621bb88be
6 changed files with 84 additions and 0 deletions
19
Dockerfile
Normal file
19
Dockerfile
Normal file
|
@ -0,0 +1,19 @@
|
|||
FROM archlinux:latest
|
||||
|
||||
# import bioarchlinux keyring
|
||||
RUN pacman -Syu --noconfirm
|
||||
RUN pacman-key --recv-keys B1F96021DB62254D
|
||||
RUN pacman-key --finger B1F96021DB62254D
|
||||
RUN pacman-key --init
|
||||
RUN pacman-key --lsign-key B1F96021DB62254D
|
||||
|
||||
# add bioarchlinux to pacman.conf
|
||||
RUN curl https://raw.githubusercontent.com/BioArchLinux/mirror/main/pacman.conf.bio -o /etc/pacman.conf
|
||||
RUN curl https://raw.githubusercontent.com/BioArchLinux/mirror/main/mirrorlist.bio -o /etc/pacman.d/mirrorlist.bio
|
||||
RUN sed -i '2,2s/# //g' /etc/pacman.d/mirrorlist.bio
|
||||
|
||||
# install keyring and mirrorlist packages
|
||||
RUN pacman -Syu --noconfirm
|
||||
RUN pacman -S --noconfirm bioarchlinux-keyring
|
||||
RUN pacman -S --noconfirm --overwrite '*' bioarchlinux-mirrorlist
|
||||
RUN rm -rf /var/cache/pacman/pkg
|
33
README.md
Normal file
33
README.md
Normal file
|
@ -0,0 +1,33 @@
|
|||
# BioArchLinux on Docker
|
||||
|
||||
## Install docker and pull image
|
||||
|
||||
Install [docker](https://www.docker.com/) and start it
|
||||
|
||||
```
|
||||
docker pull bioarchlinux/bioarchlinux
|
||||
docker run -it --name container_name bioarchlinux/bioarchlinux
|
||||
```
|
||||
|
||||
## Choose mirror
|
||||
then you need to choose a mirror of archlinux and bioarchlinux
|
||||
|
||||
choose mirror of archlinux from [here](https://archlinux.org/mirrorlist/) and run the following command ( take sdu mirror as the example)
|
||||
|
||||
```
|
||||
echo 'Server = https://mirrors.sdu.edu.cn/archlinux/$repo/os/$arch' > /etc/pacman.d/mirrorlist
|
||||
```
|
||||
|
||||
choose mirror bioarchlinux from [here](https://raw.githubusercontent.com/BioArchLinux/mirror/main/mirrorlist.bio) and run the following command ( take sdu mirror as the example)
|
||||
|
||||
```
|
||||
echo 'Server = https://mirrors.sdu.edu.cn/bioarchlinux/$arch' > /etc/pacman.d/mirrorlist.bio
|
||||
```
|
||||
|
||||
## Use it
|
||||
|
||||
Finally, you can install any packages from BioArchLinux
|
||||
```
|
||||
pacman -Syu
|
||||
pacman -S foo
|
||||
```
|
8
dockerhub.service
Normal file
8
dockerhub.service
Normal file
|
@ -0,0 +1,8 @@
|
|||
[Unit]
|
||||
Description=docker updater
|
||||
Wants=dockerhub.timer
|
||||
|
||||
[Service]
|
||||
User=root
|
||||
Type=simple
|
||||
ExecStart=/usr/share/lilac/docker/man_docker.sh
|
9
dockerhub.timer
Normal file
9
dockerhub.timer
Normal file
|
@ -0,0 +1,9 @@
|
|||
[Unit]
|
||||
Description=Runs docker updater everyday
|
||||
|
||||
[Timer]
|
||||
OnCalendar=*-*-* 02:00:00
|
||||
Unit=dockerhub.service
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
8
gen_docker.sh
Executable file
8
gen_docker.sh
Executable file
|
@ -0,0 +1,8 @@
|
|||
#!/bin/bash
|
||||
|
||||
docker build -t bioarchlinux:$(date "+%Y%m%d") .
|
||||
docker tag bioarchlinux:$(date "+%Y%m%d") bioarchlinux/bioarchlinux:$(date "+%Y%m%d")
|
||||
docker tag bioarchlinux:$(date "+%Y%m%d") bioarchlinux/bioarchlinux:latest
|
||||
docker push bioarchlinux/bioarchlinux:$(date "+%Y%m%d") -a
|
||||
|
||||
docker rmi --force $(docker images -q)
|
7
man_docker.sh
Executable file
7
man_docker.sh
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
cd /usr/share/lilac/docker
|
||||
|
||||
git pull
|
||||
|
||||
./gen_docker.sh
|
Loading…
Add table
Reference in a new issue