{"id":21178499,"url":"https://github.com/cyrof/mc-server","last_synced_at":"2025-03-14T18:43:02.250Z","repository":{"id":221377824,"uuid":"754182542","full_name":"Cyrof/mc-server","owner":"Cyrof","description":null,"archived":false,"fork":false,"pushed_at":"2024-03-27T14:56:07.000Z","size":13,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-21T11:45:09.465Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Cyrof.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-07T15:03:26.000Z","updated_at":"2024-03-20T13:42:42.000Z","dependencies_parsed_at":"2024-03-27T16:07:36.377Z","dependency_job_id":"ea372197-f79d-47b1-add9-eff2754afcae","html_url":"https://github.com/Cyrof/mc-server","commit_stats":null,"previous_names":["cyrof/mc-server"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cyrof%2Fmc-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cyrof%2Fmc-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cyrof%2Fmc-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cyrof%2Fmc-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cyrof","download_url":"https://codeload.github.com/Cyrof/mc-server/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243629219,"owners_count":20322014,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-20T17:21:47.699Z","updated_at":"2025-03-14T18:43:02.205Z","avatar_url":"https://github.com/Cyrof.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Minecraft Server with Docker and Backup Script\nThis repository hosts a Minecraft server setup utilizing Docker and Docker Compose, providing flexibility for deployment with or without port forwarding. Additionally, It includes a backup script to automate the process of backing up Minecraft server data.\n\n## Docker Setup\n### Docker Compose Files\n- **docker-compose-ngrok.yaml**: This file sets up the Minecraft server along with an Ngrok container, allowing for for easy access to the server without the need for port forwarding. The Minecraft container is connected to the same Ngrok container, ensuring seamless integration. \u003cbr\u003e\n**IMPORTANT** Change the `\u003cngrok authtoken\u003e` to your own ngrok token\n``` yaml\nenvironment:\n      - NGROK_AUTHTOKEN=\u003cngrok authtoken\u003e\n```\n\n- **docker-compose-pf.yaml**: This file sets up the Minecraft server without Ngrok. Users are required to port forward the default Minecraft port (25565) on their router for external access.\n\n### Usage\nTo start the server, simply run: \n``` bash\n$ docker-compose -f \u003cdocker-compose-file\u003e up -d\n```\nIf you preder using Docker directly for port forwarding, you can use the following command:\n```bash\n$ docker run -d -p 25565:25565 -e EULA=TRUE -v \u003cserver_path\u003e:/data itzg/minecraft-server\n```\n**IMPORTANT** change the \u003cserver_path\u003e to the path of your minecraft server to link to docker container. Please ensure that you have port 25565 forwarded on your router for external access to the server.\n\n### Backup Script\nThe '**mc-backup-script**' folder contains a Python script '**backup.py**', designed to automate the backup process for your Minecraft server data.\n\n### Setup \n1. Navigate into the folder:\n    ```bash\n    $ cd mc-backup-script\n    ```\n2. Create a virtual environment:\n    ```bash\n    $ python3 -m venv \u003cname_of_venv\u003e\n    ``` \n3. Activate the virtual environment:\n    ```bash\n    $ source \u003cname_of_venv\u003e/bin/activate\n    ```\n4. Install the required packgages:\n    ```bash \n    $ pip install -r requirements.txt\n    ```\n5. Create a '**.env**' file in the '**mc-backup-script**' folder.\n6. Add the following variables to the '**.env**' file:\n   ```plaintext\n   SRC=\u003cpath-to-mc-server-folder\u003e\n   DST=\u003cpath-to-backup-folder\u003e\n   ```\n   Replace '**\u003cpath-to-mc-server-folder\u003e**' with the full path to your Minecraft server folder containing the data you want to back up, and '**\u003cpath-to-backup-folder\u003e**' with the full path where you want to store your backups.\n\n### Usage\nSet up cronjob with 5 min interval to run this python script.\n\n## Contributing \nFeel free to contribute to this project by forking this repository and creating a pull request with your changes.\n\n## Issues\nIf you encounter any issues or have suggestions for improvements, please open an issue in the repository.\n\n## License \nThis project is licensed under the [**Apache 2.0 License**](https://github.com/Cyrof/mc-server/blob/main/LICENSE)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyrof%2Fmc-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcyrof%2Fmc-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcyrof%2Fmc-server/lists"}