Brew Cask Install

/ Comments off

Brew install -cask chromedriver, this would install your desired version. After that you can always do git checkout master and brew up to keep in sync with the latest master of homebrew-cask. Here is my installation log. I've installed BasicTex via Homebrew Cask (brew cask install basictex) which supposedly includes pdfTeX and a bunch of other tools Stack Exchange Network Stack Exchange network consists of 178 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their.

This is a step-by-step guide to installing and running Kubernetes on your Mac so that you can develop applications locally.

You will be guided through running and accessing a Kubernetes cluster on your local machine using the following tools:

Cached
  • Homebrew
  • Docker for Mac
  • Minikube
  • virtualbox
  • kubectl

Installation Guide

The only pre-requisite for this guide is that you have Homebrew installed. Homebrew is a package manager for the Mac. You’ll also need Homebrew Cask, which you can install after Homebrew by running brew tap caskroom/cask in your Terminal.

Brew Cask Install Anaconda

  1. Install Docker for Mac. Docker is used to create, manage, and run our containers. It lets us construct containers that will run in Kubernetes Pods.

  2. Install VirtualBox for Mac using Homebrew. Run brew cask install virtualbox in your Terminal. VirtualBox lets you run virtual machines on your Mac (like running Windows inside macOS, except for a Kubernetes cluster.)

    Skip to step three if everything has worked to this point.

    In my case, I already had the non-Homebrew VirtualBox app installed which caused issues when trying to start minikube.

    If you already have VirtualBox installed, start the installation as before with brew cask install virtualbox. You will get a warning that confirms this saying Warning: Cask 'virtualbox' is already installed.. Once this is confirmed, you can reinstall VirtualBox with Homebrew by running brew cask reinstall virtualbox.

    If you happen to have VirtualBox already running when you do this, you could see an error saying Failed to unload org.virtualbox.kext.VBoxDrv - (libkern/kext) kext is in use or retained (cannot unload).

    This is because the kernel extensions that VirtualBox uses were in use when the uninstall occurred. If you scroll up in the output of that command, beneath Warning! Found the following active VirtualBox processes: you’ll see a list of the processes that need to be killed.

    Kill each of these in turn by running kill first_column_number (first_column_number is the process identifier for that process).

    Now re-run brew cask reinstall virtualbox and it should succeed.

  3. Install kubectl for Mac. This is the command-line interface that lets you interact with Kuberentes. Run brew install kubectl in your Terminal.

  4. Install Minikube via the Installation > OSX instructions from the latest release. At the time of writing, this meant running the following command in Terminal…

    Minikube will run a Kubernetes cluster with a single node.

  5. Everything should work! Start your Minikube cluster with minikube start. Then run kubectl api-versions. If you see a list of versions, everything’s working! minikube start might take a few minutes.

  6. At this point, I got an error saying Error starting host: Error getting state for host: machine does not exist. because I had previously tried to run Minikube. You can fix this by running open ~/.minikube/ to open Minikube’s data files, and then deleting and deleting the machines directory. Then run minikube start again.

Come Together

You’ve installed all these tools and everything looks like it’s working. A quick explanation of how the components relate is needed.

  • VirtualBox is a generic tool for running virtual machines. You can use it to run Ubuntu, Windows, etc. inside your macOS operating system host.
  • Minikube is a Kubernetes-specific package that runs a Kubernetes cluster on your machine. That cluster has a single node and has some unique features that make it more suitable for local development. Minikube tells VirtualBox to run. Minikube can use other virtualization tools—not just VirtualBox—however these require extra configuration.
  • kubectl is the command line application that lets you interact with your Minikube Kubernetes cluster. It sends request to the Kubernetes API server running on the cluser to manage your Kubernetes environment. kubectl is like any other application that runs on your Mac—it just makes HTTP requests to the Kubernetes API on the cluster.

Homebrew is a package manager for MAC OS X. Using Homebrew you can directly download and install many open source software and unix tools. Again instead of downloading .dmg files and moving the applications you may use Homebrew Cask to install these applications. Applications like VLC, Google Chrome and many other utility applications which are not in Mac App Store can also be installed on your Mac using this package manager. Go through the steps mentioned below to know how to install Homebrew and Homebrew cask and how to install packages using Homebrew / Homebrew Cask on your Macbook.

Steps to install Homebrew and Homebrew Cask on Mac OS X

1. First of all, open the Terminal and install Xcode.
xcode-select –install
If it’s already installed you will get below message.
“command line tools are already installed, use “Software Update” to install updates.”

2. Now, run below command to install Homebrew.
ruby -e “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)”
Make sure, you are not running it from root user. It will ask for password. Provide the password and hit “Enter”. Once done press “Return” / “Enter” key to proceed further.

3. To ensure that Homebrew is working properly, run below command.
brew doctor
You should get the output as “Your system is ready to brew”

4. Now run below to install Homebrew Cask.

Debaleenas-MacBook-Pro:~ TechEntice$ brew install caskroom/cask/brew-cask
> Tapping caskroom/cask
Cloning into '/usr/local/Library/Taps/caskroom/homebrew-cask'...
remote: Counting objects: 3058, done.
remote: Compressing objects: 100% (2973/2973), done.
remote: Total 3058 (delta 100), reused 718 (delta 69), pack-reused 0
Receiving objects: 100% (3058/3058), 5.77 MiB 196.00 KiB/s, done.
Resolving deltas: 100% (100/100), done.
Checking connectivity... done.
Tapped 1 formula (3037 files, 23M)
> Installing brew-cask from caskroom/homebrew-cask
> Cloning https://github.com/caskroom/homebrew-cask.git
Cloning into '/Library/Caches/Homebrew/brew-cask--git'...
remote: Counting objects: 2999, done.
remote: Compressing objects: 100% (2902/2902), done.
remote: Total 2999 (delta 117), reused 834 (delta 81), pack-reused 0
Receiving objects: 100% (2999/2999), 5.74 MiB 317.00 KiB/s, done.
Resolving deltas: 100% (117/117), done.
Checking connectivity... done.
Note: checking out '2fc9d2323950a45549e1d5c4b25481d98726b85c'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

git checkout -b new_branch_name

> Checking out tag v0.54.1
🍺 /usr/local/Cellar/brew-cask/0.54.1: 2731 files, 11M, built in 70 seconds
Aniks-MacBook-Pro:~ TechEntice$

You may use install/uninstall/search in brew and brew cask to perform. Below we have installed sshfs using brew cask.

Brew Cask Install Chromedriver

Debaleenas-MacBook-Pro:~ TechEntice$ brew search sshfs
homebrew/fuse/sshfs Caskroom/cask/sshfs

Debaleenas-MacBook-Pro:~ TechEntice$ brew cask install sshfs
> We need to make Caskroom for the first time at /opt/homebrew-cask/Caskroom
> We'll set permissions properly so we won't need sudo in the future
Password:
> Satisfying dependencies
> Installing Cask dependencies: osxfuse
osxfuse ...
> Downloading http://downloads.sourceforge.net/project/osxfuse/osxfuse-2.7.5/osxfuse-2.7.5.dmg
######################################################################## 100.0%
> Running installer for osxfuse; your password may be necessary.
> Package installers may write to any location; options such as --appdir are ignored.
> installer: Package name is FUSE for OS X (OSXFUSE)
> installer: Installing at base path /
> installer: The install was successful.
🍺 osxfuse staged at '/opt/homebrew-cask/Caskroom/osxfuse/2.7.5' (6 files, 8.5M)
done
complete
> Downloading https://github.com/osxfuse/sshfs/releases/download/osxfuse-sshfs-2.5.0/sshfs-2.5.0.pkg
######################################################################## 100.0%
> Running installer for sshfs; your password may be necessary.
> Package installers may write to any location; options such as --appdir are ignored.
> installer: Package name is SSHFS 2.5.0
> installer: Upgrading at base path /
> installer: The upgrade was successful.
🍺 sshfs staged at '/opt/homebrew-cask/Caskroom/sshfs/2.5.0' (3.5M)

Brew Cask Install Java

Check man brew or man brew cask for it’s detailed usage.