diff --git a/.devops/未命名项目.yml b/.devops/未命名项目.yml new file mode 100644 index 000000000..d069a3510 --- /dev/null +++ b/.devops/未命名项目.yml @@ -0,0 +1,65 @@ +version: 2 +name: 未命名项目 +description: "" +global: + concurrent: 1 +trigger: + webhook: gitlink@1.0.0 + event: + - ref: push + ruleset-operator: AND +workflow: + - ref: start + name: 开始 + task: start + - ref: git_clone_0 + name: git clone + task: git_clone@1.2.9 + input: + username: ((yjh.gitlink_user)) + password: ((yjh.gitlink_pwd)) + remote_url: '"https://gitlink.org.cn/jkcl/reposync.git"' + ref: '"refs/heads/master"' + commit_id: '""' + depth: 1 + needs: + - start + - ref: docker_image_build_0 + name: docker镜像构建 + task: docker_image_build@1.6.0 + input: + docker_username: ((yjh.aliyun_user)) + docker_password: ((yjh.aliyun_pwd)) + image_name: '"crpi-rlxgl92hhxkh8r6q.cn-hangzhou.personal.cr.aliyuncs.com/yuanjiahong/group_07"' + image_tag: '"latest"' + registry_address: '"crpi-rlxgl92hhxkh8r6q.cn-hangzhou.personal.cr.aliyuncs.com"' + docker_file: '"Dockerfile"' + docker_build_path: '"."' + workspace: git_clone_0.git_path + image_push: true + build_args: '""' + needs: + - git_clone_0 + - ref: ssh_cmd_0 + name: ssh执行命令 + task: ssh_cmd@1.1.1 + input: + ssh_pass: ((yjh.ssh_pwd)) + ssh_ip: '"114.55.237.214"' + ssh_port: '"22"' + ssh_user: '"root"' + ssh_cmd: "\"docker stop group_07 || true && docker rm group_07 || true && docker + pull + crpi-rlxgl92hhxkh8r6q.cn-hangzhou.personal.cr.aliyuncs.com/yuanjiahong/\ + group_07:latest; docker run -d -p 8089:8000 --name group_07 -e + BOOT_MODE='app' + crpi-rlxgl92hhxkh8r6q.cn-hangzhou.personal.cr.aliyuncs.com/yuanjiahong/\ + group_07:latest\"" + needs: + - docker_image_build_0 + - ref: end + name: 结束 + task: end + needs: + - ssh_cmd_0 + diff --git a/01af00be-5808-4b90-b4d0-56815560ccff_jpg.rf.cc8348838d232b6c9c92c36c5127533b_2_vertical_flip.jpg b/01af00be-5808-4b90-b4d0-56815560ccff_jpg.rf.cc8348838d232b6c9c92c36c5127533b_2_vertical_flip.jpg new file mode 100644 index 000000000..66ffd171f Binary files /dev/null and b/01af00be-5808-4b90-b4d0-56815560ccff_jpg.rf.cc8348838d232b6c9c92c36c5127533b_2_vertical_flip.jpg differ diff --git a/Dockerfile b/Dockerfile index 24a7ae2bd..f2c1d58ec 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,27 +1,27 @@ FROM centos:7 -RUN yum update -y && \ - yum install -y wget gcc make openssl-devel bzip2-devel libffi-devel zlib-devel +# 配置yum源为阿里云镜像 +RUN mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak && \ + curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo && \ + yum clean all && \ + yum makecache + +RUN yum install -y wget gcc make openssl-devel bzip2-devel libffi-devel zlib-devel RUN wget -P /data/ob-tool https://www.python.org/ftp/python/3.9.6/Python-3.9.6.tgz RUN cd /data/ob-tool && tar xzf Python-3.9.6.tgz RUN cd /data/ob-tool/Python-3.9.6 && ./configure --enable-optimizations && make altinstall ADD ./ /data/ob-robot/ RUN cd /data/ob-robot/ && \ - pip3.9 install -r /data/ob-robot/requirement.txt + pip3.9 install -i https://pypi.tuna.tsinghua.edu.cn/simple -r /data/ob-robot/requirement.txt -RUN yum install -y git openssh-server +# Install OpenSSH and a modern version of Git from the IUS repository. +# This avoids manual compilation, making the build faster and more reliable. +RUN yum install -y openssh-server && \ + yum install -y https://repo.ius.io/ius-release-el7.rpm && \ + yum install -y git236 ENV GIT_SSH_COMMAND='ssh -o StrictHostKeyChecking=no -i /root/.ssh/id_rsa' -RUN yum install -y autoconf gettext && \ - wget http://github.com/git/git/archive/v2.32.0.tar.gz && \ - tar -xvf v2.32.0.tar.gz && \ - rm -f v2.32.0.tar.gz && \ - cd git-* && \ - make configure && \ - ./configure --prefix=/usr && \ - make -j16 && \ - make install WORKDIR /data/ob-robot CMD if [ "$BOOT_MODE" = "app" ] ; then python3.9 main.py; fi