mirror of
https://github.com/jellyfin/jellyfin-packaging.git
synced 2024-11-23 05:59:41 +00:00
Add ability to disable Docker pushes
This commit is contained in:
parent
cc225d5d49
commit
4e81d71c54
24
build.py
24
build.py
@ -35,7 +35,7 @@ except Exception as e:
|
||||
exit(1)
|
||||
|
||||
|
||||
def build_package_deb(jellyfin_version, build_type, build_arch, build_version):
|
||||
def build_package_deb(jellyfin_version, build_type, build_arch, build_version, no_push=False):
|
||||
"""
|
||||
Build a .deb package (Debian or Ubuntu) within a Docker container that matches the requested distribution version
|
||||
"""
|
||||
@ -111,7 +111,7 @@ def build_package_deb(jellyfin_version, build_type, build_arch, build_version):
|
||||
)
|
||||
|
||||
|
||||
def build_package_rpm(jellyfin_version, build_type, build_arch, build_version):
|
||||
def build_package_rpm(jellyfin_version, build_type, build_arch, build_version, no_push=False):
|
||||
"""
|
||||
Build a .rpm package (Fedora or CentOS) within a Docker container that matches the requested distribution version
|
||||
"""
|
||||
@ -121,7 +121,7 @@ def build_package_rpm(jellyfin_version, build_type, build_arch, build_version):
|
||||
pass
|
||||
|
||||
|
||||
def build_linux(jellyfin_version, build_type, build_arch, _build_version):
|
||||
def build_linux(jellyfin_version, build_type, build_arch, _build_version, no_push=False):
|
||||
"""
|
||||
Build a portable Linux archive
|
||||
"""
|
||||
@ -163,7 +163,7 @@ def build_linux(jellyfin_version, build_type, build_arch, _build_version):
|
||||
)
|
||||
|
||||
|
||||
def build_windows(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
def build_windows(jellyfin_version, build_type, _build_arch, _build_version, no_push=False):
|
||||
"""
|
||||
Build a portable Windows archive
|
||||
"""
|
||||
@ -205,7 +205,7 @@ def build_windows(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
)
|
||||
|
||||
|
||||
def build_macos(jellyfin_version, build_type, build_arch, _build_version):
|
||||
def build_macos(jellyfin_version, build_type, build_arch, _build_version, no_push=False):
|
||||
"""
|
||||
Build a portable MacOS archive
|
||||
"""
|
||||
@ -247,7 +247,7 @@ def build_macos(jellyfin_version, build_type, build_arch, _build_version):
|
||||
)
|
||||
|
||||
|
||||
def build_portable(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
def build_portable(jellyfin_version, build_type, _build_arch, _build_version, no_push=False):
|
||||
"""
|
||||
Build a portable .NET archive
|
||||
"""
|
||||
@ -276,7 +276,7 @@ def build_portable(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
)
|
||||
|
||||
|
||||
def build_docker(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
def build_docker(jellyfin_version, build_type, _build_arch, _build_version, no_push=False):
|
||||
"""
|
||||
Build Docker images for all architectures and combining manifests
|
||||
"""
|
||||
@ -345,6 +345,9 @@ def build_docker(jellyfin_version, build_type, _build_arch, _build_version):
|
||||
|
||||
log("")
|
||||
|
||||
if no_push:
|
||||
return
|
||||
|
||||
def build_manifests(server, images):
|
||||
# Build the manifests
|
||||
log(f">> Building Docker manifests for {server}...")
|
||||
@ -510,7 +513,12 @@ if jellyfin_version == "master":
|
||||
jellyfin_version = datetime.now().strftime("%Y%m%d%H")
|
||||
log(f"NOTE: Autocorrecting 'master' version to {jellyfin_version}")
|
||||
|
||||
if "--no-push" in sys.argv:
|
||||
no_push = True
|
||||
else:
|
||||
no_push = False
|
||||
|
||||
# Launch the builder function
|
||||
function_definitions[configurations[build_type]["build_function"]](
|
||||
jellyfin_version, build_type, build_arch, build_version
|
||||
jellyfin_version, build_type, build_arch, build_version, no_push=no_push
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user