Skip to content
This repository has been archived by the owner on Mar 21, 2021. It is now read-only.

Commit

Permalink
Initial 'javascript' (xubuntu-vnc-javascript)
Browse files Browse the repository at this point in the history
  • Loading branch information
accetto committed Jun 26, 2019
1 parent 631438b commit 9109523
Show file tree
Hide file tree
Showing 6 changed files with 241 additions and 0 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@

***

### Release 19.06.1-javascript

#### accetto/xubuntu-vnc-javascript

Initial version is new.

### Release 19.06.1-node

#### accetto/xubuntu-vnc-node
Expand Down
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ Contains resources for building [accetto/xubuntu-vnc-chromium][this-docker-xubun

Contains resources for building [accetto/xubuntu-vnc-node][this-docker-xubuntu-vnc-node] images withe the [Node.js][nodejs] JavaScript-based development platform.

#### [xubuntu-vnc-javascript][this-github-xubuntu-vnc-javascript]

Contains resources for building [accetto/xubuntu-vnc-javascript][this-docker-xubuntu-vnc-javascript] images with the [Node.js][nodejs] JavaScript-based development platform, [Visual Studio Code][vscode] developer editor, [TypeScript][typescript] programming language and [LoopBack][loopback] API framework.

#### [utils][this-github-utils]

Contains various utilities that make building the images more convenient.
Expand Down Expand Up @@ -97,6 +101,9 @@ Credit goes to all the countless people and companies, who contribute to open so
[this-github-xubuntu-vnc-node]: https://github.com/accetto/xubuntu-vnc/tree/master/docker/xubuntu-vnc-node/
[this-docker-xubuntu-vnc-node]: https://hub.docker.com/r/accetto/xubuntu-vnc-node/

[this-github-xubuntu-vnc-javascript]: https://github.com/accetto/xubuntu-vnc/tree/master/docker/xubuntu-vnc-javascript/
[this-docker-xubuntu-vnc-javascript]: https://hub.docker.com/r/accetto/xubuntu-vnc-javascript/

[accetto-docker-ubuntu-vnc-xfce]: https://hub.docker.com/r/accetto/ubuntu-vnc-xfce
[accetto-docker-ubuntu-vnc-xfce-firefox-default]: https://hub.docker.com/r/accetto/ubuntu-vnc-xfce-firefox-default
[accetto-docker-ubuntu-vnc-xfce-firefox-plus]: https://hub.docker.com/r/accetto/ubuntu-vnc-xfce-firefox-plus
Expand All @@ -108,7 +115,10 @@ Credit goes to all the countless people and companies, who contribute to open so

[chromium]: https://www.chromium.org/Home
[inkscape]: https://inkscape.org/
[loopback]: https://loopback.io/
[firefox]: https://www.mozilla.org
[nodejs]: https://nodejs.org/en/
[tigervnc]: http://tigervnc.org
[typescript]: https://www.typescriptlang.org/
[vscode]: https://code.visualstudio.com/
[xfce]: http://www.xfce.org
37 changes: 37 additions & 0 deletions docker/xubuntu-vnc-javascript/Dockerfile.javascript
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# docker build -f Dockerfile.javascript -t accetto/xubuntu-vnc-javascript .
# docker build -f Dockerfile.javascript --build-arg BASETAG=lab -t accetto/xubuntu-vnc-javascript:lab .

ARG BASETAG=latest

FROM accetto/xubuntu-vnc-node:${BASETAG} as stage-vscode

USER 0

RUN apt-get update && apt-get install -y \
curl \
&& curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg \
&& install -o root -g root -m 644 microsoft.gpg /etc/apt/trusted.gpg.d/ \
&& sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list' \
&& apt-get install apt-transport-https \
&& apt-get update \
&& apt-get install code \
&& apt-get -y autoremove \
&& rm -rf /var/lib/apt/lists/*

FROM stage-vscode as stage-typescript

RUN npm install -g typescript

FROM stage-typescript as stage-loopback

RUN npm install -g @loopback/cli

EXPOSE 3000

FROM stage-loopback as stage-final

ENV REFRESHED_AT 2019-06-26

WORKDIR /usr/src

USER 1001
37 changes: 37 additions & 0 deletions docker/xubuntu-vnc-javascript/Dockerfile.javascript.chromium
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# docker build -f Dockerfile.javascript.chromium -t accetto/xubuntu-vnc-javascript:chromium .
# docker build -f Dockerfile.javascript.chromium --build-arg BASETAG=lab -t accetto/xubuntu-vnc-javascript:chromium-lab .

ARG BASETAG=chromium

FROM accetto/xubuntu-vnc-node:${BASETAG} as stage-vscode

USER 0

RUN apt-get update && apt-get install -y \
curl \
&& curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg \
&& install -o root -g root -m 644 microsoft.gpg /etc/apt/trusted.gpg.d/ \
&& sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list' \
&& apt-get install apt-transport-https \
&& apt-get update \
&& apt-get install code \
&& apt-get -y autoremove \
&& rm -rf /var/lib/apt/lists/*

FROM stage-vscode as stage-typescript

RUN npm install -g typescript

FROM stage-typescript as stage-loopback

RUN npm install -g @loopback/cli

EXPOSE 3000

FROM stage-loopback as stage-final

ENV REFRESHED_AT 2019-06-26

WORKDIR /usr/src

USER 1001
37 changes: 37 additions & 0 deletions docker/xubuntu-vnc-javascript/Dockerfile.javascript.firefox
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# docker build -f Dockerfile.javascript.firefox -t accetto/xubuntu-vnc-javascript:firefox .
# docker build -f Dockerfile.javascript.firefox --build-arg BASETAG=lab -t accetto/xubuntu-vnc-javascript:firefox-lab .

ARG BASETAG=firefox

FROM accetto/xubuntu-vnc-node:${BASETAG} as stage-vscode

USER 0

RUN apt-get update && apt-get install -y \
curl \
&& curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg \
&& install -o root -g root -m 644 microsoft.gpg /etc/apt/trusted.gpg.d/ \
&& sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/vscode stable main" > /etc/apt/sources.list.d/vscode.list' \
&& apt-get install apt-transport-https \
&& apt-get update \
&& apt-get install code \
&& apt-get -y autoremove \
&& rm -rf /var/lib/apt/lists/*

FROM stage-vscode as stage-typescript

RUN npm install -g typescript

FROM stage-typescript as stage-loopback

RUN npm install -g @loopback/cli

EXPOSE 3000

FROM stage-loopback as stage-final

ENV REFRESHED_AT 2019-06-26

WORKDIR /usr/src

USER 1001
114 changes: 114 additions & 0 deletions docker/xubuntu-vnc-javascript/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
# Headless Ubuntu/Xfce container with VNC for JavaScript development

## accetto/xubuntu-vnc-javascript

[Docker Hub][this-docker] - [Git Hub][this-github] - [Changelog][this-changelog] - [Wiki][this-wiki]

***

This repository contains resources for building Docker images based on [Ubuntu][docker-ubuntu] with [Xfce][xfce] desktop environment, [VNC][tigervnc] server for headless use and JavaScript development platform.

The images are based on the base image [accetto/xubuntu-vnc][accetto-docker-xubuntu-vnc] and inherit all the components and features. Therefore not the whole description will be repeated here.

This image adds the following components:

- [Node.js][nodejs] JavaScript-based development platform
- [npm][npm] package manager for Node.js
- [curl][curl] utility
- [Visual Studio Code][vscode] developer editor

The history of notable changes is documented in the [CHANGELOG][this-changelog].

![container-screenshot][this-screenshot-container]

### Image tags

The following image tags are regularly maintained and rebuilt:

- `latest` is based on `accetto/xubuntu-vnc-node:latest`

[![version badge](https://images.microbadger.com/badges/version/accetto/xubuntu-vnc-javascript:latest.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:latest "Get your own version badge on microbadger.com") [![size badge](https://images.microbadger.com/badges/image/accetto/xubuntu-vnc-javascript:latest.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:latest "Get your own image badge on microbadger.com")

- `firefox` is based on `accetto/xubuntu-vnc-node:firefox` and includes also [Firefox][firefox] web browser

[![version badge](https://images.microbadger.com/badges/version/accetto/xubuntu-vnc-javascript:firefox.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:firefox "Get your own version badge on microbadger.com") [![size badge](https://images.microbadger.com/badges/image/accetto/xubuntu-vnc-javascript:firefox.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:firefox "Get your own image badge on microbadger.com")

- `chromium` is based on `accetto/xubuntu-vnc-node:chromium` and includes also [Chromium][chromium] web browser

[![version badge](https://images.microbadger.com/badges/version/accetto/xubuntu-vnc-javascript:chromium.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:chromium "Get your own version badge on microbadger.com") [![size badge](https://images.microbadger.com/badges/image/accetto/xubuntu-vnc-javascript:chromium.svg)](https://microbadger.com/images/accetto/xubuntu-vnc-javascript:chromium "Get your own image badge on microbadger.com")

### Dockerfiles

The [Git Hub][this-github-xubuntu-vnc-javascript] repository contains several Dockerfiles that can be used to build the images.

- `Dockerfile.javascript`

This is the main Dockerfile for building the `latest` image tag based on the `accetto/xubuntu-vnc-node:latest` tag by default.

However, by providing the `BASETAG` build argument it is possible to build images based on other base tags, for example `accetto/xubuntu-vnc-node:lab`.

- `Dockerfile.javascript.firefox`

This Dockerfile is for building the `firefox` image tag, which is based on the `accetto/xubuntu-vnc-node:firefox` tag and therefore includes also [Firefox][firefox] web browser and the **plus** features

- `Dockerfile.javascript.chromium`

This Dockerfile is for building the `chromium` image tag, which is based on the `accetto/xubuntu-vnc-node:chromium` tag and therefore includes also [Chromium][chromium] web browser

### Ports

The image exposes only the TCP port **5901** and therefore the containers consume only one TCP port (per container) on the host computer.

### Volumes

The containers do not create or use any external volumes by default. However, the following folders make good mounting points: `/home/headless/Documents/`, `/home/headless/Downloads/`, `/home/headless/Pictures/`, `/home/headless/Public/`

Both **named volumes** and **bind mounts** can be used. More about volumes can be found in the [Docker documentation][docker-doc] (e.g. [Manage data in Docker][docker-doc-managing-data]).

### Container user

Containers created from these images run under the default non-root application user **headless** (ID 1001), unless overridden. For more description check the base image [accetto/xubuntu-vnc][accetto-docker-xubuntu-vnc] or [Wiki][this-wiki].

### Using headless containers

The containers are intended to be used through a **VNC Viewer** (e.g. [TigerVNC][tigervnc] or [TightVNC][tightvnc]). The viewer should connect to the host running the container, pointing to its TCP port mapped to the container's port **5901**.

## Issues

If you have found a problem or you just have a question, please check the [Issues][this-issues] and the [Wiki][this-wiki] first. Please do not overlook the closed issues.

If you do not find a solution, you can file a new issue. The better you describe the problem, the bigger the chance it'll be solved soon.

## Credits

Credit goes to all the countless people and companies, who contribute to open source community and make so many dreamy things real.

***

[this-docker]: https://hub.docker.com/r/accetto/xubuntu-vnc-javascript/
[this-github-xubuntu-vnc-javascript]: https://github.com/accetto/xubuntu-vnc/tree/master/docker/xubuntu-vnc-javascript

[this-github]: https://github.com/accetto/xubuntu-vnc/
[this-changelog]: https://github.com/accetto/xubuntu-vnc/blob/master/CHANGELOG.md
[this-wiki]: https://github.com/accetto/xubuntu-vnc/wiki

[this-issues]: https://github.com/accetto/xubuntu-vnc/issues

[this-screenshot-container]: https://raw.githubusercontent.com/accetto/xubuntu-vnc/master/docker/xubuntu-vnc-javascript/xubuntu-vnc-javascript.jpg

[accetto-docker-xubuntu-vnc]: https://hub.docker.com/r/accetto/xubuntu-vnc/

[docker-doc]: https://docs.docker.com/
[docker-doc-managing-data]: https://docs.docker.com/storage/

[docker-ubuntu]: https://hub.docker.com/_/ubuntu/
[tigervnc]: http://tigervnc.org
[tightvnc]: http://www.tightvnc.com
[xfce]: http://www.xfce.org

[chromium]: https://www.chromium.org/Home
[curl]: http://manpages.ubuntu.com/manpages/bionic/man1/curl.1.html
[firefox]: https://www.mozilla.org
[nodejs]: https://nodejs.org/en/
[npm]: https://www.npmjs.com/
[vscode]: https://code.visualstudio.com/

0 comments on commit 9109523

Please sign in to comment.