Commit Graph

580 Commits

Author SHA1 Message Date
tschettervictor
9a157f2fc8 Update clone.sh - remove duplicate line 2024-12-04 08:18:53 -07:00
tschettervictor
0a1e9df948 Update clone.sh - revert jail config edit
This reverts some changes the the "update_jailconf" function.

The reason behind this revert is that if a jail somehow has the same name as a directory, then the previous commit would have changed the directory name as well, which would break stuff.

The current code avoids all that and only replaces the necessary jail name value.
2024-12-04 08:18:03 -07:00
tschettervictor
55203b2298 add support for static MAC on VNET jails
- support static MAC on bridged and VNET jails
- remove quotes around vnet.interface
2024-10-09 11:31:54 -06:00
tschettervictor
ca66263ee2 support cloning of bridged VNET jails + static MAC jails
- fixed cloning of VNET bridged jails
- added support for regenerating static MAC on cloned jails
- simplified some sed commands to edit cloned jail.conf file

Tested with bridged VNET, VNET, and loopback jails
2024-10-09 11:30:09 -06:00
tschettervictor
5fab649266 Add see command to rename bridges interface 2024-10-09 09:15:52 -06:00
tschettervictor
ee21616e81 Uncomment for non-VNET jails 2024-10-09 09:05:49 -06:00
tschettervictor
a9c1bae0ca beginning work to allow cloned jail with new static MAC feature
Current implementation allows for cloning jails that were created using a static MAC.

Also removed some unnecessary sed strings. These were simplified.
2024-10-09 08:47:46 -06:00
tschettervictor
cc75f454b4 spacing edit 2024-10-08 16:35:01 -06:00
tschettervictor
2560b43602 support for -V option also 2024-10-08 16:32:52 -06:00
tschettervictor
0961165d36 add support for static mac address for jails
This commit will generate a static MAC address for each jail, based on the name of the jail. It will use the first half (xx:xx:xx) of the host MAC to avoid network clashes, and generate a random HEX string from the hashed name of the jail. It will then add that random 5 character HEX string in MAC format, and add an "a" and "b" for the host and jail respectively. 

This way a jail can retain it's MAC ID even if it is deleted and reinstalled, as long as the same name is retained.
2024-10-08 16:21:28 -06:00
Juan David Hurtado G
9aeb0ea10c Merge pull request #643 from draga79/master
Adjust devfs_ruleset for hierarchical jails compatibility
2024-07-14 09:00:54 -05:00
yaazkal
09dcdd0ec7 [REF] clean code for PR#650 2024-07-13 17:29:30 -05:00
Juan David Hurtado G
b7b2efca12 Merge pull request #650 from em-winterschon/fbsd-140R-setup-bootstrap-fixes
diff patches applied to resolve errors on setup.sh and bootstrap.sh
2024-07-13 17:20:23 -05:00
Juan David Hurtado G
e441850f81 Merge pull request #665 from andrewhotlab/master
restore check_fib() call
2024-07-13 08:01:20 -05:00
Martin Stoyanov
4859b56050 fix for https://github.com/BastilleBSD/bastille/issues/661 2024-03-13 10:24:54 -05:00
Andrew
5faac5e7a4 restore check_fib() calls
This is needed to respect the "exec.fib" parameter in bastille "console" command, which has been deleted by commit b997be5
2024-01-18 19:55:58 +01:00
Eva Winterschön
19c8c021c4 diff patches applied to resolve errors on setup.sh and bootstrap.sh 2023-12-25 11:39:02 -08:00
Stefano Marinelli
6ca8ea578e Adjust devfs_ruleset for hierarchical jails compatibility
Hierarchical jails inherit the parent jail's permissions and don't support setting devfs_ruleset to a non-zero value. This update adds a check to determine if the script is running inside a jail. If so, it sets devfs_ruleset to 0 to comply with this constraint.
2023-11-27 18:45:09 +01:00
Christer Edwards
3a4ebc63bb Merge pull request #642 from BastilleBSD/support_lowercase
fix logic for rc.conf + bastille.conf ZFS check
2023-11-25 19:15:16 -07:00
Christer Edwards
c627b1f7fa fix logic for rc.conf + bastille.conf ZFS check 2023-11-25 19:11:57 -07:00
Christer Edwards
dd60e7f175 add support for bastille_vnet devfs.rules in bastille setup 2023-11-25 17:19:57 -07:00
Christer Edwards
32d67aea40 Merge pull request #640 from BastilleBSD/eol_patch
fix for recent EOL support patch
2023-11-25 17:07:56 -07:00
Christer Edwards
b30a7484bb fix for recent EOL support patch 2023-11-25 17:06:05 -07:00
Christer Edwards
622c926917 support lowercase values in bastille.conf (issue #368) 2023-11-25 15:09:11 -07:00
Christer Edwards
97a0e692d9 standardize options in create matrix 2023-11-24 16:41:25 -07:00
Christer Edwards
3df39078bf support combining options for bastille create 2023-11-24 16:28:31 -07:00
Christer Edwards
8906e491d0 initial support & docs to bootstrap EOL releases 2023-11-20 16:07:11 -07:00
Christer Edwards
ace7bdce2f add osrelease to jail.conf for new jails 2023-11-19 14:37:31 -07:00
Romain Tartière
157125c4af Relax validation of -BETA / -RC releases
Accross the code, release names are checked against some variation of
-BETAx / -RCx which are inconsistent in the range of accepted values for
`x`.

As  a consequence, some commands cannot be successfuly run while they
are valid, e.g. `bastille create test 14.0-RC4 10.0.0.2` is rejected
because only `*-RC1` and `*-RC2` are accepted as a RC release name.

Find out these lists of specific BETA and RC patterns and adjust them to
allow any one-digit value at the end.  We generaly do up to 4 BETA / RC
releases, so a one digit limit is probably enough for the time being.
2023-11-10 08:09:51 -10:00
Barry McCormick
df00a7939e Merge pull request #623 from adriel-tech/patch-1
fix configure_zfs() to properly return status of zfs module.
2023-11-01 08:38:17 -07:00
Michal Procházka
cf928f1237 Fix generated interface name in rc.conf for vnet jail 2023-10-30 20:39:58 +01:00
adriel-tech
11367238ec Update setup.sh
Removed -q from kldstat in function configure_zfs().
on FreeBSD 14 (maybe earlier) this causes kldstat to return in such
a way that BastilleBSD assumes zfs is not loaded.
2023-10-29 15:16:39 -07:00
Nikos Chondros
445b42ed39 Merge branch 'master' into master 2023-10-26 20:51:15 +03:00
tucoinfo
e7eb9b7717 fix-issue-601
#601
2023-10-19 15:16:37 +02:00
Barry McCormick
721a5ca6a0 fix for JID instead of jail name in list printout 2023-10-18 18:26:55 -07:00
Barry McCormick
91f479e5d7 Merge pull request #598 from JRGTH/import_enhancements
Validate jib during jail import
2023-10-18 08:55:10 -07:00
Barry McCormick
f35de69b28 Merge pull request #605 from JRGTH/rdr_fixes
Add rdr pf conf check
2023-10-18 08:53:47 -07:00
Barry McCormick
e078aed54a Merge pull request #608 from tub5ta/patch-1
Permit jail upgrades to use BETA and RC branches
2023-10-18 08:53:26 -07:00
Christer Edwards
40e4b817d8 prep & cleanup for 0.10.20231013 release 2023-10-10 19:51:10 -06:00
Barry McCormick
3355c07dbf rdr disable directive fix 2023-10-04 10:13:08 -07:00
Jason Tubnor
aa688f7072 Update upgrade.sh
Allow the uplift of jails to test BETA and RC branches before release
2023-09-20 09:44:28 +10:00
JRGTH
d6b5733d48 Add rdr pf conf check
Prevent shutdown/rdr command stalls.
2023-09-07 08:34:28 -04:00
JRGTH
72bd211f7b Validate jib during jail import 2023-07-19 10:56:20 -04:00
Christer Edwards
3ea553086f source bastille.conf for pf path support 2023-07-14 21:53:02 -06:00
Christer Edwards
e15a481e46 setup now references bastille_pf_conf variable 2023-07-14 21:07:36 -06:00
Christer Edwards
15f2ea8574 Merge branch 'master' of https://github.com/bastillebsd/bastille into 2023_release 2023-07-14 21:02:30 -06:00
Christer Edwards
4efcc5021c update copyright dates 2023-07-14 21:02:14 -06:00
Christer Edwards
a2e1befa80 Merge pull request #587 from JRGTH/list_cmd_update
list cmd enhancement
2023-07-14 16:37:01 -06:00
Christer Edwards
a406654e18 Merge pull request #593 from gqgunhed/gqgunhed-linux-releases
Updated supported Linux releases
2023-07-14 16:34:24 -06:00
skenizen
373ccd45d9 changed the occurence of path /etc/pf.conf in the rdr.sh script for reading it as a variable from the bastille configuration. 2023-07-12 10:57:46 +02:00