General 

Homebrew

Homebrew is used as package manager for most required tools.

Installation:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

If homebrew is already installed, update it and uprade the installed packages:

brew upgrade

Texteditor

For editing files at the commandline, you must have an editor on your local system.

For example, you can use:

  • nano

    brew install nano

    To set nano as your default text editor for your shell, add the following line to your personal .bashrc or .zshrc file:

    export EDITOR=/usr/bin/nano

     You can also set any other editor as default by replacing /usr/bin/nano with the path to your editor.

  • atom
  • Visual Studio Code

Advice

Before you install the editor of your choice, check if you apply to terms of license to use the tool.


Development

Git

Check if git is already installed on your system:

which git

Installation:

brew install git

Check if you have access to the censhare git repository:

https://git.censhare.com

To clone censhare git repositories locally, access via ssh keys must be configured for your git account. To check:

  • Login to https://git.censhare.com.
  • Click the user menu at the top right and select Preferences.
  • Click the SSH Keys entry on the left navigation bar.
  • On the SSH Keys page, check the Your SSH keys section:
    • If there is an entry, you have already configured an SSH key for git access.
    • If the entry is Your SSH keys (0), you must upload your public SSH key.


Check if you have already configured an SSH key on your system. It shows the public key of your SSH key pair:

cat ~/.ssh/id_rsa.pub

If not, create an SSH key with 2048-bit RSA. Use the default directory as suggested:

# generate the key
ssh-keygen -t rsa -b 2048
# Display the public key
cat ~/.ssh/id_rsa.pub
  • Copy the public key from the terminal and paste it into Key field on the SSH Keys page.
  • Enter a name for the key in the Title field.
  • Click Add key.

If you have not yet configure SSL access, you can also use HTTPS that uses the web browser:

git clone https://git.censhare.com:foo/bar

Sourcetree

If you like to work with a graphical git client, you can install Sourctree.

Xcode

Check in the application folder if Xcode is installed. If not, ask IT support to install it on your Mac from the App store.

node

For example, node is used to build the webpack packages that are delivered through the Static Resource Server.

For installation of node and a better handling of the different node version, we use the node version manager.

Installation:

brew install nvm

Check your installation:

nvm --version

Install the latest LTS version of node:

nvm install --lts

Use the LTS version:

nvm use --lts

For now, the local build of webpacks for censhare WP requires version 12 of node:

nvm install 12

If node version manager is already installed, check if version 12 is installed and selected:

nvm list

Select version 12:

nvm use 12

Yarn

Yarn is a package manager for JavaScript. For example, it is used to build the webpacks locally.

Installation:

brew install yarn

Maven

Maven is a build automation tool mainly for Java projects. Among others, it also used to build the jar file for microservices locally, for example the Cloud Gateway and the Static Resource Server.

Installation:

brew install mvn

To build the jar files, maven requires access to censhare Artifactory to download required artifacts such as libraries. You must configure maven that it can access Artifactory.

Java 11 JDK

We use the Amazon Corretto distribution for the Java 11 JDK. Download and install the latest package from this URL: https://corretto.aws/downloads/latest/amazon-corretto-11-x64-macos-jdk.pkg

Check installation:

/usr/libexec/java_home -V

jenv

Info

You must only install jenv if you want to run censhare versions prior to 2019.1 locally, as these require Java 8. Otherwise, you can skip this step.

Installation:

brew install jenv && mkdir ~/.jenv/versions

Add Java 11 to jenv:

jenv add <path_to_Java11>

Tools for censhare Server

Image-Service-Tools

Install the latest package of Image-Service-Tools from the censhare repository (censhare-ImageService-tools-<yyyy>.pkg).


Database

PostgresSQL

Download Postgres.app from https://postgresapp.com/downloads.html. Minimal required PostgreSQL version is 12. For information, see System requirements.

Check if PSQL is accessible:

which psql

If not, add the following line to your personal .bashrc or .zshrc file:

PATH=$PATH:/Applications/Postgres.app/Contents/Versions/latest/bin

Start a new shell and test availability again.

Container and microservices

Docker

Docker is required to run container applications locally, for example Keycloak or Kafka. It is also used when building microservices, for example Cloud Gateway or Static Resource Server.

To download and install Docker for Desktop: https://docs.docker.com/desktop/mac/install/.

Info

Docker for Desktop requires a license with extra costs that has to be acquired. Talk to your manager for this.

Minikube

To run microservices or container apps, for example Keycloak, locally for ETS development, minikube is used.

Installation:

brew install minikube

Hyperkit

Hyperkit is used as driver for minikube.

Installation:

brew install hyperkit

Tools for ETS

ETS is based on Kubernetes. If you want to manage a ETS cluster from the command line, install the following tools.

Kubectl

Kubectl is the CLI tool to work with Kubernetes clusters and used access ETS cluster, including team clusters.

Installation:

brew install kubectl

Kubectx

Kubectx is a tool that allows to switch fast between different contexts for different Kubernetes clusters. A context defines which namespace, which Kubernetes cluster, and which access credentials to use when Kubernetes commands are executed.

Installation:

brew install kubectx

kcat

Kcat is used to read messages from a Kafka topic as a Consumer and write messages to a Kafka topic as a Producer. It is formerly known as kafkacat.

brew install kcat

kn

kn is the command line tool for managing serverless functions deployed to knative.

Installation:

brew install kn

Tools for EKS clusters on Amazon AWS

If you are working with ETS clusters that are running on Amazon EKS, also install the following tools.

awscli

awscli is the command line to to manage Amazon AWS services.

Installation:

brew install awscli

Add the following lines to your to your personal .bashrc or .zshrc file:

export AWS_PROFILE=saml
export AWS_DEFAULT_PROFILE=saml

Create a text file:

~/.aws/credentials

Add the following content to the file:

[saml]
output = json
region = eu-central-1

eksctl

eksctl is the command line tool for Kubernetes clusters based on Amazon EKS.

Installation:

brew install eksctl