-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #43 from DXCanas/master
Add independent buildkite pipeline
- Loading branch information
Showing
3 changed files
with
51 additions
and
11 deletions.
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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#! /bin/bash | ||
set -eo pipefail | ||
|
||
mkdir -p whl | ||
|
||
echo "--- Downloading whl file" | ||
|
||
# Allows for building directly from pipeline or trigger | ||
if [[ $LE_TRIGGERED_FROM_BUILD_ID ]] | ||
then | ||
echo "Downloading from triggered build" | ||
buildkite-agent artifact download 'dist/*.whl' . --build ${BUILDKITE_TRIGGERED_FROM_BUILD_ID} | ||
mv dist/* whl/ | ||
rm -r dist | ||
else | ||
echo "Downloading from pip" | ||
pip download -d ./whl kolibri | ||
fi | ||
|
||
echo "--- :android: Build APK" | ||
make run_docker | ||
|
||
# Making folder structure match other installers (convention) | ||
mv ./dist/android/*.apk ./dist | ||
|
||
if [[ $LE_TRIGGERED_FROM_JOB_ID && $BUILDKITE_TRIGGERED_FROM_BUILD_ID ]] | ||
then | ||
echo "--- Uploading artifact to parent job" | ||
buildkite-agent artifact upload dist/*-release.apk --job $LE_TRIGGERED_FROM_JOB_ID | ||
fi | ||
|
||
echo "--- Uploading artifact" | ||
buildkite-agent artifact upload dist/*-release.apk |
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
steps: | ||
# - block: "Build :android:?" | ||
# TODO make this independantly triggerable | ||
# Only block when build is triggered by another build | ||
# - if: build.source == "trigger_job" | ||
- label: "Build Android App" | ||
command: ".buildkite/build.sh" |
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