Var & Init files

This commit is contained in:
chbmb 2019-05-18 00:16:30 +01:00
parent 60c73e7a90
commit e8b4092f7d
5 changed files with 63 additions and 22 deletions

28
jenkins-vars.yml Normal file
View File

@ -0,0 +1,28 @@
---
# jenkins variables
project_name: docker-mstream
external_type: github_stable
release_type: stable
release_tag: latest
ls_branch: master
repo_vars:
- EXT_GIT_BRANCH = 'master'
- EXT_USER = 'IrosTheBeggar'
- EXT_REPO = 'mStream'
- BUILD_VERSION_ARG = 'MSTREAM_RELEASE'
- LS_USER = 'linuxserver'
- LS_REPO = 'docker-mstream'
- CONTAINER_NAME = 'mstream'
- DOCKERHUB_IMAGE = 'linuxserver/mstream'
- DEV_DOCKERHUB_IMAGE = 'lsiodev/mstream'
- PR_DOCKERHUB_IMAGE = 'lspipepr/mstream'
- DIST_IMAGE = 'alpine'
- MULTIARCH='true'
- CI='true'
- CI_WEB='true'
- CI_PORT='3000'
- CI_SSL='false'
- CI_DELAY='120'
- CI_DOCKERENV='TZ=US/Pacific'
- CI_AUTH='user:password'
- CI_WEBPATH=''

View File

@ -1,8 +1,8 @@
project_name: mstream
project_url: "https://github.com/IrosTheBeggar/mStream"
project_name: mStream
project_url: "https://mstream.io/"
project_logo: "https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/mstream.png"
project_blurb: |
[{{ project_name|capitalize }}]({{ project_url }}) is a personal music streaming server. You can use mStream to stream your music from your home computer to any device, anywhere.
[{{ project_name }}]({{ project_url }}) is a personal music streaming server. You can use mStream to stream your music from your home computer to any device, anywhere.
project_lsio_github_repo_url: "https://github.com/linuxserver/docker-{{ project_name }}"
# supported architectures
@ -22,13 +22,15 @@ param_ports:
- { external_port: "3000", internal_port: "3000", port_desc: "The port for the mStream webinterface" }
param_usage_include_env: true
param_env_vars:
- { env_var: "USER", env_value: "admin", desc: "Set username to login" }
- { env_var: "PASSWORD", env_value: "password", desc: "Set password for user" }
- { env_var: "USE_JSON", env_value: "true/false", desc: "Run mStream using the config specified at `/config/config.json`, note this will mean user/password is defined in `config.json`" }
- { env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use e.g. Europe/London" }
# application setup block
app_setup_block_enabled: true
app_setup_block: |
Access the webui at `http://<your-ip>:3000`, for more information check out [{{ project_name|capitalize }}]({{ project_url }}).
Access the webui at `http://<your-ip>:3000`, For most users specifying a USER and PASSWORD is sufficient, the `USE_JSON` option allows for more granular control of mStream, but with added complexity, requiring manual editing of `config.json` to configure your install, for more information check out [{{ project_name|capitalize }}](https://github.com/IrosTheBeggar/mStream/blob/master/docs/json_config.md#json-config).
# changelog
changelogs:
- { date: "28.09.16:", desc: "Inital Release" }
- { date: "18.05.19:", desc: "Inital Release" }

View File

@ -1,11 +1,10 @@
{
"port": 3000,
"webAppDirectory": "public",
"secret": "",
"writeLogs": true,
"noUpload": false,
"writeLogs": false,
"noUpload": true,
"scanOptions": {
"skipImg": true,
"skipImg": false,
"scanInterval": 1.5,
"pause": 50,
"saveInterval": 500,
@ -13,16 +12,17 @@
},
"storage": {
"albumArtDirectory": "/config/album-art",
"dbDirectory": "/config",
"logsDirectory": "/config/logs"
"dbDirectory": "/config/db"
},
"folders": {
"music": "/music"
"library": "/music"
},
"users": {
"admin": {
"password":"password",
"vpaths": "music"
}
"vpaths": "library",
"lastfm-user": "username",
"lastfm-password": "password"
}
}
}
}

View File

@ -1,9 +1,15 @@
#!/usr/bin/with-contenv bash
# make folders
mkdir -p \
/config/album_art \
/config/db
# make folders if don't exist
[[ ! -d /config/album-art ]] && \
mkdir -p /config/album-art
[[ ! - d /config/db ]] && \
mkdir -p /config/db
# copy config.json if doesn't exist
[[ ! -e /config/config.json ]] && \
cp /defaults/config.json /config/config.json
# permissions
chown abc:abc -R \

View File

@ -2,5 +2,10 @@
cd /opt/mstream || exit
exec \
s6-setuidgid abc mstream -j /config/config.json
if [ "$USE_JSON" == "true" ]; then
exec \
s6-setuidgid abc mstream -j /config/config.json
else
exec \
s6-setuidgid abc mstream -m /music -I /config/album-art/ -d /config/db/ -u ${USER} -x ${PASSWORD}
fi