Tarantool development patches archive
 help / color / mirror / Atom feed
From: "Oleg Piskunov" <o.piskunov@tarantool.org>
To: "Alexander V. Tikhonov" <avtikhon@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [PATCH v1] Make S3 paths the same to Tarantool documented
Date: Tue, 18 Feb 2020 15:24:25 +0300	[thread overview]
Message-ID: <1582028664.238863565@f114.i.mail.ru> (raw)
In-Reply-To: <36105cdadaa8c8a99da901a4bb0fd0d44a936ae6.1582011996.git.avtikhon@tarantool.org>

[-- Attachment #1: Type: text/plain, Size: 4986 bytes --]


Sasha, could you please remove comments about Vanilla packages structure.
For the rest - LGTM
 
Regards,
Oleg
  
>Вторник, 18 февраля 2020, 10:47 +03:00 от Alexander V. Tikhonov <avtikhon@tarantool.org>:
> 
>Changed the Vanilla paths of the packages in S3 to
>the Tarantool documented on its web site, to give
>the ability to Tarantool users to continue use it
>w/o changes.
>
>Also moved the RPM sources packages to the standalone
>path.
>
>Follows up #3380
>---
>
>Github:  https://github.com/tarantool/tarantool/tree/avtikhon/gh-3380-rpm-packages-paths-full-ci
>Issue:  https://github.com/tarantool/tarantool/issues/3380
>
> tools/update_repo.sh | 73 +++++++++++++++++++++++++++++++-------------
> 1 file changed, 51 insertions(+), 22 deletions(-)
>
>diff --git a/tools/update_repo.sh b/tools/update_repo.sh
>index 65a977187..ec6146514 100755
>--- a/tools/update_repo.sh
>+++ b/tools/update_repo.sh
>@@ -405,42 +405,68 @@ EOF
> }
> 
> # The 'pack_rpm' function especialy created for RPM packages. It works
>-# with RPM packing OS like Centos, Fedora. It is based on globaly known
>+# with RPM packing OS like CentOS, Fedora. It is based on globaly known
> # tool 'createrepo' from:
>-#  https://linux.die.net/man/8/createrepo
>+#  https://linux.die.net/man/8/createrepo
> # This tool works with single distribution of the given OS.
>-# Result of the routine is the rpm package for YUM repository with
>-# file structure equal to the Centos/Fedora:
>-#  http://mirror.centos.org/centos/7/os/x86_64/Packages/
>-#  http://mirrors.kernel.org/fedora/releases/30/Everything/x86_64/os/Packages/t/
>+#
>+# Vanilla RPM packages structure for YUM repositories looks like:
>+# CentOS:
>+# Binaries:  http://mirror.centos.org/centos/7/os/x86_64/Packages/
>+# Sources:  http://vault.centos.org/8.1.1911/BaseOS/Source/SPackages/
>+# Fedora:
>+# Binaries:  http://mirrors.kernel.org/fedora/releases/30/Everything/x86_64/os/Packages/t/
>+# Sources:  http://mirrors.kernel.org/fedora/releases/30/Everything/source/tree/Packages/t/
>+# Decided to have back port capability at Tarantool links:
>+# CentOS:
>+# Tarantool:  https://www.tarantool.io/en/download/os-installation/rhel-centos/
>+# Changed Vanila -> MCS S3:
>+# centos/7/os/x86_64/Packages -> centos/7/x86_64/Packages
>+# 8.1.1911/BaseOS/Source/SPackages -> centos/8.1.1911/SRPMS/Packages
>+# Fedora:
>+# Tarantool:  https://www.tarantool.io/en/download/os-installation/fedora/
>+# Changed Vanila -> MCS S3:
>+# fedora/releases/30/Everything/x86_64/os/Packages -> fedora/30/x86_64/Packages
>+# fedora/releases/30/Everything/source/tree/Packages -> fedora/30/SRPMS/Packages
> function pack_rpm {
>- if ! ls $repo/*.rpm >/dev/null ; then
>- echo "ERROR: Current '$repo' path doesn't have RPM packages in path"
>- usage
>- exit 1
>- fi
>+ pack_subdir=$1
>+ pack_patterns=$2
>+
>+ for pack_pattern in $pack_patterns ; do
>+ if ! ls $repo/$pack_pattern >/dev/null ; then
>+ if [ "$pack_pattern" == "*.noarch.rpm" ]; then
>+ pack_patterns=$(echo "$pack_patterns" | sed "s#$pack_pattern##g")
>+ continue
>+ fi
>+ echo "ERROR: Current '$repo' path doesn't have $pack_pattern packages in path"
>+ usage
>+ exit 1
>+ fi
>+ done
> 
>     # prepare the workspace
>     prepare_ws ${os}_${option_dist}
> 
>     # copy the needed package binaries to the workspace
>- cp $repo/*.rpm $ws/.
>+ for pack_pattern in $pack_patterns ; do
>+ cp $repo/$pack_pattern $ws/.
>+ done
> 
>     pushd $ws
> 
>     # set the paths
>- if [ "$os" == "el" ]; then
>- repopath=$option_dist/os/x86_64
>- rpmpath=Packages
>- elif [ "$os" == "fedora" ]; then
>- repopath=releases/$option_dist/Everything/x86_64/os
>- rpmpath=Packages/$proddir
>+ repopath=$option_dist/$pack_subdir
>+ rpmpath=Packages
>+ if [ "$os" == "fedora" ]; then
>+ rpmpath=$rpmpath/$proddir
>     fi
>     packpath=$repopath/$rpmpath
> 
>     # prepare local repository with packages
>     $mk_dir $packpath
>- mv *.rpm $packpath/.
>+ for pack_pattern in $pack_patterns ; do
>+ mv $pack_pattern $packpath/.
>+ done
>     cd $repopath
> 
>     # copy the current metadata files from S3
>@@ -547,8 +573,10 @@ EOF
>     gpg --detach-sign --armor repodata/repomd.xml
> 
>     # copy the packages to S3
>- for file in $rpmpath/*.rpm ; do
>- $aws_cp_public $file "$bucket_path/$repopath/$file"
>+ for pack_pattern in $pack_patterns ; do
>+ for file in $rpmpath/$pack_pattern ; do
>+ $aws_cp_public $file "$bucket_path/$repopath/$file"
>+ done
>     done
> 
>     # update the metadata at the S3
>@@ -563,7 +591,8 @@ EOF
> if [ "$os" == "ubuntu" -o "$os" == "debian" ]; then
>     pack_deb
> elif [ "$os" == "el" -o "$os" == "fedora" ]; then
>- pack_rpm
>+ pack_rpm x86_64 "*.x86_64.rpm *.noarch.rpm"
>+ pack_rpm SRPMS "*.src.rpm"
> else
>     echo "USAGE: given OS '$os' is not supported, use any single from the list: $alloss"
>     usage
>--
>2.17.1
>  
 
 
--
Oleg Piskunov
 

[-- Attachment #2: Type: text/html, Size: 7295 bytes --]

  reply	other threads:[~2020-02-18 12:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-18  7:47 Alexander V. Tikhonov
2020-02-18 12:24 ` Oleg Piskunov [this message]
2020-02-18 17:08 ` Alexander Turenko
2020-02-19 10:53   ` Alexander Tikhonov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1582028664.238863565@f114.i.mail.ru \
    --to=o.piskunov@tarantool.org \
    --cc=avtikhon@tarantool.org \
    --cc=tarantool-patches@dev.tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH v1] Make S3 paths the same to Tarantool documented' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox