Commit Graph

18 Commits

Author SHA1 Message Date
Christian Hesse
a2c8dd3173 archiso_pxe_common: remove resolv.conf before copy
Booting via PXE we want to keep our DNS configuration. So remove
/etc/resolv.conf in new root before copying the current file.

Without this systemd-resolved fallback nameservers are used and we see an
error message when the root ships a symbolic link to systemd-resolved's
stub-resolv.conf:

cp: not writing through dangling symlink '/new_root/etc/resolv.conf'
2021-01-26 21:59:01 +00:00
fdupoux
2c99df5c9b Reset network interfaces at the end of the PXE boot to allow DHCP to run 2020-11-18 21:16:27 +00:00
David Runge
e264b44682
Add license and basic documentation
LICENSE:
Add GPL-3.0 license.

{{archiso,configs}/*,.editorconfig,.gitlab-ci.yml}:
Add SPDX license identifier.

Makefile:
Add SPDX license identifier.
Install the `run_archiso.sh` script as global executable `run_archiso`.
Use -D and -t flags to install to install files more generically (without a previous call to install the directory).

README.rst:
Add README outlining the project's scope, how to build images from the profiles and how to test.

AUTHORS.rst:
Add list of all direct contributors to the repository.

CONTRIBUTING.rst:
Add basic contribution guidelines, explaining the linter and the license in use.

Closes #7
Closes #3
2020-07-29 14:27:48 +02:00
nl6720
b40fb2ae53
Separate custom comments from shellcheck comments
Having a shellcheck directive and custom comments in the same line can trigger SC1107 on old versions of shellcheck.
2020-07-17 10:42:14 +03:00
David Runge
e2032db4e7
Adding linting for initcpio scripts
archiso/initcpio/install/*:
Setting bash shebang for all scripts and making them comform with shellcheck.

archiso/initcpio/{hooks,script}/*:
Setting ash shebang for all scripts and making them comform with shellcheck (for dash, as shellcheck has no ash specific
ruleset). Essentially the ash based scripts should be POSIX compliant as much as possible to have an easier time
writing, debugging and maintaining them.
Ensuring that variables are not treated as options and introducing variable quoting.

.gitlab-ci.yml:
Integrating shellcheck for initcpio scripts.

Closes #32
2020-07-11 20:58:01 +02:00
David Thurstenson
3fec501225 Handle case where ip=dhcp
Signed-off-by: David Thurstenson <thurstylark@gmail.com>
2017-03-14 11:12:29 -03:00
David Thurstenson
ae854ed712 Add timeout to ipconfig call
Signed-off-by: David Thurstenson <thurstylark@gmail.com>
2017-03-14 11:12:29 -03:00
Christian Hesse
a04548ce2a pxe-common: not only search, but also domain entry in resolv.conf
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-09-29 19:34:51 -03:00
Christian Hesse
7b5d876742 pxe-common: add dns domain name in resolv.conf
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-09-29 19:34:51 -03:00
Christian Hesse
38b81f0384 pxe-common: add a comment what added settings to resolv.conf
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-09-29 19:34:51 -03:00
Christian Hesse
a9e7b0d50b flush and set down only if boot interface is known
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-05-28 13:47:10 -03:00
Christian Hesse
ca288915c0 do not declare bootif_dev local
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-05-27 18:57:54 -03:00
Christian Hesse
1bd3d4ec55 use ip syntax according to ip-address(8)
According to ip-address(8) flushing an interface requires the
keyword 'dev'.
Also add proper quoting.

Signed-off-by: Christian Hesse <mail@eworm.de>
2016-05-27 13:49:24 -03:00
Christian Hesse
51b7ed7f18 only run pxe late hook if $ip is given
Signed-off-by: Christian Hesse <mail@eworm.de>
2016-05-24 21:31:37 -03:00
Gerardo Exequiel Pozzi
e018653a23 [archiso] Set net iface down if copytoram=y (default)
This should fix FS#36749

Also flush address on specified device (default)

Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@gmail.com>
2016-03-18 22:04:16 -03:00
Christian Hesse
f21da59e81 flush ip addresses after copy to RAM
We received an IP address from DHCP server and configure it statically.
This is required if we continue to use network connectivity to access
the root device (for example via NBD or NFS).

The lease is not updated, though. This can cause trouble in networks
with low lease times. So let's flush the addresses if root filesystem
has been copied to RAM. A dhcp client in main system can handle the
network connectivity then.

Signed-off-by: Christian Hesse <mail@eworm.de>
2015-06-24 21:52:40 -03:00
Christian Hesse
b1a397e98d launch interactive shell if ipconfig fails
Signed-off-by: Christian Hesse <mail@eworm.de>
2015-05-29 13:10:42 -03:00
Gerardo Exequiel Pozzi
5df61f0c9e [archiso] Rework Makefile / Reorder files
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
2012-08-25 15:14:51 -03:00