Skip to content

iflowfor8hours/postinstall

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

postinstall.sh

Build Status

Bash Script to automate post-installation steps. Helps to install packages on different operating systems.

Apple macOS Arch Linux CentOS Debian Fedora FreeBSD OpenBSD Red Hat SUSE Slackware Ubuntu Android Termux Alpine Linux

Cygwin and Haiku are also supported.

Overview

postinstall.sh is simple bash shell script which in turn generates scripts. The generation depends on the operating system and type of installation. The templates that are included in the generation can be stored in the file system or on a web server. This can also be your GitHub repository. Just fork this repository and edit it according to your needs.

postinstall.sh is not a configuration management system. If you want to install many servers automatically, you should look at ansible. But if you want to quickly reinstall your laptop or Raspberry Pi, postinstall.sh can help you.

Please check the Wiki for more information.

Installation

Download:

curl -f https://raw.githubusercontent.com/Cyclenerd/postinstall/master/postinstall.sh -o postinstall.sh

Alternative download with short URL:

curl -fL http://bit.ly/get_postinstall -o postinstall.sh

Run as root:

bash postinstall.sh

Usage

Usage: postinstall [-t <TYPE>] [-b <BASE>] [-h]:
	[-t <TYPE>] sets the type of installation
	[-b <BASE>] sets the base url or dir
	[-h]        displays help

Example: postinstall.sh or postinstall.sh -t workstation

Screenshot

Fedora

Program Flow

  • Determine operating system and architecture
  • Check package manager and requirements
  • Generate script to run before and after installation and list of packages to install
  • Install packages

Requirements

Only bash, curl, tput (ncurses-utils) and a package manager for the respective operating system:

  • Alpine Linux β†’ apk
  • Apple macOS β†’ port or brew
  • Arch Linux β†’ pacman
  • Cygwin β†’ apt-cyg
  • Debian / Ubuntu β†’ apt-get
  • FreeBSD β†’ pkg
  • Haiku β†’ pkgman
  • NetBSD β†’ pkg_add
  • OpenBSD β†’ pkg_add
  • OpenWRT β†’ opkg
  • Red Hat / Fedora / CentOS β†’ dnf or yum
  • Slackware β†’ slackpkg
  • SUSE / openSUSE β†’ zypper
  • Termux β†’ pkg

TODO

  • More and better documentation
  • Support for even more operating systems and package managers

Help is welcome πŸ‘

License

GNU Public License version 3. Please feel free to fork and modify this on GitHub (https://github.com/Cyclenerd/postinstall).

About

πŸ’» Bash Script to automate post-installation steps

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 100.0%