forked from metacpan/metacpan-docker
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0bdaa95
commit c7673d5
Showing
1 changed file
with
31 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,40 @@ | ||
#!/bin/sh | ||
|
||
./bin/run bin/metacpan mapping --delete | ||
MODULE=`basename $0` | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: Indices re-creating ..." | ||
|
||
sdeletelog=`./bin/run bin/metacpan mapping --delete --yes 2>&1` | ||
ideleters=$? | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: Re-creation finished with [$ideleters]" | ||
echo "${NOW} I ${MODULE}: Re-creation Log:\n'$sdeletelog'" | ||
|
||
if [ $ideleters -ne 0 ]; then | ||
echo "${NOW} I ${MODULE}: Re-creation failed!" | ||
|
||
exit $ideleters | ||
fi | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: ElasticSearch 'elasticsearch:9200': Indices showing ..." | ||
|
||
curl -v 'elasticsearch:9200/_cat/indices' | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: Packages downloading ..." | ||
|
||
/bin/partial-cpan-mirror.sh | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: Indices rebuilding ..." | ||
|
||
./bin/run bin/metacpan release /CPAN/authors/id/ | ||
./bin/run bin/metacpan latest | ||
./bin/run bin/metacpan author | ||
./bin/run bin/metacpan permission | ||
|
||
NOW=$(date +"%F %T") | ||
echo "${NOW} I ${MODULE}: done." |