mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-06 11:24:07 +08:00
🗽 Sync 2026-11-02 01:12:34
This commit is contained in:
1 parent
484df37424
commit
6001519237
3 files changed
+3
-45
No files matched your search
+1
-4
@@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=dockerd
|
||||
PKG_VERSION:=29.6.1
|
||||
PKG_RELEASE:=9
|
||||
PKG_RELEASE:=10
|
||||
PKG_LICENSE:=Apache-2.0
|
||||
PKG_LICENSE_FILES:=LICENSE
|
||||
PKG_CPE_ID:=cpe:/a:mobyproject:moby
|
||||
@@ -127,9 +127,6 @@ define Package/dockerd/install
|
||||
|
||||
$(INSTALL_DIR) $(1)/opt/docker/
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/uci-defaults
|
||||
$(INSTALL_DATA) ./files/dockerd.uci-defaults $(1)/etc/uci-defaults/dockerd
|
||||
|
||||
ifeq ($(CONFIG_DOCKER_CHECK_CONFIG),y)
|
||||
$(INSTALL_DIR) $(1)/usr/share/docker/
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/contrib/check-config.sh $(1)/usr/share/docker/
|
||||
|
||||
@@ -1,39 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
function NEWPART(){
|
||||
ROOT_DISK=$1
|
||||
# 检查是否有未分配空间
|
||||
DISK_SIZE=$(parted -s $ROOT_DISK unit MB print | grep '^Disk' | awk '{print $3}' | sed 's/MB//')
|
||||
LAST_PART_END=$(parted -s $ROOT_DISK unit MB print | tail -n 2 | head -n 1 | awk '{print $3}' | sed 's/MB//')
|
||||
[ $LAST_PART_END == "End" ] && return 0
|
||||
UNALLOCATED_SPACE="$(awk "BEGIN {print $DISK_SIZE - $LAST_PART_END}")"
|
||||
awk 'BEGIN {exit !('$UNALLOCATED_SPACE' >= '1024')}' && {
|
||||
# 创建新分区
|
||||
parted -s $ROOT_DISK mkpart primary ext4 ${LAST_PART_END}MB 100% && {
|
||||
|
||||
ROOT_DISK_NAME="$(echo $ROOT_DISK | cut -d / -f 3)"
|
||||
LAST_PART_NAME="$(lsblk -nlo NAME | grep $ROOT_DISK_NAME | tail -n 1)"
|
||||
# 格式化新分区
|
||||
mkfs.ext4 -F -L "docker" /dev/${LAST_PART_NAME}
|
||||
pgrep -x /usr/bin/dockerd > /dev/null && /etc/init.d/dockerd stop
|
||||
mkdir -p /opt/docker
|
||||
eval $(block info /dev/${LAST_PART_NAME} | grep -o -e 'UUID="\S*"')
|
||||
[ ! -f /etc/config/fstab ] && ( block detect > /etc/config/fstab )
|
||||
uci set fstab.mountdocker="mount"
|
||||
uci set fstab.mountdocker.uuid="${UUID}"
|
||||
uci set fstab.mountdocker.target="/opt/docker"
|
||||
uci commit fstab
|
||||
umount -f /dev/${LAST_PART_NAME}
|
||||
/sbin/block mount
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
cat /etc/mtab | grep -q "/opt/docker" || {
|
||||
uci -q get fstab.mountdocker || {
|
||||
disk="$(lsblk | awk '/disk/ {print $1; exit}')"
|
||||
NEWPART /dev/$disk
|
||||
}
|
||||
}
|
||||
|
||||
exit 0
|
||||
+2
-2
@@ -5,8 +5,8 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=gately
|
||||
PKG_VERSION:=0.6.2.2
|
||||
PKG_RELEASE:=21
|
||||
PKG_VERSION:=0.6.2.3
|
||||
PKG_RELEASE:=22
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://codeload.github.com/wangwanjie/gately/tar.gz/v$(PKG_VERSION)?
|
||||
|
||||
Reference in new issue
Block a user