generated from OPDMC/Template-MCServer
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
391 changed files
with
25,621 additions
and
207 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
Dockerfile linguist-detectable=true | ||
§§template§§*.mcfunction linguist-language=dockerfile | ||
*.html linguist-detectable=false |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# pip install pyunpack patool | ||
|
||
import sys | ||
import os | ||
import patoolib | ||
|
||
def is_multi_part_zip(file_path): | ||
z01_file = file_path[:-4] + ".z01" # Replace the last .zip with .z01 | ||
return os.path.exists(z01_file) | ||
|
||
def delete_original_files(file_path): | ||
base_name = file_path[:-4] | ||
files_to_delete = [file_path] + [base_name + ext for ext in ['.zip', '.z01', '.z02', '.z03', '.z04', '.z05', '.z06', '.z07', '.z08', '.z09']] | ||
for file in files_to_delete: | ||
if os.path.exists(file): | ||
os.remove(file) | ||
print(f"Deleted: {file}") | ||
|
||
def unzip_files(directory): | ||
for root, dirs, files in os.walk(directory): | ||
for file in files: | ||
file_path = os.path.join(root, file) | ||
if (file.endswith('.jar.zip') or file.endswith('.zip.zip')) and is_multi_part_zip(file_path): | ||
print(f"Processing file: {file_path}") | ||
try: | ||
patoolib.extract_archive(file_path, outdir=root) | ||
print(f"Unzipped: {file_path}") | ||
# Delete original files after successful extraction | ||
delete_original_files(file_path) | ||
except Exception as e: | ||
print(f"Error unzipping {file_path}: {e}") | ||
|
||
def main(): | ||
if len(sys.argv) != 2: | ||
print("Usage: ClientPkgReformat.py <DIRECTORY>") | ||
sys.exit(1) | ||
|
||
directory = sys.argv[1] | ||
|
||
if not os.path.isdir(directory): | ||
print(f"Error: {directory} is not a valid directory.") | ||
sys.exit(1) | ||
|
||
unzip_files(directory) | ||
|
||
if __name__ == "__main__": | ||
main() | ||
|
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
docker_test_server*/ | ||
docker_test_server*/ | ||
minecraft_client_versionpack/mods/Pixelmon-1.16.5-9.1.11-universal.jar |
File renamed without changes.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,82 +1,38 @@ | ||
§§template§§§§template§§§§template§§ | ||
|
||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.1?arch=amd64&label=AMD64%20v2.1&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.1?arch=arm64&label=ARM64%20v2.1&color=008866) | ||
|
||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.0?arch=amd64&label=AMD64%20v2.0&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.0?arch=arm64&label=ARM64%20v2.0&color=008866) | ||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/1.16.5-opdmodpixelmon/v1.0?arch=amd64&label=AMD64%20v1.0&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/1.16.5-opdmodpixelmon/v1.0?arch=arm64&label=ARM64%20v1.0&color=008866) | ||
|
||
--- | ||
|
||
# [Template-MCServer v2.1](https://github.com/OPDMC/Template-MCServer/releases/tag/v2.1) | ||
# [1.16.5-OPDModPixelmon v1.0](https://github.com/OPDMC/1.16.5-OPDModPixelmon/releases/tag/v1.0) | ||
|
||
> [!IMPORTANT] | ||
> | ||
> This project is merely a Docker packaging of a server created by others. The server and client modpack's author is the PixelmonMod team. Please respect the original author's copyright. | ||
> | ||
> By using this project, you acknowledge and agree that the [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) is automatically set to TRUE. | ||
> | ||
> 使用本项目即表示您承认并同意 [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) 已自动设置为 TRUE。 | ||
> | ||
> 此项目仅为对他人制作的服务器的 Docker 打包。此服务器和客户端模组包的作者是 PixelmonMod 团队。请尊重原作者版权。 | ||
<a href='https://hub.docker.com/r/opdmc/template-mcserver'><img src="https://img.shields.io/badge/-DockerHub-1c90ed?style=flat&logo=Docker&logoColor=white" referrerpolicy="no-referrer" alt="DockerHub"></a> <a href='https://github.com/OPDMC/Template-MCServer/pkgs/container/template-mcserver'><img src="https://img.shields.io/badge/-Ghcr.io-8957E5?style=flat&logo=GitHub&logoColor=white" referrerpolicy="no-referrer" alt="Ghcr.io"></a> | ||
<a href='https://hub.docker.com/r/opdmc/1.16.5-opdmodpixelmon'><img src="https://img.shields.io/badge/-DockerHub-1c90ed?style=flat&logo=Docker&logoColor=white" referrerpolicy="no-referrer" alt="DockerHub"></a> <a href='https://github.com/OPDMC/1.16.5-OPDModPixelmon/pkgs/container/1.16.5-opdmodpixelmon'><img src="https://img.shields.io/badge/-Ghcr.io-8957E5?style=flat&logo=GitHub&logoColor=white" referrerpolicy="no-referrer" alt="Ghcr.io"></a> | ||
|
||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.1?arch=amd64&label=AMD64%20v2.1&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.1?arch=arm64&label=ARM64%20v2.1&color=008866) | ||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/1.16.5-opdmodpixelmon/v1.0?arch=amd64&label=AMD64%20v1.0&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/1.16.5-opdmodpixelmon/v1.0?arch=arm64&label=ARM64%20v1.0&color=008866) | ||
|
||
### Usage | ||
|
||
```shell | ||
# DockerHub | ||
docker pull opdmc/template-mcserver:v2.1 | ||
docker pull opdmc/1.16.5-opdmodpixelmon:v1.0 | ||
# Ghcr.io | ||
docker pull ghcr.io/opdmc/template-mcserver:v2.1 | ||
docker pull ghcr.io/opdmc/1.16.5-opdmodpixelmon:v1.0 | ||
``` | ||
|
||
```shell | ||
docker run -d \ | ||
--name=1.19.4-opdmc \ | ||
--name=1.16.5-opdmodpixelmon \ | ||
-p 127.0.0.1:80:25565/tcp \ | ||
-v /path/to/store/data:/minecraft \ | ||
opdmc/1.19.4-opdmodcarpet:latest | ||
opdmc/1.16.5-opdmodpixelmon | ||
``` | ||
|
||
### Changelog | ||
|
||
**Full Changelog**: https://github.com/OPDMC/Template-MCServer/compare/v2.0...v2.1 | ||
|
||
# [Template-MCServer v2.0](https://github.com/OPDMC/Template-MCServer/releases/tag/v2.0) | ||
|
||
> [!IMPORTANT] | ||
> By using this project, you acknowledge and agree that the [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) is automatically set to TRUE. | ||
> | ||
> 使用本项目即表示您承认并同意 [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) 已自动设置为 TRUE。 | ||
<a href='https://hub.docker.com/r/opdmc/template-mcserver'><img src="https://img.shields.io/badge/-DockerHub-1c90ed?style=flat&logo=Docker&logoColor=white" referrerpolicy="no-referrer" alt="DockerHub"></a> <a href='https://github.com/OPDMC/Template-MCServer/pkgs/container/template-mcserver'><img src="https://img.shields.io/badge/-Ghcr.io-8957E5?style=flat&logo=GitHub&logoColor=white" referrerpolicy="no-referrer" alt="Ghcr.io"></a> | ||
|
||
![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.0?arch=amd64&label=AMD64%20v2.0&color=006688) ![Docker Image Size (tag)](https://img.shields.io/docker/image-size/opdmc/template-mcserver/v2.0?arch=arm64&label=ARM64%20v2.0&color=008866) | ||
|
||
### Usage | ||
|
||
```shell | ||
# DockerHub | ||
docker pull opdmc/template-mcserver:v2.0 | ||
# Ghcr.io | ||
docker pull ghcr.io/opdmc/template-mcserver:v2.0 | ||
``` | ||
|
||
```shell | ||
docker run -d \ | ||
--name=1.19.4-opdmc \ | ||
-p 127.0.0.1:80:25565/tcp \ | ||
-v /path/to/store/data:/minecraft \ | ||
opdmc/1.19.4-opdmodcarpet:latest | ||
``` | ||
|
||
### Changelog | ||
|
||
**Full Changelog**: https://github.com/OPDMC/Template-MCServer/compare/v1.0...v2.0 | ||
|
||
# [Template-MCServer v1.0](https://github.com/OPDMC/Template-MCServer/releases/tag/v1.0) | ||
|
||
> [!IMPORTANT] | ||
> By using this project, you acknowledge and agree that the [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) is automatically set to TRUE. | ||
> | ||
> 使用本项目即表示您承认并同意 [Minecraft EULA](https://account.mojang.com/documents/minecraft_eula) 已自动设置为 TRUE。 | ||
### Changelog | ||
|
||
**Full Changelog**: https://github.com/OPDMC/Template-MCServer/commits/v1.0 | ||
**Full Changelog**: https://github.com/OPDMC/1.16.5-OPDModPixelmon/commits/v1.0 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,15 @@ | ||
# §§template§§ | ||
FROM openjdk:17-slim-bullseye | ||
# §§template§§ | ||
FROM openjdk:11-slim-bullseye | ||
RUN apt-get update && apt-get install -y dos2unix | ||
ENV EULA=TRUE | ||
WORKDIR /minecraft | ||
COPY ./minecraft_server /docker_init | ||
COPY docker-init.sh ../init.sh | ||
RUN dos2unix ../init.sh && chmod +x ../init.sh | ||
RUN dos2unix /docker_init/Install.sh && chmod +x /docker_init/Install.sh | ||
RUN dos2unix /docker_init/settings.sh && chmod +x /docker_init/settings.sh | ||
RUN dos2unix /docker_init/start.sh && chmod +x /docker_init/start.sh | ||
WORKDIR /docker_init | ||
RUN ./Install.sh | ||
WORKDIR /minecraft | ||
EXPOSE 25565 | ||
ENTRYPOINT [ "sh", "../init.sh" ] |
Oops, something went wrong.