roles/fedoraloveskde: Use hard git resets with an origin

For fedoraloveskde.org, we currently directly push the pre-built website
into the repo branches until we figure out a better approach. Thus the
hisotry does not matter at all here and we just need the latest commit
fetched and switched to. We can thus directly fetch changes and reset,
specify the commit we want to use.

Signed-off-by: Timothée Ravier <tim@siosm.fr>
This commit is contained in:
Timothée Ravier 2021-09-18 01:22:11 +02:00 committed by kevin
parent fd0e069ea6
commit 66ce205d8a
2 changed files with 4 additions and 6 deletions

View file

@ -8,6 +8,5 @@ fi
cd /srv/web/fedoraloveskde.org
/usr/bin/git clean -q -fdx || exit 1
/usr/bin/git reset -q --hard || exit 1
/usr/bin/git checkout -q production || exit 1
/usr/bin/git pull -q --ff-only || exit 1
/usr/bin/git fetch -q || exit 1
/usr/bin/git reset -q --hard origin/production || exit 1

View file

@ -8,6 +8,5 @@ fi
cd /srv/web/fedoraloveskde.org
/usr/bin/git clean -q -fdx || exit 1
/usr/bin/git reset -q --hard || exit 1
/usr/bin/git checkout -q staging || exit 1
/usr/bin/git pull -q --ff-only || exit 1
/usr/bin/git fetch -q || exit 1
/usr/bin/git reset -q --hard origin/staging || exit 1