├── .cims-conf └── .gitignore ├── .gitattributes ├── .github └── workflows │ └── nuitka.yml ├── .gitignore ├── .idea ├── .gitignore ├── ClassIslandManagementServer.py.iml ├── dictionaries │ ├── 34876.xml │ └── project.xml ├── inspectionProfiles │ ├── Project_Default.xml │ └── profiles_settings.xml ├── jsLibraryMappings.xml ├── misc.xml ├── modules.xml ├── runConfigurations │ ├── .xml │ ├── 2.xml │ ├── 3.xml │ ├── 4.xml │ └── _CIMS_py.xml └── vcs.xml ├── .spacecompiler ├── APIDocument.md ├── BuildInClasses.py ├── CIMS.py ├── CIMS.spacescript ├── Datas ├── .gitignore ├── ClassPlan │ └── default.json ├── DefaultSettings │ └── default.json ├── Policy │ └── default.json ├── Subjects │ └── default.json ├── TimeLayout │ └── default.json ├── __init__.py ├── client_status.json ├── clients.json ├── pre_register.json └── profile_config.json ├── LICENSE ├── ManagementServer.vercel ├── __init__.py ├── api.py ├── command.py └── gRPC.py ├── ManagementServer ├── __init__.py ├── api.py ├── command.py └── gRPC.py ├── Protobuf ├── .gitignore ├── Client │ ├── ClientCommandDeliverScReq.proto │ ├── ClientRegisterCsReq.proto │ └── __init__.py ├── Command │ ├── HeartBeat.proto │ ├── SendNotification.proto │ └── __init__.py ├── Enum │ ├── CommandTypes.proto │ ├── Retcode.proto │ └── __init__.py ├── Server │ ├── ClientCommandDeliverScRsp.proto │ ├── ClientRegisterScRsp.proto │ └── __init__.py ├── Service │ ├── ClientCommandDeliver.proto │ ├── ClientRegister.proto │ └── __init__.py └── __init__.py ├── QuickValues.py ├── README.md ├── Shell.py ├── abstract.py ├── change-visble.txt ├── changelog.txt ├── i18n └── __init__.py ├── install.sh ├── logger └── __init__.py ├── logs └── .gitignore ├── nuitka-build.bat ├── nuitka-ubuntu.sh ├── project.json ├── project_info.json ├── requirements.txt ├── updater.py └── vercel.json /.cims-conf/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MINIOpenSource/CIMS-backend/08d343ee57f584db887bf8c00fa94fde7c949ddc/.cims-conf/.gitignore -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.github/workflows/nuitka.yml: -------------------------------------------------------------------------------- 1 | name: 构建二进制文件 2 | on: 3 | push: 4 | branches: 5 | - main 6 | pull_request: 7 | branches: 8 | - main 9 | workflow_dispatch: 10 | 11 | jobs: 12 | builder_matrix: 13 | strategy: 14 | fail-fast: false 15 | matrix: 16 | os: [ ubuntu-latest, windows-latest] 17 | runs-on: ${{ matrix.os }} 18 | steps: 19 | - name: Checkout repository 20 | uses: actions/checkout@v4.2.2 21 | - name: Setup Python 22 | uses: actions/setup-python@v5.3.0 23 | with: 24 | python-version: '3.13' 25 | cache: 'pip' 26 | cache-dependency-path: | 27 | **/requirements*.txt 28 | - name: Setup toolkits 29 | run: pip install grpcio-tools 30 | - name: Build protobuf (Windows) 31 | if: ${{ startsWith(matrix.os, 'windows') }} 32 | run: | 33 | $protoFiles = Get-ChildItem Protobuf -Recurse -Filter *.proto -File ` 34 | | ForEach-Object { $_.FullName } 35 | python -m grpc_tools.protoc --proto_path=D:\a\CIMS-backend\CIMS-backend\ --python_out=. --grpc_python_out=. $protoFiles 36 | - name: Build protobuf (Linux) 37 | if: ${{ startsWith(matrix.os, 'ubuntu') }} 38 | run: | 39 | find Protobuf/ -type f -name "*.proto" \ 40 | | xargs python -m grpc_tools.protoc --proto_path=. --python_out=. --grpc_python_out=. 41 | - name: Install Linux-specific Dependencies 42 | if: ${{ startsWith(matrix.os, 'ubuntu') }} 43 | run: | 44 | sudo apt-get update 45 | sudo apt-get install -y mold clang 46 | 47 | - name: Install Dependencies 48 | run: pip install -r requirements.txt 49 | 50 | - name: Build (Windows) 51 | if: ${{ startsWith(matrix.os, 'windows') }} 52 | uses: Nuitka/Nuitka-Action@main 53 | with: 54 | mode: standalone 55 | script-name: CIMS.py 56 | output-file: CIMS-backend 57 | include-data-files: LICENSE=LICENSE 58 | disable-console: false 59 | file-version: 1.0.0.0 60 | product-name: CIMS-backend 61 | - name: Build (Linux) 62 | if: ${{ startsWith(matrix.os, 'ubuntu') }} 63 | uses: Nuitka/Nuitka-Action@main 64 | env: 65 | CC: clang 66 | CXX: clang++ 67 | LDFLAGS: "-fuse-ld=mold" 68 | with: 69 | mode: standalone 70 | script-name: CIMS.py 71 | output-file: CIMS-backend 72 | 73 | - name: Upload unsigned application 74 | uses: actions/upload-artifact@v4.4.2 75 | with: 76 | name: ${{ matrix.os }} 77 | path: build/CIMS.dist 78 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Byte-compiled / optimized / DLL files 2 | __pycache__/ 3 | *$py.class 4 | 5 | # C extensions 6 | *.so 7 | 8 | # Distribution / packaging 9 | .Python 10 | build/ 11 | develop-eggs/ 12 | dist/ 13 | downloads/ 14 | eggs/ 15 | .eggs/ 16 | lib/ 17 | lib64/ 18 | parts/ 19 | sdist/ 20 | var/ 21 | wheels/ 22 | share/python-wheels/ 23 | *.egg-info/ 24 | .installed.cfg 25 | *.egg 26 | MANIFEST 27 | 28 | # PyInstaller 29 | # Usually these files are written by a python script from a template 30 | # before PyInstaller builds the exe, so as to inject date/other infos into it. 31 | *.manifest 32 | *.spec 33 | 34 | # Installer logs 35 | pip-log.txt 36 | pip-delete-this-directory.txt 37 | 38 | # Unit test / coverage reports 39 | htmlcov/ 40 | .tox/ 41 | .nox/ 42 | .coverage 43 | .coverage.* 44 | .cache 45 | nosetests.xml 46 | coverage.xml 47 | *.cover 48 | *.py,cover 49 | .hypothesis/ 50 | .pytest_cache/ 51 | cover/ 52 | 53 | # Translations 54 | *.mo 55 | *.pot 56 | 57 | # Django stuff: 58 | *.log 59 | local_settings.py 60 | db.sqlite3 61 | db.sqlite3-journal 62 | 63 | # Flask stuff: 64 | instance/ 65 | .webassets-cache 66 | 67 | # Scrapy stuff: 68 | .scrapy 69 | 70 | # Sphinx documentation 71 | docs/_build/ 72 | 73 | # PyBuilder 74 | .pybuilder/ 75 | target/ 76 | 77 | # Jupyter Notebook 78 | .ipynb_checkpoints 79 | 80 | # IPython 81 | profile_default/ 82 | ipython_config.py 83 | 84 | # pyenv 85 | # For a library or package, you might want to ignore these files since the code is 86 | # intended to run in multiple environments; otherwise, check them in: 87 | .python-version 88 | 89 | # pipenv 90 | # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. 91 | # However, in case of collaboration, if having platform-specific dependencies or dependencies 92 | # having no cross-platform support, pipenv may install dependencies that don't work, or not 93 | # install all needed dependencies. 94 | #Pipfile.lock 95 | 96 | # poetry 97 | # Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control. 98 | # This is especially recommended for binary packages to ensure reproducibility, and is more 99 | # commonly ignored for libraries. 100 | # https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control 101 | #poetry.lock 102 | 103 | # pdm 104 | # Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control. 105 | #pdm.lock 106 | # pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it 107 | # in version control. 108 | # https://pdm.fming.dev/latest/usage/project/#working-with-version-control 109 | .pdm.toml 110 | .pdm-python 111 | .pdm-build/ 112 | 113 | # PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm 114 | __pypackages__/ 115 | 116 | # Celery stuff 117 | celerybeat-schedule 118 | celerybeat.pid 119 | 120 | # SageMath parsed files 121 | *.sage.py 122 | 123 | # Environments 124 | .env 125 | .venv 126 | env/ 127 | venv/ 128 | ENV/ 129 | env.bak/ 130 | venv.bak/ 131 | 132 | # Spyder project settings 133 | .spyderproject 134 | .spyproject 135 | 136 | # Rope project settings 137 | .ropeproject 138 | 139 | # mkdocs documentation 140 | /site 141 | 142 | # mypy 143 | .mypy_cache/ 144 | .dmypy.json 145 | dmypy.json 146 | 147 | # Pyre type checker 148 | .pyre/ 149 | 150 | # pytype static type analyzer 151 | .pytype/ 152 | 153 | # Cython debug symbols 154 | cython_debug/ 155 | 156 | # Visual Studio 157 | .vs/ 158 | *.pyproj 159 | *.sln 160 | 161 | # Github Release 162 | release/ 163 | 164 | # Generated Resources 165 | .installed 166 | ManagementPreset.json 167 | ManagementPreset.json.bak 168 | settings.json 169 | 170 | # Protocol Buffer 171 | Protobuf/ 172 | 173 | # PyCharm 174 | # JetBrains specific template is maintained in a separate JetBrains.gitignore that can 175 | # be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore 176 | # and can be added to the global gitignore or merged into this file. For a more nuclear 177 | # option (not recommended) you can uncomment the following to ignore the entire idea folder. 178 | #.idea/ 179 | -------------------------------------------------------------------------------- /.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # 默认忽略的文件 2 | /shelf/ 3 | /workspace.xml 4 | # 基于编辑器的 HTTP 客户端请求 5 | /httpRequests/ 6 | # Datasource local storage ignored files 7 | /dataSources/ 8 | /dataSources.local.xml 9 | -------------------------------------------------------------------------------- /.idea/ClassIslandManagementServer.py.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 15 | -------------------------------------------------------------------------------- /.idea/dictionaries/34876.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | retcode 5 | 6 | 7 | -------------------------------------------------------------------------------- /.idea/dictionaries/project.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | cims 5 | classisland 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/inspectionProfiles/Project_Default.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 12 | -------------------------------------------------------------------------------- /.idea/inspectionProfiles/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | -------------------------------------------------------------------------------- /.idea/jsLibraryMappings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/runConfigurations/.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 |