Skip to content
Snippets Groups Projects
Commit bccd1824 authored by Walter Lozano's avatar Walter Lozano
Browse files

Remove unused scripts


Remove old scripts that are not longer used

Signed-off-by: default avatarWalter Lozano <walter.lozano@collabora.com>
parent 1a2268f0
No related branches found
No related tags found
1 merge request!188Improvements to folding pipeline
#!/bin/sh
set -e
set -x
PATH=.:$PATH
NOVERIFY=y
NOCLONE=
OBSHOST=niobium
TOOLPATH=.
IMGBUILDER=harzer
PKGBUILDER=gouda
GITHOST=git.apertis.org
IMGHOST=images.apertis.org
MOMHOST=mom.apertis.org
run=
# SSH can be overridden by NOACT, ssh always runs
ssh="ssh -o ControlMaster=auto -o ControlPersist=30m"
[ -z "$RELEASE" ] && ( echo "No release specified, use RELEASE env var to specify the old version number" >&2 ; exit 1 )
[ -z "$NEXT_RELEASE" ] && ( echo "No release specified, use NEXT_RELEASE env var to specify the new version number" >&2 ; exit 1 )
[ -n "$NOVERIFY" ] && NOVERIFY=--no-verify
[ -n "$NOACT" ] && run="echo +++"
SSH="$run $ssh"
OSC="$run osc"
for host in $OBSHOST $IMGHOST $MOMHOST
do
if [ "$($ssh $host id -ur)" != 0 ]
then
echo "Can't get root at $host, check your ssh config" >&2
exit 1
fi
done
# Detect source release components
components=$(osc ls / | grep ^apertis:$RELEASE | cut -f 3 -d :)
for c in $components
do
$SSH $OBSHOST mkdir -p /srv/obs/build/apertis:$NEXT_RELEASE:$c/rebuild
done
# Clone binary repositories
for c in $components
do
$SSH $OBSHOST test -d /srv/obs/build/apertis:$RELEASE:$c/rebuild && \
[ -z "$NOCLONE" ] && $SSH $OBSHOST obs_admin --clone-repository apertis:$RELEASE:$c rebuild apertis:$NEXT_RELEASE:$c rebuild
done
#!/bin/sh
set -e
set -x
PATH=.:$PATH
NOVERIFY=y
NOCLONE=
OBSHOST=niobium
TOOLPATH=.
IMGBUILDER=harzer
PKGBUILDER=gouda
GITHOST=git.apertis.org
IMGHOST=images.apertis.org
MOMHOST=mom.apertis.org
run=
# SSH can be overridden by NOACT, ssh always runs
ssh="ssh -o ControlMaster=auto -o ControlPersist=30m"
[ -z "$RELEASE" ] && ( echo "No release specified, use RELEASE env var to specify the old version number" >&2 ; exit 1 )
[ -z "$NEXT_RELEASE" ] && ( echo "No release specified, use NEXT_RELEASE env var to specify the new version number" >&2 ; exit 1 )
[ -n "$NOVERIFY" ] && NOVERIFY=--no-verify
[ -n "$NOACT" ] && run="echo +++"
SSH="$run $ssh"
OSC="$run osc"
for host in $OBSHOST $IMGHOST $MOMHOST
do
if [ "$($ssh $host id -ur)" != 0 ]
then
echo "Can't get root at $host, check your ssh config" >&2
exit 1
fi
done
# Detect source release components
components=$(osc ls / | grep ^apertis:$RELEASE | cut -f 3 -d :)
schedulers=$($ssh $OBSHOST systemctl --no-legend --full list-units scheduler@* | cut -f 1 -d \ )
if [ -z "$schedulers" ]
then
# hmm, probably something or someone have already stopped all schedulers
# to be able to restart them again, just let's list all schedulers
schedulers=$($ssh $OBSHOST systemctl --no-legend --full --all list-units scheduler@* | cut -f 1 -d \ )
else
$SSH $OBSHOST systemctl stop $schedulers
fi
for c in $components
do
$SSH $OBSHOST mkdir -p /srv/obs/build/apertis:$NEXT_RELEASE:$c/$NEXT_RELEASE
done
# Clone binary repositories
for c in $components
do
[ -z "$NOCLONE" ] && $SSH $OBSHOST obs_admin --clone-repository apertis:$RELEASE:$c $RELEASE apertis:$NEXT_RELEASE:$c $NEXT_RELEASE
done
# Republish binary repositories
for c in $components
do
$SSH $OBSHOST obs_admin --republish-repository apertis:$NEXT_RELEASE:$c $NEXT_RELEASE
done
# Start OBS schedulers
$SSH $OBSHOST systemctl start $schedulers
# Update base-files
update-base-files
# Setup MOM
$SSH $MOMHOST $TOOLPATH/add-mom-release $NEXT_RELEASE
#!/bin/sh
. ./gitlab.sh
branch=${RELEASE:=v2019dev0}
groups=packaging
#"$(cat package-groups)"
for g in $groups
do
repos="$(get-groups-repos $g)"
for d in $repos
do
if [ "$(get-repo-branch $g/$d apertis/$branch)" != null ]
then
echo "skipping $g/$d (apertis/$branch exists)"
continue
fi
c="$(get-repo-branch $g/$d apertis/master)"
if [ "$c" != null ]
then
# this repo uses apertis/$branch branches
# echo create-repo-branch $g/$d apertis/$branch $c
create-repo-branch $g/$d apertis/$branch $c | jq -r '[.name, .commit.short_id] | @tsv'
else
c="$(get-repo-branch $g/$d master)"
create-repo-branch $g/$d $branch $c | jq -r '[.name, .commit.short_id] | @tsv'
fi
done
done
#!/bin/sh
set -e
[ -z "$EMAIL" ] && EMAIL="Apertis packagers <packagers@lists.apertis.org>"
[ -z "$RELEASE" ] && ( echo "No release specified, use RELEASE env var to specify the old version number" >&2 ; exit 1 )
repository=$1
base_repository=$2
[ -z "$repository" ] && ( echo "No repository specified" >&2 ; exit 1 )
[ -z "$base_repository" ] && ( echo "No base repository specified" >&2 ; exit 1 )
run=
[ "$NOACT" = "0" ] || run="echo +++"
. ./common.sh
if [ -z "${NEXT_RELEASE}" ]
then
NEXT_RELEASE=$(next_release ${RELEASE})
echo "Assuming the next release is ${NEXT_RELEASE}. Use NEXT_RELEASE env var to specify it explicitly"
fi
template="<project name=\"$OSNAME:$NEXT_RELEASE:$repository\">
<title>$NEXT_RELEASE $repository repository</title>
<description/>
<person userid=\"Admin\" role=\"bugowner\"/>
<person userid=\"ritesh\" role=\"bugowner\"/>
<person userid=\"Admin\" role=\"maintainer\"/>
<person userid=\"apertis-gitlab\" role=\"maintainer\"/>
<person userid=\"apertis-jenkins\" role=\"maintainer\"/>
<group groupid=\"apertis-dev\" role=\"maintainer\"/>
<build>
<enable/>
</build>
<publish>
<enable/>
</publish>
<debuginfo>
<disable/>
</debuginfo>
<repository name=\"default\" rebuild=\"local\" block=\"never\">
<path project=\"$OSNAME:$NEXT_RELEASE:$base_repository\" repository=\"default\"/>
<arch>armv7hl</arch>
<arch>aarch64</arch>
<arch>x86_64</arch>
</repository>
</project>"
# This following command needs OBS Admin privileges
set -vx
echo "$template" | $run osc meta prj $OSNAME:$NEXT_RELEASE:$repository -F -
apertis
appfw
docs
hmi
infrastructure
packaging
sample-applications
tests
#!/bin/sh
set -e
[ -z "$EMAIL" ] && EMAIL="Apertis packagers <packagers@lists.apertis.org>"
[ -z "$RELEASE" ] && ( echo "No release specified, use RELEASE env var to specify the old version number" >&2 ; exit 1 )
run=
[ "$NOACT" = "0" ] || run="echo +++"
. ./common.sh
if [ -z "${NEXT_RELEASE}" ]
then
NEXT_RELEASE=$(next_release ${RELEASE})
echo "Assuming the next release is ${NEXT_RELEASE}. Use NEXT_RELEASE env var to specify it explicitly"
fi
[ -d apertis-docs ] && rm -rf apertis-docs
git clone https://oauth2:${BRANCHING_GITLAB_API_TOKEN}@${CI_SERVER_HOST}/docs/apertis-docs
cd apertis-docs
git rev-parse --verify -q origin/apertis/${NEXT_RELEASE} > /dev/null || git branch apertis/${NEXT_RELEASE} origin/apertis/${RELEASE}
git checkout apertis/${NEXT_RELEASE}
if ! grep -q "release = \"${NEXT_RELEASE}\"" Jenkinsfile
then
sed -i "s/release = .*/release = \"${NEXT_RELEASE}\"/" Jenkinsfile
git commit -s -m "Target ${NEXT_RELEASE}" Jenkinsfile
fi
$run git push origin apertis/${NEXT_RELEASE}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment