build.sh 507 B

12345678910111213141516171819202122
  1. #!/bin/bash
  2. set -x -e
  3. # Clean up
  4. rm -rf gluon
  5. git clone https://github.com/freifunk-gluon/gluon.git gluon -b "${GLUON_TAG}"
  6. # Add site configuration
  7. mkdir -p gluon/site
  8. cp /usr/src/site.mk gluon/site/
  9. cp /usr/src/site.conf gluon/site/
  10. # Build
  11. cd gluon
  12. make update
  13. time make -j $(($(nproc)+1)) GLUON_TARGET=ar71xx-generic
  14. set +x
  15. echo -e "\nBUILD FINISHED\n"
  16. echo "You can copy the resulting images from the container using:"
  17. echo -e "\ndocker cp ${HOSTNAME}:/usr/src/build/gluon/images <destination>\n"