Skip to content

Commit

Permalink
Merge pull request #7 from aptalca/code-server-nodejs
Browse files Browse the repository at this point in the history
code-server: nodejs initial release
  • Loading branch information
thelamer committed Feb 6, 2020
2 parents ca2c0ce + 6499749 commit d1454d2
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 67 deletions.
8 changes: 4 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ language: shell

branches:
only:
- <baseimagename>-<modname> #replace variables, omit brackets
- code-server-nodejs

services:
- docker

env:
global:
- DOCKERHUB="linuxserver/mods" #don't modify
- BASEIMAGE="baseimagename" #replace
- MODNAME="modname" #replace
- DOCKERHUB="linuxserver/mods"
- BASEIMAGE="code-server"
- MODNAME="nodejs"

jobs:
include:
Expand Down
2 changes: 2 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM scratch

LABEL maintainer="aptalca"

# copy local files
COPY root/ /
21 changes: 0 additions & 21 deletions Dockerfile.complex

This file was deleted.

16 changes: 4 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
# Docker mod for openssh-server
# Nodejs - Docker mod for code-server

This mod adds rsync to openssh-server, to be installed/updated during container start.
This mod adds a nodejs dev environment to code-server, to be installed/updated during container start.

In openssh-server docker arguments, set an environment variable `DOCKER_MODS=linuxserver/mods:openssh-server-rsync`
In code-server docker arguments, set an environment variable `DOCKER_MODS=linuxserver/mods:code-server-nodejs`

# Mod creation instructions

* Ask the team to create a new branch named `<baseimagename>-<modname>`. Baseimage should be the name of the image the mod will be applied to. The new branch will be based on the `template` branch.
* Fork the repo, checkout the template branch.
* Edit the `Dockerfile` for the mod. `Dockerfile.complex` is only an example and included for reference; it should be deleted when done.
* Inspect the `root` folder contents. Edit, add and remove as necessary.
* Edit this readme with pertinent info, delete thse instructions.
* Finally edit the `travis.yml`. Customize the build branch,and the vars for `BASEIMAGE` and `MODNAME`
* Submit PR against the branch created by the team
If adding multiple mods, enter them in an array separated by `|`, such as `DOCKER_MODS=linuxserver/mods:code-server-nodejs|linuxserver/mods:code-server-mod2`
14 changes: 14 additions & 0 deletions root/etc/cont-init.d/99-nodejs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/with-contenv bash

echo "**** installing nodejs dev environment ****"
[[ ! -f "/etc/apt/sources.list.d/nodesource.list" ]] && \
curl -s https://deb.nodesource.com/gpgkey/nodesource.gpg.key | apt-key add - && \
echo 'deb https://deb.nodesource.com/node_12.x bionic main' \
> /etc/apt/sources.list.d/nodesource.list
[[ ! -f "/etc/apt/sources.list.d/yarn.list" ]] && \
curl -s https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo 'deb https://dl.yarnpkg.com/debian/ stable main' \
> /etc/apt/sources.list.d/yarn.list
apt-get update && apt-get install -y \
nodejs \
yarn
27 changes: 0 additions & 27 deletions root/etc/cont-init.d/99-vpn-config

This file was deleted.

3 changes: 0 additions & 3 deletions root/etc/services.d/sshvpn/run

This file was deleted.

0 comments on commit d1454d2

Please sign in to comment.