Docker Codes speichern
# Import Ubuntu image to Docker
docker pull ubuntu:16.04
docker run -it ubuntu:16.04
# Instsall Python3 and pip3
apt-get update
apt-get install -y python3 python3-pip
# Install Selenium
pip3 install selenium
# Install BeautifulSoup4
pip3 install beautifulsoup4
# Install library for PhantomJS
apt-get install -y wget libfontconfig
# Downloading and installing binary
mkdir -p /home/root/src && cd &_
tar jxvf phantomjs-2.1.1-linux-x86_64.tar.bz2
cd phantomjs-2.1.1-linux-x86_64/bin/
cp phantomjs /usr/local/bin/
# Installing font
apt-get install -y fonts-nanum*
Frage
Ich versuche, Ubuntu Bild zu importieren, um Andockfenster und Runde Pakete inscluding python3, PIP3 BS4 und PhantomJS zu installieren. Dann möchte ich alle diese Konfigurationen in Docker als "ubuntu-phantomjs" speichern. Da ich gerade auf dem Ubuntu-Image bin, funktioniert alles, was mit dem Befehl 'docker' beginnt, nicht. Wie kann ich mein Bild speichern? HierWie meine Installationen auf Ubuntu Bild in Docker