updating to new file
This commit is contained in:
parent
2893ca1dcb
commit
13a1f6f32a
73
Dockerfile
73
Dockerfile
@ -1,27 +1,46 @@
|
|||||||
FROM phusion/baseimage:latest
|
# Download Ubuntu base image from phusion
|
||||||
|
# https://github.com/phusion/baseimage-docker
|
||||||
WORKDIR /opt/
|
FROM phusion/baseimage:latest
|
||||||
|
|
||||||
#Install Dotnet
|
# Define working directory
|
||||||
RUN sh -c 'echo "deb [arch=amd64] https://apt-mo.trafficmanager.net/repos/dotnet-release/ xenial main" > /etc/apt/sources.list.d/dotnetdev.list' \
|
WORKDIR /opt/
|
||||||
&& apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 417A0893 \
|
|
||||||
&& apt-get update && apt-get install -y dotnet-dev-2.0.0
|
# Prepare for Basic stuff
|
||||||
|
RUN apt-get update
|
||||||
#Add ffmpeg3 ppa
|
RUN apt-get install software-properties-common apt-transport-https curl -y
|
||||||
RUN add-apt-repository ppa:jonathonf/ffmpeg-3
|
|
||||||
|
# Register the trusted Microsoft signature key
|
||||||
#Install required software
|
RUN curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg
|
||||||
RUN apt-get update && apt-get install -y git libopus0 opus-tools libopus-dev libsodium-dev ffmpeg rsync python tzdata
|
RUN mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg
|
||||||
|
|
||||||
#Add youtube-dl
|
# Register the Microsoft Product feed for your distro version
|
||||||
RUN curl -L https://yt-dl.org/downloads/latest/youtube-dl -o /usr/local/bin/youtube-dl && chmod a+rx /usr/local/bin/youtube-dl
|
RUN sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-xenial-prod xenial main" > /etc/apt/sources.list.d/dotnetdev.list'
|
||||||
|
|
||||||
#Download and install stable version of Nadeko
|
# Add ffmpeg3 ppa
|
||||||
RUN curl -O https://raw.githubusercontent.com/mattburchett/nadeko/release/nadeko_installer_1_4.sh && chmod 755 nadeko_installer_1_4.sh && ./nadeko_installer_1_4.sh \
|
RUN add-apt-repository ppa:jonathonf/ffmpeg-3
|
||||||
&& curl -O https://raw.githubusercontent.com/mattburchett/nadeko/release/nadeko_autorestart.sh && chmod 755 nadeko_autorestart.sh
|
|
||||||
|
# Updating existing tools
|
||||||
|
RUN apt-get update && apt-get upgrade -y && apt-get dist-upgrade -y
|
||||||
|
|
||||||
VOLUME ["/root/nadeko"]
|
# Install Git
|
||||||
|
RUN apt-get update && apt-get install -y git
|
||||||
CMD ["sh","/opt/nadeko_autorestart.sh"]
|
|
||||||
|
# Install .Net Core
|
||||||
|
RUN apt-get update && apt-get install -y dotnet-sdk-2.0.0
|
||||||
|
|
||||||
|
# Install Redis-server
|
||||||
|
RUN apt-get update && apt-get install -y redis-server
|
||||||
|
|
||||||
|
# Install required software
|
||||||
|
RUN apt-get update && apt-get install -y libopus0 opus-tools libopus-dev libsodium-dev ffmpeg rsync python python3-pip
|
||||||
|
|
||||||
|
#Add youtube-dl
|
||||||
|
RUN curl -L https://yt-dl.org/downloads/latest/youtube-dl -o /usr/local/bin/youtube-dl && chmod a+rx /usr/local/bin/youtube-dl
|
||||||
|
|
||||||
|
#Download and install stable version of Nadeko
|
||||||
|
RUN curl -H "Cache-Control: no-cache" https://raw.githubusercontent.com/willysunny/Nadecker/master/nadeko_installer_2_5_7.sh -o ./nadeko_installer.sh && chmod 755 nadeko_installer.sh && ./nadeko_installer.sh
|
||||||
|
RUN curl -O -H "Cache-Control: no-cache" https://raw.githubusercontent.com/willysunny/Nadecker/master/nadeko_autorestart.sh && chmod 755 nadeko_autorestart.sh
|
||||||
|
|
||||||
|
VOLUME ["/root/nadeko"]
|
||||||
|
|
||||||
|
CMD ["sh","/opt/nadeko_autorestart.sh"]
|
||||||
|
@ -14,16 +14,18 @@ mv -n /opt/NadekoBot/src/NadekoBot/credentials.json /root/nadeko/credentials.jso
|
|||||||
rm /opt/NadekoBot/src/NadekoBot/credentials.json > /dev/null 2>&1
|
rm /opt/NadekoBot/src/NadekoBot/credentials.json > /dev/null 2>&1
|
||||||
ln -s /root/nadeko/credentials.json /opt/NadekoBot/src/NadekoBot/credentials.json > /dev/null 2>&1
|
ln -s /root/nadeko/credentials.json /opt/NadekoBot/src/NadekoBot/credentials.json > /dev/null 2>&1
|
||||||
|
|
||||||
#echo ""
|
echo ""
|
||||||
#echo "Linking Nadeko Data Folder"
|
echo "Patching Nadeko Data Folder"
|
||||||
#mkdir -p /root/nadeko/data
|
mkdir -p /root/nadeko/patch
|
||||||
#rsync --ignore-existing -rt /opt/NadekoBot/src/NadekoBot/bin/Release/netcoreapp1.1/data/ /root/nadeko/data/
|
cd /root/nadeko/patch && bash "./patch.sh"
|
||||||
#rm -rf /opt/NadekoBot/src/NadekoBot/bin/Release/netcoreapp1.1/data/ > /dev/null 2>&1
|
|
||||||
#ln -s /root/nadeko/data/ /opt/NadekoBot/src/NadekoBot/bin/Release/netcoreapp1.1/data > /dev/null 2>&1
|
echo ""
|
||||||
|
echo "Starting Redis-Server"
|
||||||
|
/usr/bin/redis-server --daemonize yes
|
||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "Running NadekoBot with auto restart Please wait."
|
echo "Running NadekoBot with auto restart Please wait."
|
||||||
cd NadekoBot/src/NadekoBot
|
cd /opt/NadekoBot/src/NadekoBot
|
||||||
while :; do dotnet run -c Release; sleep 5s; done
|
while :; do dotnet run -c Release; sleep 5s; done
|
||||||
echo "Done"
|
echo "Done"
|
||||||
|
|
||||||
|
@ -42,6 +42,7 @@ echo "Download done"
|
|||||||
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "Building NadekoBot"
|
echo "Building NadekoBot"
|
||||||
|
#dotnet add /opt/NadekoBot/src/NadekoBot package ImageSharp --version 1.0.0-alpha9-00194 --source https://www.myget.org/F/imagesharp/api/v3/index.json
|
||||||
dotnet build --configuration Release
|
dotnet build --configuration Release
|
||||||
echo ""
|
echo ""
|
||||||
echo "Building done."
|
echo "Building done."
|
Loading…
Reference in New Issue
Block a user