initial implementation
the build was successful Details

This commit is contained in:
Jan Christian Grünhage 2018-01-08 21:57:47 +01:00
parent 23b6b867dc
commit 573050bc4c
Signed by: jcgruenhage
GPG Key ID: 6594C449C633D10C
8 changed files with 54 additions and 49 deletions

2
.dockerignore Normal file
View File

@ -0,0 +1,2 @@
data
.idea

7
.drone.yml Normal file
View File

@ -0,0 +1,7 @@
pipeline:
docker:
image: plugins/docker
repo: docker.jcg.re/coturn
registry: docker.jcg.re
secrets: [ docker_username, docker_password ]
tags: latest

50
.gitignore vendored
View File

@ -1,48 +1,2 @@
# ---> JetBrains
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
# User-specific stuff:
.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/dictionaries
# Sensitive or high-churn files:
.idea/**/dataSources/
.idea/**/dataSources.ids
.idea/**/dataSources.xml
.idea/**/dataSources.local.xml
.idea/**/sqlDataSources.xml
.idea/**/dynamic.xml
.idea/**/uiDesigner.xml
# Gradle:
.idea/**/gradle.xml
.idea/**/libraries
# Mongo Explorer plugin:
.idea/**/mongoSettings.xml
## File-based project format:
*.iws
## Plugin-specific files:
# IntelliJ
/out/
# mpeltonen/sbt-idea plugin
.idea_modules/
# JIRA plugin
atlassian-ide-plugin.xml
# Cursive Clojure plugin
.idea/replstate.xml
# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties
data
.idea

9
Dockerfile Normal file
View File

@ -0,0 +1,9 @@
FROM docker.jcg.re/base-alpine
RUN apk add --no-cache \
coturn \
&& mkdir /data
ADD root /
VOLUME /data

View File

@ -1,2 +1,7 @@
# docker-coturn
## docker.jcg.re/coturn
[![Build Status](https://drone.jcg.re/api/badges/jcgruenhage/docker-coturn/status.svg)](https://drone.jcg.re/jcgruenhage/docker-coturn)
Will probably not be documented any more than this.
You should be able to figure out how to use this if you take a look
at the run file at root/etc/s6.d/coturn/run,
the Dockerfile and [the coturn manpages](https://manpages.debian.org/stretch/coturn/index.html).

11
docker-compose.yml Normal file
View File

@ -0,0 +1,11 @@
version: '2'
services:
coturn:
image: docker.jcg.re/coturn
container_name: coturn
build: .
volumes:
- ./data:/data:z
ports:
- 3478:3478

View File

@ -0,0 +1,2 @@
#!/usr/bin/env sh
s6-svscanctl -t /etc/s6.d

15
root/etc/s6.d/coturn/run Executable file
View File

@ -0,0 +1,15 @@
#!/usr/bin/env sh
# copy default config file, if the config file doesn't exist.
if [ ! -f /data/turnserver.conf ]; then
cp /etc/coturn/turnserver.conf.default /data/turnserver.conf
fi
# chown data
chown -R ${UID}:${GID} /data
# run coturn
su-exec ${UID}:${GID} turnserver \
-c /data/turnserver.conf \
--db /data/user.db \
--prod