Skip to content

Instantly share code, notes, and snippets.

@focusaurus focusaurus/build.sh
Created Jan 26, 2017

Embed
What would you like to do?
Build script detects macOS and runs itself under docker
#!/usr/bin/env bash
cd "$(dirname "$0")/.."
if [[ "$(uname)" == "Darwin" ]]; then
docker build --tag foo-rpmbuild .
docker run --interactive --tty --rm \
--volume "${PWD}:/opt/docker-host" \
--volume "$(yarn cache dir | grep '^/'):/var/run/yarn-cache" \
foo-rpmbuild /opt/docker-host/bin/build.sh
exit
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.