• Stars
    star
    2,189
  • Rank 21,073 (Top 0.5 %)
  • Language
    Shell
  • License
    MIT License
  • Created about 9 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

👢 Bootstrap your macOS development system.

Strap

A script to bootstrap a minimal macOS development system. This does not assume you're doing Ruby/Rails/web development but installs the minimal set of software every macOS developer will want.

Motivation

Replacing Boxen in GitHub with a better tool. This post outlines the problems with Boxen and requirements for Strap and other tools used by GitHub: https://mikemcquaid.com/2016/06/15/replacing-boxen/

Features

  • Enables sudo using TouchID
  • Disables Java in Safari (for better security)
  • Enables the macOS screensaver password immediately (for better security)
  • Enables the macOS application firewall (for better security)
  • Adds a Found this computer? message to the login screen (for machine recovery)
  • Enables full-disk encryption and saves the FileVault Recovery Key to the Desktop (for better security)
  • Installs the Xcode Command Line Tools (for compilers and Unix tools)
  • Agree to the Xcode license (for using compilers without prompts)
  • Installs Homebrew (for installing command-line software)
  • Installs Homebrew Bundle (for bundler-like Brewfile support)
  • Installs Homebrew Services (for managing Homebrew-installed services)
  • Installs Homebrew Cask (for installing graphical software)
  • Installs the latest macOS software updates (for better security)
  • Installs dotfiles from a user's https://github.com/username/dotfiles repository. If they exist and are executable: runs script/setup to configure the dotfiles and script/strap-after-setup after setting up everything else.
  • Installs software from a user's Brewfile in their https://github.com/username/homebrew-brewfile repository or .Brewfile in their home directory.
  • A simple web application to set Git's name, email and GitHub token (needs authorised on any organisations you wish to access)
  • Idempotent

Out of Scope Features

  • Enabling any network services by default (instead enable them when needed)
  • Installing Homebrew formulae by default for everyone in an organisation (install them with Brewfiles in project repositories instead of mandating formulae for the whole organisation)
  • Opting-out of any macOS updates (Apple's security updates and macOS updates are there for a reason)
  • Disabling security features (these are a minimal set of best practises)
  • Add phone number to security screen message (want to avoid prompting users for information on installation)

Usage

Open https://strap.mikemcquaid.com/ in your web browser.

Instead, to run Strap locally run:

git clone https://github.com/MikeMcQuaid/strap
cd strap
bash bin/strap.sh # or bash bin/strap.sh --debug for more debugging output

Instead, to run the web application locally run:

git clone https://github.com/MikeMcQuaid/strap
cd strap
./script/bootstrap
GITHUB_KEY="..." GITHUB_SECRET="..." ./script/server

Strap is also available as a Docker image on Docker Hub (mikemcquaid/strap) and GitHub Packages (ghcr.io/mikemcquaid/strap).

Web Application Configuration Environment Variables

  • GITHUB_KEY: the GitHub.com Application Client ID.
  • GITHUB_SECRET: the GitHub.com Application Client Secret.
  • SESSION_SECRET: the secret used for cookie session storage.
  • WEB_CONCURRENCY: the number of Unicorn (web server) processes to run (defaults to 3).
  • STRAP_ISSUES_URL: the URL where users should file issues (defaults to no URL).
  • STRAP_BEFORE_INSTALL: instructions displayed in the web application for users to follow before installing Strap (wrapped in <li> tags).
  • CUSTOM_HOMEBREW_TAP: an optional Homebrew tap to install with brew tap. Specify multiple arguments to brew tap by separating values with spaces.
  • CUSTOM_BREW_COMMAND: a single brew command that is run after all other stages have completed.

Status

Stable and in active development.

Contact

Mike McQuaid

License

Licensed under the MIT License. The full license text is available in LICENSE.txt.

More Repositories

1

GitInPractice

📖 An opinionated intermediate/advanced Git book
1,029
star
2

TwitterDelete

💀 Deleted your old, unpopular tweets (archived)
Ruby
281
star
3

dotfiles

💻 My dot files shared between machines.
Shell
261
star
4

HookHand

↪️ Runs scripts from webhooks.
Ruby
57
star
5

Qocoa

☕️ Qt wrappers for macOS Cocoa widgets.
C++
45
star
6

GitInPracticeRedux

👩🏼‍💻 A repository created by working through the examples in Git In Practice
41
star
7

scripts

💀 This was a collection of helper scripts I wrote and shared between machines.
18
star
8

ManningAsciiDoc

📚 Rake buildsystem for generating Manning DocBook and PDF files from AsciiDoc.
Ruby
17
star
9

mikemcquaid.com

😅 The home page for a software engineer named Mike McQuaid.
HTML
13
star
10

gitinpractice.com

🏡 The home page for an opinionated intermediate/advanced Git book
Ruby
11
star
11

MikeMcQuaid

👓 My GitHub Profile README
10
star
12

LockOldIssues

🔒 LockOldIssues was a small application to lock your old, closed GitHub issues.
Ruby
9
star
13

cantyoujust.no

Can't you just ...? NO.
HTML
7
star
14

imdb-watcher

🎦 Ruby script to turn IMDB watchlists into iTunes and Netflix streaming URLs.
Ruby
7
star
15

RemoveMPEG4MetaData

🎥 A tool to erase metadata from MPEG4 files.
Objective-C
5
star
16

Fabula

📖 A RPG conversation editor.
C++
5
star
17

ESPCKML

🏤 Bookmarklet to overlay a KML file on the Edinburgh Solicitors Property Centre's maps.
CoffeeScript
5
star
18

GitInPracticeErrata

🐛 Errata for Git In Practice
4
star
19

mmq.lol

🩳 A URL shortener for Mike McQuaid
Ruby
3
star
20

NightSkyLine

🌃 A readable HTML5 and CSS3 Wordpress theme.
CSS
3
star
21

AsciiDoc.tmbundle

📘 TextMate support for AsciiDoc
3
star
22

SampleManningAsciiDocBook

📘 This repository is a sample Manning AsciiDoc book to be used with ManningAsciiDoc.
3
star
23

GitInPracticeReduxSubmodule

🚉 A test submodule repository used by an example in Git In Practice
3
star
24

Whiteboard

⬜ Android app that hosts an HTML5-based whiteboard server.
Java
3
star
25

.github

👩‍⚕️ Default community health files for the MikeMcQuaid user on GitHub.
2
star
26

GitForBeginnersDemo

🏫 The demo for my Git For Beginners talk.
2
star
27

PlanningCenterChecks

⛪ A simple use of the Planning Centre Online API to query for data that hasn't been input correctly.
Ruby
1
star