Skip to content

Commit

Permalink
Merge pull request #29 from cedwards/master
Browse files Browse the repository at this point in the history
update copyright; fixes #28
  • Loading branch information
cedwards authored Feb 5, 2019
2 parents 29e98b5 + 957465d commit 57bd13c
Show file tree
Hide file tree
Showing 24 changed files with 36 additions and 41 deletions.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
BSD 3-Clause License

Copyright (c) 2018, Christer Edwards <[email protected]>
Copyright (c) 2018-2019, Christer Edwards <[email protected]>
All rights reserved.

Redistribution and use in source and binary forms, with or without
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Then, install via `pkg`.
Example:

```shell
pkg add https://github.com/BastilleBSD/bastille/releases/download/0.3.20181130/bastille-0.3.20181130_2.txz
pkg add https://github.com/BastilleBSD/bastille/releases/download/0.3.20190204/bastille-0.3.20190204.txz
```

BETA binary packages are signed. These can be verified with this pubkey:
Expand Down Expand Up @@ -191,15 +191,15 @@ a private (rfc1918) IP address.
- ip

```shell
ishmael ~ # bastille create folsom 11.2-RELEASE 10.8.62.1
ishmael ~ # bastille create folsom 12.0-RELEASE 10.8.62.1

RELEASE: 11.2-RELEASE.
RELEASE: 12.0-RELEASE.
NAME: folsom.
IP: 10.8.62.1.

```

This command will create a 11.2-RELEASE jail assigning the 10.8.62.1 ip address
This command will create a 12.0-RELEASE jail assigning the 10.8.62.1 ip address
to the new system.

I recommend using private (rfc1918) ip address ranges for your jails.
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# -- Project information -----------------------------------------------------

project = 'Bastille'
copyright = '2018, Christer Edwards'
copyright = '2018-2019, Christer Edwards'
author = 'Christer Edwards'

# The short X.Y version
Expand Down
4 changes: 2 additions & 2 deletions usr/local/bin/bastille
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -32,7 +32,7 @@
. /usr/local/etc/bastille/bastille.conf

## version
BASTILLE_VERSION="0.3.20190102"
BASTILLE_VERSION="0.3.20190204"

usage() {
cat << EOF
Expand Down
1 change: 1 addition & 0 deletions usr/local/etc/bastille/bastille.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ bastille_logsdir=${bastille_prefix}/logs
bastille_releasesdir=${bastille_prefix}/releases
bastille_templatesdir=${bastille_prefix}/templates
bastille_sharedir=/usr/local/share/bastille
bastille_bootstrap_archives=base
18 changes: 6 additions & 12 deletions usr/local/share/bastille/bootstrap.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -58,21 +58,15 @@ bootstrap_release() {
mkdir -p "${bastille_cachedir}/${RELEASE}"
fi

### create $bastille_base/release/$release directory
### fetch $release/base.txz -o $bastille_base/cache/$release/base.txz
### fetch $release/lib32.txz -o $bastille_base/cache/$release/lib32.txz
### extract $release/base.txz to $bastille_base/release/$release
### extract $release/lib32.txz to $bastille_base/release/$release
if [ ! -d "${bastille_releasesdir}/${RELEASE}" ]; then
mkdir -p "${bastille_releasesdir}/${RELEASE}"
sh ${bastille_sharedir}/freebsd_dist_fetch.sh -r ${RELEASE} base lib32
sh ${bastille_sharedir}/freebsd_dist_fetch.sh -r ${RELEASE} ${bastille_bootstrap_archives}

echo
echo -e "${COLOR_GREEN}Extracting FreeBSD ${RELEASE} base.txz.${COLOR_RESET}"
/usr/bin/tar -C "${bastille_releasesdir}/${RELEASE}" -xf "${bastille_cachedir}/${RELEASE}/base.txz"

echo -e "${COLOR_GREEN}Extracting FreeBSD ${RELEASE} lib32.txz.${COLOR_RESET}"
/usr/bin/tar -C "${bastille_releasesdir}/${RELEASE}" -xf "${bastille_cachedir}/${RELEASE}/lib32.txz"
for _archive in ${bastille_bootstrap_archives}; do
echo -e "${COLOR_GREEN}Extracting FreeBSD ${RELEASE} ${_archive}.txz.${COLOR_RESET}"
/usr/bin/tar -C "${bastille_releasesdir}/${RELEASE}" -xf "${bastille_cachedir}/${RELEASE}/${_archive}.txz"
done

echo -e "${COLOR_GREEN}Bootstrap successful.${COLOR_RESET}"
echo -e "${COLOR_GREEN}See 'bastille --help' for available commands.${COLOR_RESET}"
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/cmd.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/console.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/cp.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/create.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
7 changes: 4 additions & 3 deletions usr/local/share/bastille/destroy.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -55,8 +55,9 @@ destroy_jail() {
echo -e "${COLOR_GREEN}Deleting Jail: ${NAME}.${COLOR_RESET}"
chflags -R noschg ${bastille_jail_base}
rm -rf ${bastille_jail_base}
echo -e "${COLOR_GREEN}Note: jail console logs not destroyed.${COLOR_RESET}"
echo -e "${COLOR_GREEN}${bastille_jail_log}${COLOR_RESET}"
mv ${bastille_jail_log} ${bastille_jail_log}-$(date +%F)
echo -e "${COLOR_GREEN}Note: jail console logs archived.${COLOR_RESET}"
echo -e "${COLOR_GREEN}${bastille_jail_log}-$(date +%F)${COLOR_RESET}"
echo
fi
}
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/htop.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/list.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/pkg.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/restart.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/service.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/start.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
3 changes: 1 addition & 2 deletions usr/local/share/bastille/stop.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down Expand Up @@ -57,6 +57,5 @@ fi
for _jail in ${JAILS}; do
echo -e "${COLOR_GREEN}[${_jail}]:${COLOR_RESET}"
jail -f "${bastille_jailsdir}/${_jail}/jail.conf" -r ${_jail}
pfctl -f /etc/pf.conf
echo
done
2 changes: 1 addition & 1 deletion usr/local/share/bastille/sysrc.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/template.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/top.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/update.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/upgrade.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down
2 changes: 1 addition & 1 deletion usr/local/share/bastille/verify.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (c) 2018, Christer Edwards <[email protected]>
# Copyright (c) 2018-2019, Christer Edwards <[email protected]>
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
Expand Down

0 comments on commit 57bd13c

Please sign in to comment.