forked from Sysdeploy/ipxe_scripts
Refactor tests to travis.yml and move build process from script to buildbot
This commit is contained in:
parent
ae55be8be9
commit
72327c4d67
4
.travis.yml
Normal file
4
.travis.yml
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
script:
|
||||||
|
- ./buildbot/test.sh
|
||||||
|
|
31
buildbot/ipxe_config_sed.sh
Executable file
31
buildbot/ipxe_config_sed.sh
Executable file
|
@ -0,0 +1,31 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
|
||||||
|
if [[ ! $1 ]]; then
|
||||||
|
>&2 echo "No IPXE repo directory was supplied as an argument."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
# Enable required IPXE features
|
||||||
|
|
||||||
|
sed -i 's/^\/\/\#define\ DOWNLOAD_PROTO_HTTPS/\#define\ DOWNLOAD_PROTO_HTTPS/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ NSLOOKUP_CMD/\#define\ NSLOOKUP_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ TIME_CMD/\#define\ TIME_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ DIGEST_CMD/\#define\ DIGEST_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ REBOOT_CMD/\#define\ REBOOT_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ POWEROFF_CMD/\#define\ POWEROFF_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ IMAGE_TRUST_CMD/\#define\ IMAGE_TRUST_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ NTP_CMD/\#define\ NTP_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\/\/\#define\ CERT_CMD/\#define\ CERT_CMD/g' "${1}/src/config/general.h"
|
||||||
|
|
||||||
|
sed -i 's/^\#undef\ DOWNLOAD_PROTO_HTTPS/\#define\ DOWNLOAD_PROTO_HTTPS/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ NSLOOKUP_CMD/\#define\ NSLOOKUP_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ TIME_CMD/\#define\ TIME_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ DIGEST_CMD/\#define\ DIGEST_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ REBOOT_CMD/\#define\ REBOOT_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ POWEROFF_CMD/\#define\ POWEROFF_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ IMAGE_TRUST_CMD/\#define\ IMAGE_TRUST_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ NTP_CMD/\#define\ NTP_CMD/g' "${1}/src/config/general.h"
|
||||||
|
sed -i 's/^\#undef\ CERT_CMD/\#define\ CERT_CMD/g' "${1}/src/config/general.h"
|
||||||
|
|
5
buildbot/test.sh
Executable file
5
buildbot/test.sh
Executable file
|
@ -0,0 +1,5 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# TODO
|
||||||
|
/bin/true
|
||||||
|
|
|
@ -1,41 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
|
|
||||||
# By this point, the dependencies are installed, so we just need to download
|
|
||||||
# IPXE and build our ISO
|
|
||||||
|
|
||||||
git clone git://git.ipxe.org/ipxe.git
|
|
||||||
cd ipxe
|
|
||||||
|
|
||||||
# Do we want to specify a specific commit to lock in??
|
|
||||||
git checkout HEAD
|
|
||||||
cd src
|
|
||||||
|
|
||||||
# Enable required IPXE features
|
|
||||||
sed -i 's/^\/\/\#define\ DOWNLOAD_PROTO_HTTPS/\#define\ DOWNLOAD_PROTO_HTTPS/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ NSLOOKUP_CMD/\#define\ NSLOOKUP_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ TIME_CMD/\#define\ TIME_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ DIGEST_CMD/\#define\ DIGEST_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ REBOOT_CMD/\#define\ REBOOT_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ POWEROFF_CMD/\#define\ POWEROFF_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ IMAGE_TRUST_CMD/\#define\ IMAGE_TRUST_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ NTP_CMD/\#define\ NTP_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\/\/\#define\ CERT_CMD/\#define\ CERT_CMD/g' config/general.h
|
|
||||||
|
|
||||||
sed -i 's/^\#undef\ DOWNLOAD_PROTO_HTTPS/\#define\ DOWNLOAD_PROTO_HTTPS/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ NSLOOKUP_CMD/\#define\ NSLOOKUP_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ TIME_CMD/\#define\ TIME_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ DIGEST_CMD/\#define\ DIGEST_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ REBOOT_CMD/\#define\ REBOOT_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ POWEROFF_CMD/\#define\ POWEROFF_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ IMAGE_TRUST_CMD/\#define\ IMAGE_TRUST_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ NTP_CMD/\#define\ NTP_CMD/g' config/general.h
|
|
||||||
sed -i 's/^\#undef\ CERT_CMD/\#define\ CERT_CMD/g' config/general.h
|
|
||||||
|
|
||||||
|
|
||||||
IPXE_EMBED_FILE_LOC="$(realpath $(dirname $(realpath $0))/../embed.ipxe)"
|
|
||||||
|
|
||||||
make bin/ipxe.iso EMBED="${IPXE_EMBED_FILE_LOC}" \
|
|
||||||
CERT="${IPXE_SIGNING_CERT},${IPXE_SIGNING_CA_CRT}" \
|
|
||||||
TRUST="${IPXE_SIGNING_CA_CRT}"
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user