Created
November 16, 2016 01:11
-
-
Save DanielRamosAcosta/4cad668e83d44a42723aa6edb929d73b to your computer and use it in GitHub Desktop.
Miencraft server dockerfile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM openjdk:8 | |
| RUN apt-get update | |
| RUN apt-get install -y nginx openssh-server git-core openssh-client curl | |
| RUN apt-get install -y nano | |
| RUN apt-get install -y build-essential | |
| RUN apt-get install -y openssl libreadline6 libreadline6-dev curl zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion pkg-config | |
| RUN command curl -sSL https://rvm.io/mpapis.asc | gpg --import - | |
| RUN \curl -L https://get.rvm.io | bash -s stable | |
| RUN /bin/bash -l -c "rvm requirements" | |
| RUN /bin/bash -l -c "rvm install 2.3" | |
| RUN /bin/bash -l -c "gem install bundler --no-ri --no-rdoc" | |
| RUN /bin/bash -l -c "gem install spigoter" | |
| RUN mkdir SERVER | |
| WORKDIR SERVER | |
| RUN /bin/bash -l -c "spigoter init" | |
| RUN /bin/bash -l -c "spigoter compile" | |
| RUN /bin/bash -l -c "spigoter start" | |
| RUN sed -i 's/false/true/g' eula.txt | |
| EXPOSE 25565 | |
| ENTRYPOINT /bin/bash -l -c "spigoter start" | |
| # Para contruir la imagen: docker build -t minecraft-server | |
| # Para instanciar la máquina: docker run -d -it -p 127.0.0.1:25565:25565 --name parame2 minecraft-server |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment