mirror of
https://github.com/clearlinux/micro-config-drive.git
synced 2026-09-04 20:51:40 +00:00
This option allows users to suspend execution of the cloud-init provisioning until a valid network is detected. This detection is currently done through requesting a DNS lookup for one of the Clear Linux NTP service IP addresses (this is a RR record, we don't actually look at the result). This lookup is not infinite. After 5 minutes, the wait exits no matter what even if there is no network detected. The option can be provided manually. `packages` and `package_upgrade` options *imply* this option, but one can explicitly disable the wait by providing it early in the cloud-config file with a value of `false`. The wait routing is active - it will retry relatively quickly to detect an active connection. Any failure will result in another retry. In a fully private network without public DNS, this will not work. The DNS hostname used for testing can be manipulated through the `-with-dnstestaddr=<hostname>` configure flag. You shouldn't put an IP address in here, since that fully disables any network testing.
60 lines
1.4 KiB
Makefile
60 lines
1.4 KiB
Makefile
if BUILD_TESTS
|
|
|
|
SUBDIRS = .
|
|
|
|
ACLOCAL_AMFLAGS = -I m4
|
|
|
|
TESTS =
|
|
|
|
check_PROGRAMS =
|
|
|
|
check_LTLIBRARIES = libtest.la
|
|
COMMON_CFLAGS = -std=gnu99 -I$(top_srcdir)/src -I$(top_srcdir)/src/ccmodules \
|
|
-I$(top_srcdir)/src/interpreters \
|
|
$(CHECK_FLAGS) $(GLIB_CFLAGS) $(CURL_CFLAGS) $(YAML_CFLAGS) $(BLKID_CFLAGS) $(PARTED_CFLAGS)
|
|
COMMON_LDADD = $(CHECK_LIBS) $(GLIB_LIBS) $(CURL_LIBS) $(YAML_LIBS) $(BLKID_LIBS) $(PARTED_LIBS)
|
|
|
|
libtest_la_SOURCES = \
|
|
../src/lib.c \
|
|
../src/async_task.c \
|
|
../src/disk.c \
|
|
../src/userdata.c \
|
|
../src/interpreters/cloud_config.c \
|
|
../src/interpreters/shell_script.c \
|
|
../src/ccmodules/envar.c \
|
|
../src/ccmodules/groups.c \
|
|
../src/ccmodules/hostname.c \
|
|
../src/ccmodules/package_upgrade.c \
|
|
../src/ccmodules/packages.c \
|
|
../src/ccmodules/runcmd.c \
|
|
../src/ccmodules/service.c \
|
|
../src/ccmodules/ssh_authorized_keys.c \
|
|
../src/ccmodules/users.c \
|
|
../src/ccmodules/write_files.c \
|
|
../src/ccmodules/fbootcmd.c \
|
|
../src/ccmodules/wait-for-network.c
|
|
|
|
if DEBUG
|
|
libtest_la_SOURCES += ../src/debug.c
|
|
endif
|
|
|
|
|
|
libtest_la_CFLAGS = $(COMMON_CFLAGS)
|
|
|
|
lib_test_SOURCES = lib_test.c
|
|
lib_test_CFLAGS = $(COMMON_CFLAGS) $(AM_CFLAGS)
|
|
lib_test_LDADD = libtest.la $(COMMON_LDADD)
|
|
TESTS += lib_test
|
|
|
|
userdata_test_SOURCES = userdata_test.c
|
|
userdata_test_CFLAGS = $(COMMON_CFLAGS) $(AM_CFLAGS)
|
|
userdata_test_LDADD = libtest.la $(COMMON_LDADD)
|
|
TESTS += userdata_test
|
|
|
|
|
|
check_PROGRAMS += $(TESTS)
|
|
|
|
CLEANFILES = *~ *.log
|
|
|
|
endif
|