Browse Source

docker-ce: add postinst and prerm script for service start and stop

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
lilik-openwrt-22.03
Florian Eckert 4 years ago
parent
commit
cc8d8bcf28
1 changed files with 18 additions and 0 deletions
  1. +18
    -0
      utils/docker-ce/Makefile

+ 18
- 0
utils/docker-ce/Makefile View File

@ -133,4 +133,22 @@ define Package/docker-ce/install
$(1)/etc/sysctl.d/12-br-netfilter-ip.conf $(1)/etc/sysctl.d/12-br-netfilter-ip.conf
endef endef
define Package/docker-ce/postinst
#!/bin/sh
[ -n "$$IPKG_INSTROOT" ] || {
/etc/init.d/dockerd enable
/etc/init.d/dockerd uciadd
/etc/init.d/dockerd start
}
endef
define Package/docker-ce/prerm
#!/bin/sh
[ -n "$$IPKG_INSTROOT" ] || {
/etc/init.d/dockerd disable
/etc/init.d/dockerd stop
/etc/init.d/dockerd ucidel
}
endef
$(eval $(call BuildPackage,docker-ce)) $(eval $(call BuildPackage,docker-ce))

Loading…
Cancel
Save