Compare commits

..

6 Commits

Author SHA1 Message Date
itdoginfo
8cd990f8a3 Fix extension for list 2025-08-26 14:25:28 +03:00
itdoginfo
c509fd38c7 Fix version for docker 2025-08-26 14:16:08 +03:00
itdoginfo
38991a803a Fix 2025-08-25 19:44:16 +03:00
itdoginfo
29c34e31db Fix 2025-08-25 19:41:04 +03:00
itdoginfo
a77e8fae7d Disable tag check 2025-08-25 19:13:01 +03:00
itdoginfo
6d83737336 Auto version for make 2025-08-25 19:11:12 +03:00
5 changed files with 22 additions and 33 deletions

View File

@@ -10,28 +10,22 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4.2.1
with:
fetch-depth: 0
- name: Check version match
- name: Extract version
id: version
run: |
PODKOP_VERSION=$(grep '^PKG_VERSION:=' podkop/Makefile | cut -d '=' -f 2)
LUCI_APP_PODKOP_VERSION=$(grep '^PKG_VERSION:=' luci-app-podkop/Makefile | cut -d '=' -f 2)
TAG_VERSION=${GITHUB_REF#refs/tags/v}
echo "Podkop version: $PODKOP_VERSION"
echo "Luci-app-podkop version: $LUCI_APP_PODKOP_VERSION"
echo "Tag version: $TAG_VERSION"
if [ "$PODKOP_VERSION" != "$TAG_VERSION" ] || [ "$LUCI_APP_PODKOP_VERSION" != "$TAG_VERSION" ]; then
echo "Error: Version mismatch"
exit 1
fi
VERSION=$(git describe --tags --exact-match 2>/dev/null || echo "dev_$(date +%d%m%Y)")
echo "version=$VERSION" >> $GITHUB_OUTPUT
- name: Build and push
uses: docker/build-push-action@v6.9.0
with:
context: .
tags: podkop:ci
build-args: |
PKG_VERSION=${{ steps.version.outputs.version }}
- name: Create Docker container
run: docker create --name podkop podkop:ci

View File

@@ -1,5 +1,8 @@
FROM itdoginfo/openwrt-sdk:24.10.1
ARG PKG_VERSION
ENV PKG_VERSION=${PKG_VERSION}
COPY ./podkop /builder/package/feeds/utilites/podkop
COPY ./luci-app-podkop /builder/package/feeds/luci/luci-app-podkop

View File

@@ -1,7 +1,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-podkop
PKG_VERSION:=0.4.7
PKG_VERSION := $(if $(PKG_VERSION),$(PKG_VERSION),dev_$(shell date +%d%m%Y))
PKG_RELEASE:=1
LUCI_TITLE:=LuCI podkop app

View File

@@ -1,7 +1,9 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=podkop
PKG_VERSION:=0.4.7
PKG_VERSION := $(if $(PKG_VERSION),$(PKG_VERSION),dev_$(shell date +%d%m%Y))
PKG_RELEASE:=1
PKG_MAINTAINER:=ITDog <podkop@itdog.info>

View File

@@ -1763,16 +1763,12 @@ configure_remote_domain_list_handler() {
local file_extension
file_extension=$(get_url_file_extension "$url")
case "$file_extension" in
lst)
log "Detected file extension: .$file_extension → no processing needed, managed on list_update"
;;
json|srs)
log "Detected file extension: .$file_extension → proceeding with processing"
sing_box_add_remote_ruleset_and_rules "$url" "$section" "domains"
;;
*)
log "Detected file extension: .$file_extension → unsupported, skipping"
return 1
log "Detected file extension: .$file_extension → no processing needed, managed on list_update"
;;
esac
}
@@ -1796,17 +1792,13 @@ configure_remote_subnet_list_handler() {
local file_extension
file_extension=$(get_url_file_extension "$url")
case "$file_extension" in
lst)
log "Detected file extension: .$file_extension → no processing needed, managed on list_update"
;;
json|srs)
log "Detected file extension: .$file_extension → proceeding with processing"
sing_box_add_remote_ruleset_and_rules "$url" "$section" "subnets"
;;
*)
log "Detected file extension: .$file_extension → unsupported, skipping"
return 1
;;
log "Detected file extension: .$file_extension → no processing needed, managed on list_update"
;;
esac
}
@@ -1899,16 +1891,12 @@ import_domains_from_remote_domain_list_handler() {
local file_extension
file_extension=$(get_url_file_extension "$url")
case "$file_extension" in
lst)
log "Detected file extension: .$file_extension → proceeding with processing"
import_domains_from_remote_lst_file "$url" "$section"
;;
json|srs)
log "Detected file extension: .$file_extension → no update needed, sing-box manages updates"
;;
*)
log "Detected file extension: .$file_extension → unsupported, skipping"
return 1
log "Detected file extension: .$file_extension → proceeding with processing"
import_domains_from_remote_lst_file "$url" "$section"
;;
esac
}