From da1d1170c895dc8ff5c693e1f76b62e28b8371d2 Mon Sep 17 00:00:00 2001 From: Gerardo Marx Date: Sun, 30 Aug 2020 08:47:57 -0500 Subject: [PATCH] redis, cmd and test of isntall --- Dockerfile | 62 ++++++++++++++++++++++++++++++----------- config/install-packages | 6 ++++ docker-compose.yml | 16 +++++++++++ docker/emacs/Dockerfile | 10 +++++++ scientific-emacs | 10 +++++++ 5 files changed, 88 insertions(+), 16 deletions(-) create mode 100644 docker-compose.yml create mode 100644 docker/emacs/Dockerfile create mode 100755 scientific-emacs diff --git a/Dockerfile b/Dockerfile index cbf4274..fb093ed 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,17 +1,53 @@ # Ubuntu bullseye -FROM debian:bullseye +FROM ubuntu:bionic ENV UNAME="scientific-emacs" MAINTAINER gmarxcc LABEL version="0.1" +ENV DEBIAN_FRONTEND=noninteractive # installing emacs RUN apt-get update \ && apt-get -y install emacs # installing texlive base with pdflatex utility: -RUN apt-get update \ - && apt-get -y install \ - texlive-latex-base +RUN apt-get update \ +&& apt-get install -f -y \ +dvipng \ +ghostscript \ +make \ +latex-cjk-all \ +latex-cjk-common \ +latexmk \ +lcdf-typetools \ +lmodern \ +poppler-utils \ +psutils \ +purifyeps \ +t1utils \ +tex-gyre \ +tex4ht \ +texlive-base \ +texlive-bibtex-extra \ +texlive-binaries \ +texlive-extra-utils \ +texlive-font-utils \ +texlive-fonts-extra \ +texlive-fonts-extra-links \ +texlive-fonts-recommended \ +texlive-formats-extra \ +texlive-lang-all \ +texlive-latex-base \ +texlive-latex-extra \ +texlive-latex-recommended \ +texlive-luatex \ +texlive-metapost \ +texlive-pictures \ +texlive-plain-generic \ +texlive-pstricks \ +texlive-publishers \ +texlive-science \ +texlive-xetex \ +texlive-bibtex-extra #installing some usefull apps RUN apt-get update\ @@ -23,20 +59,14 @@ RUN apt-get update\ apt-utils\ aspell\ vim\ - imagemagick - -# oh-my-zshell -RUN sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" + imagemagick\ + perl-tk \ + python3 -# updating texlive +#installing usefull command-line tools RUN apt-get update\ -&& apt-get -y upgrade texlive-base - -# packages installation -#RUN tlmgr init-usertree - -#RUN tlmgr --usermode install collection-latexrecommended\ -# collection-mathscience +&& apt-get -y install \ +csvkit # init ENTRYPOINT ["zsh"] diff --git a/config/install-packages b/config/install-packages index a0df2d7..db885a8 100755 --- a/config/install-packages +++ b/config/install-packages @@ -1,4 +1,6 @@ #!/bin/zsh +tlmgr init-usertree + echo "Installing latex live packages" tlmgr install babel babel-spanis infwarerr \ blindtext IEEEtran amsmath booktabs\ @@ -6,3 +8,7 @@ tlmgr install babel babel-spanis infwarerr \ graphics biblatex algorithmic\ algorithm2e algorithmcx program\ pgf ms xcolor + +echor "Installing oh my zshell" +sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" + diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..c3bdea6 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,16 @@ +version: '3.8' +services: + this_emacs: + container_name: scientific-emacs + build: docker/emacs + volumes: + #- ./config:/home/emacs/.emacs.d + # - ./data:/home + - /tmp/.X11-unix:/tmp/.X11-unix + #- $HOME/.Xauthority:/root/.Xauthority + environment: + DISPLAY: $DISPLAY + tty: true + stdin_open: true + entrypoint: bin/bash +# redis service diff --git a/docker/emacs/Dockerfile b/docker/emacs/Dockerfile new file mode 100644 index 0000000..4bd4907 --- /dev/null +++ b/docker/emacs/Dockerfile @@ -0,0 +1,10 @@ +# Ubuntu +FROM ubuntu:latest +ENV UNAME="scientific-emacs" +MAINTAINER gmarxcc +LABEL version="0.1" + +# installing emacs +RUN apt-get update \ + && apt-get install -y emacs + diff --git a/scientific-emacs b/scientific-emacs new file mode 100755 index 0000000..1ffef11 --- /dev/null +++ b/scientific-emacs @@ -0,0 +1,10 @@ +#!/usr/bin/env zsh +# scriipt to obatin machine's ip and run the docker container +ip=$(ifconfig en0 | grep inet | awk '$1=="inet" {print $2}') +xhost + $ip +echo 'running scientific-emacs:0.1' +docker run --rm -it -v ~/lwc/docker-containers/scientific-emacs/config:/root \ + -v `pwd`:/home\ + -e DISPLAY=$ip:0 \ + -v /tmp/.X11-unix:/tmp/.X11-unix \ + gmarxcc/scientific-emacs:0.1