Use python slim image
This commit is contained in:
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
@@ -2,7 +2,7 @@ name: ci
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "master" ]
|
||||
branches: [ "*" ]
|
||||
tags: [ "*" ]
|
||||
pull_request:
|
||||
|
||||
|
||||
@@ -1,11 +1,16 @@
|
||||
# Init image
|
||||
FROM python:3
|
||||
FROM python:slim
|
||||
WORKDIR /app
|
||||
|
||||
# Install requirements
|
||||
COPY requirements.txt .
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
RUN wget -O /usr/bin/regctl https://github.com/regclient/regclient/releases/latest/download/regctl-linux-amd64
|
||||
RUN python - <<EOF
|
||||
from urllib.request import urlopen;
|
||||
from pathlib import Path;
|
||||
Path("/usr/bin/regctl").write_bytes(urlopen("https://github.com/regclient/regclient/releases/latest/download/regctl-linux-amd64").read())
|
||||
EOF
|
||||
|
||||
RUN chmod 755 /usr/bin/regctl
|
||||
|
||||
# Import app
|
||||
|
||||
16
dockup
16
dockup
@@ -136,15 +136,13 @@ def get_remote_tags(images):
|
||||
|
||||
for tag in tags:
|
||||
# Skip mismatched suffixes
|
||||
if local_suffix and not tag.endswith(local_suffix):
|
||||
continue
|
||||
|
||||
# Skip non-production versions
|
||||
if any(
|
||||
bad_keyword in tag.lower()
|
||||
for bad_keyword in ["test", "rc", "alpha", "beta", "devel"]
|
||||
):
|
||||
continue
|
||||
if local_suffix:
|
||||
if not tag.endswith(local_suffix):
|
||||
continue
|
||||
else:
|
||||
# Skip tags with suffixes if local has none
|
||||
if "-" in tag:
|
||||
continue
|
||||
|
||||
# Validate version structure
|
||||
if is_valid_semver(
|
||||
|
||||
Reference in New Issue
Block a user