Table of Content

vmware config

1 CPU
4G memory
100GB harddisk
network: NAT

test NAT Internet access

oldhorse@ubdev:~$ cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
# 127.0.0.53 is the systemd-resolved stub resolver.
# run "systemd-resolve --status" to see details about the actual nameservers.

nameserver 127.0.0.53
oldhorse@ubdev:~$ ping google.ca
PING google.ca (172.217.9.163) 56(84) bytes of data.
64 bytes from dfw25s27-in-f3.1e100.net (172.217.9.163): icmp_seq=1 ttl=128 time=42.6 ms
64 bytes from dfw25s27-in-f3.1e100.net (172.217.9.163): icmp_seq=2 ttl=128 time=42.2 ms
^C
--- google.ca ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1002ms
rtt min/avg/max/mdev = 42.277/42.469/42.662/0.282 ms

ssh server on vm

$ sudo apt-get install aptitude
$ sudo aptitude install openssh-server
oldhorse@ubdev:~$ sudo service ssh status
[sudo] password for oldhorse:
● ssh.service - OpenBSD Secure Shell server
Loaded: loaded (/lib/systemd/system/ssh.service; enabled; vendor preset: enab
Active: active (running) since Sat 2017-12-09 05:31:04 PST; 5min ago
Main PID: 1240 (sshd)
Tasks: 1 (limit: 19660)
Memory: 2.1M
CPU: 48ms
CGroup: /system.slice/ssh.service
└─1240 /usr/sbin/sshd -D

Dec 09 05:31:29 ubdev systemd[1]: Reloading OpenBSD Secure Shell server.
Dec 09 05:31:29 ubdev sshd[1240]: Received SIGHUP; restarting.
Dec 09 05:31:29 ubdev systemd[1]: Reloaded OpenBSD Secure Shell server.
Dec 09 05:31:29 ubdev sshd[1240]: Server listening on 0.0.0.0 port 22.
Dec 09 05:31:29 ubdev sshd[1240]: Server listening on :: port 22.
Dec 09 05:31:40 ubdev systemd[1]: Reloading OpenBSD Secure Shell server.
Dec 09 05:31:40 ubdev sshd[1240]: Received SIGHUP; restarting.
Dec 09 05:31:40 ubdev systemd[1]: Reloaded OpenBSD Secure Shell server.
Dec 09 05:31:40 ubdev sshd[1240]: Server listening on 0.0.0.0 port 22.
Dec 09 05:31:40 ubdev sshd[1240]: Server listening on :: port 22.

then you can ssh from host to vm using putty for rest CLI works.

update packages

$ sudo apt-get update
$ sudo apt-get upgrade -y
$ sudo apt-get install git -y
$ sudo apt-get install curl -y

hgfs share folder

vmware tools not working for hgfs, only solution is to use open-vm-tools,

$ git clone https://github.com/rasa/vmware-tools-patches.git
$ cd vmware-tools-patches
$ sudo ./patched-open-vm-tools.sh

after reboot, can see hgfs mount now:

root@ubuntu:~# df -h
vmhgfs-fuse 1.9T 1.2T 672G 64% /mnt/hgfs

desktop config

changed unity launcher icon size by:
system setting/appearance/launcher icon size

Cairo-Dock

install Cairo-Dock from Ubuntu Software

as desktop the unity is good enough, dock is optional just for fun.

The only I changed for cairo setting:

  • cairo icon size
  • cairo-dock/config/Themes MacOSX turn off animation for mouse on

unity tweak tools

settings manager for the Unity desktop, will make the desktop config more easy.

sublime text 3

oldhorse@ubdev:~$ sudo add-apt-repository ppa:webupd8team/sublime-text-3
oldhorse@ubdev:~$ sudo apt-get update
oldhorse@ubdev:~$ sudo apt-get install sublime-text-installer

oldhorse@ubdev:/opt/sublime_text$ sudo ln -s /opt/sublime_text/sublime_text /usr/local/bin/sb3

sb3 test.txt &

ReText for markdown

ReText is a simple but powerful editor for Markdown and reStructuredText markup languages.

It provides live preview and HTML/PDF export.

Install retext from Ubuntu Software.

pip

oldhorse@ubdev:~$ which -a pip
oldhorse@ubdev:~$ sudo apt-get install python-setuptools
oldhorse@ubdev:~$ sudo easy_install --upgrade pip
oldhorse@ubdev:~$ pip --version
pip 9.0.1 from /usr/local/lib/python2.7/dist-packages/pip-9.0.1-py2.7.egg (python 2.7)

docker CE

oldhorse@ubdev:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 17.04
Release: 17.04
Codename: zesty

oldhorse@ubdev:~$ uname -a
Linux ubdev 4.10.0-30-generic #34-Ubuntu SMP Mon Jul 31 19:38:17 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

oldhorse@ubdev:~$ sudo add-apt-repository \
> "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
> $(lsb_release -cs) \
> stable"

oldhorse@ubdev:~$ sudo apt-get update

oldhorse@ubdev:~$ sudo apt-get install docker-ce

oldhorse@ubdev:~$ docker run hello-world

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
1. The Docker client contacted the Docker daemon.
2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
3. The Docker daemon created a new container from that image which runs the
executable that produces the output you are currently reading.
4. The Docker daemon streamed that output to the Docker client, which sent it
to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
$ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
https://cloud.docker.com/

For more examples and ideas, visit:
https://docs.docker.com/engine/userguide/

oldhorse@ubdev:~$ sudo systemctl status docker
[sudo] password for oldhorse:
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: e
Active: active (running) since Sat 2017-12-09 05:31:32 PST; 24min ago
Docs: https://docs.docker.com
Main PID: 1509 (dockerd)
Tasks: 20
Memory: 72.8M
CPU: 5.286s
CGroup: /system.slice/docker.service
├─1509 /usr/bin/dockerd -H fd://
└─1681 docker-containerd -l unix:///var/run/docker/libcontainerd/dock

Dec 09 05:31:26 ubdev dockerd[1509]: time="2017-12-09T05:31:26.766627403-08:00"
Dec 09 05:31:26 ubdev dockerd[1509]: time="2017-12-09T05:31:26.769223791-08:00"
Dec 09 05:31:30 ubdev dockerd[1509]: time="2017-12-09T05:31:30.719931202-08:00"
Dec 09 05:31:30 ubdev dockerd[1509]: time="2017-12-09T05:31:30.902468412-08:00"
Dec 09 05:31:32 ubdev dockerd[1509]: time="2017-12-09T05:31:32.219024514-08:00"
Dec 09 05:31:32 ubdev dockerd[1509]: time="2017-12-09T05:31:32.219423982-08:00"
Dec 09 05:31:32 ubdev systemd[1]: Started Docker Application Container Engine.
Dec 09 05:31:32 ubdev dockerd[1509]: time="2017-12-09T05:31:32.583685714-08:00"
Dec 09 05:54:50 ubdev dockerd[1509]: time="2017-12-09T05:54:50.925000145-08:00"
Dec 09 05:54:50 ubdev dockerd[1509]: time="2017-12-09T05:54:50.925618380-08:00"
oldhorse@ubdev:~$

oldhorse@ubdev:~$ docker network ls
NETWORK ID NAME DRIVER SCOPE
5d772a4cf9cc bridge bridge local
962be3fa7945 host host local
c23622125048 none null local