update script to pull latest version
This commit is contained in:
parent
880fe20833
commit
75907e302e
3 changed files with 6 additions and 6 deletions
|
|
@ -1,9 +1,8 @@
|
||||||
FROM alpine:latest
|
FROM alpine:latest
|
||||||
|
|
||||||
ENV VERSION 0.3.5
|
|
||||||
ENV PUID=1000 PGID=1000
|
ENV PUID=1000 PGID=1000
|
||||||
|
|
||||||
RUN apk --update add --no-cache openjdk11-jre
|
RUN apk --update add --no-cache openjdk11-jre grep curl
|
||||||
|
|
||||||
RUN mkdir /app
|
RUN mkdir /app
|
||||||
RUN mkdir /config
|
RUN mkdir /config
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,6 @@
|
||||||
docker container for [JMusicBot](https://github.com/jagrosh/MusicBot)
|
docker container for [JMusicBot](https://github.com/jagrosh/MusicBot)
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
[JMusicBot](https://github.com/jagrosh/MusicBot)
|
|
||||||
|
|
||||||
### Docker
|
### Docker
|
||||||
Usage: `docker run -it -v yourpath/toconfig:/config yojoshb/jmusicbot:latest`
|
Usage: `docker run -it -v yourpath/toconfig:/config yojoshb/jmusicbot:latest`
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,10 @@
|
||||||
|
|
||||||
echo "Starting JMusicBot"
|
echo "Starting JMusicBot"
|
||||||
|
|
||||||
if [ ! -f JMusicBot-${VERSION}.jar ]; then
|
VER=$(curl --silent "https://api.github.com/repos/jagrosh/MusicBot/releases/latest" | grep -Po '"tag_name": "\K.*?(?=")')
|
||||||
wget https://github.com/jagrosh/MusicBot/releases/download/${VERSION}/JMusicBot-${VERSION}.jar
|
|
||||||
|
if [ ! -f JMusicBot-$VER.jar ]; then
|
||||||
|
wget https://github.com/jagrosh/MusicBot/releases/download/$VER/JMusicBot-$VER.jar
|
||||||
fi
|
fi
|
||||||
|
|
||||||
java -Dnogui=true -Dconfig=/config/config.txt -jar JMusicBot-${VERSION}.jar
|
java -Dnogui=true -Dconfig=/config/config.txt -jar JMusicBot-$VER.jar
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue