# k8s **Repository Path**: codecity/k8s ## Basic Information - **Project Name**: k8s - **Description**: k8s工具仓库 - **Primary Language**: C# - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2019-10-27 - **Last Updated**: 2023-05-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # k8s #### 介绍 k8s工具仓库 #### 使用说明 1. 添加 nuget 包源 https://www.myget.org/F/vxcode/api/v3/index.json 2. 安装 CodeCity.K8S 包 3. 在 Startup 中 调用 services.AddDockerService("服务地址") 4. 使用依赖注入DockerServiceClient 5. 调用相关方法 #### API列表 1. RegisterImage:为用户注册初始镜像 2. DeployImage:为用户部署镜像 ### 运行说明 cd /root/k8s/src/CodeCity.K8S.Service/ git pull #查看并杀死进程 ps -ef | grep dotnet #编译并运行服务,通过之后取消运行,因为要一直运行才行 dotnet run --urls=https://0.0.0.0 #永久运行 nohup dotnet run --urls=https://0.0.0.0 &