Loading…

Alpine as docker host

Alpine is a super small linux distribution. I am using it for all my new VMs running a docker instance.

Install alpine

  • Download alpine (virtual edition) ISO from https://alpinelinux.org/downloads/
  • Boot ISO and login with root and no password.
  • Start setup with setup-alpine command and follow instructions

Add SSH Key

# apk add curl
# mkdir -p /root/.ssh
# curl -L https://<yourserver>/ssh_key > /root/.ssh/authorized_keys

Install docker

# apk add nano
# nano /etc/apk/repositories

Enable edge-community repository.

# apk add docker docker-compose
# service docker start
# rc-update add docker

Shell helpers

Add ll alias

# nano ~/.profile

Add following line:

alias ll="ls -la"

To shutdown alpine user

# poweroff

Author: Anton Bracke

Software engineering student from Germany. Loves programming in PHP, JS and sometimes C.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.