diff options
author | Timo Teräs <timo.teras@iki.fi> | 2016-11-24 11:22:55 +0200 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-11-24 11:23:43 +0200 |
commit | 6096d973a2502aa1de610fd38794195742cce4d2 (patch) | |
tree | b4026494b17f54b7cbf3e3966ebbb5045ed2820a /scripts | |
parent | e5cf3f20839ed56066ef660d45aee464e4fc18c9 (diff) | |
download | aports-6096d973a2502aa1de610fd38794195742cce4d2.tar.bz2 aports-6096d973a2502aa1de610fd38794195742cce4d2.tar.xz |
scripts/mkimage.sh: add parameter to add extra repositories
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/mkimage.sh | 25 |
1 files changed, 15 insertions, 10 deletions
diff --git a/scripts/mkimage.sh b/scripts/mkimage.sh index 0b413207ca..07ff24b26f 100755 --- a/scripts/mkimage.sh +++ b/scripts/mkimage.sh @@ -57,19 +57,20 @@ usage() { $0 [--tag RELEASE] [--outdir OUTDIR] [--workdir WORKDIR] [--arch ARCH] [--profile PROFILE] [--hostkeys] [--simulate] - [--repository REPO] [--yaml FILE] + [--repository REPO] [--extra-repository REPO] [--yaml FILE] $0 --help options: ---arch Specify which architecture images to build - (default: $default_arch) ---hostkeys Copy system apk signing keys to created images ---outdir Specify directory for the created images ---profile Specify which profiles to build ---repository Add package repository to use for the image ---simulate Don't execute commands ---tag Build images for tag RELEASE ---workdir Specify temporary working directory (cache) +--arch Specify which architecture images to build + (default: $default_arch) +--hostkeys Copy system apk signing keys to created images +--outdir Specify directory for the created images +--profile Specify which profiles to build +--repository Package repository to use for the image create +--extra-repository Add repository to search packages from +--simulate Don't execute commands +--tag Build images for tag RELEASE +--workdir Specify temporary working directory (cache) --yaml known profiles: $(echo $all_profiles | sort -u) @@ -199,6 +200,7 @@ while [ $# -gt 0 ]; do shift case "$opt" in --repository) REPODIR="$1"; shift ;; + --extra-repository) EXTRAREPOS="$EXTRAREPOS $1"; shift ;; --workdir) WORKDIR="$1"; shift ;; --outdir) OUTDIR="$1"; shift ;; --tag) RELEASE="$1"; shift ;; @@ -256,6 +258,9 @@ for ARCH in $req_arch; do warning "no repository set" fi echo "$REPODIR" > "$APKROOT/etc/apk/repositories" + for repo in $EXTRAREPOS; do + echo "$repo" >> "$APKROOT/etc/apk/repositories" + done fi abuild-apk update --root "$APKROOT" |