From 29e30ff3fc733fb64a3faf5a5d90cc923f33c691 Mon Sep 17 00:00:00 2001 From: Gong <534592533@qq.com> Date: Mon, 28 Aug 2023 16:25:01 +0800 Subject: [PATCH] fix: YML --- .drone2.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100755 .drone2.yml diff --git a/.drone2.yml b/.drone2.yml new file mode 100755 index 0000000..821462c --- /dev/null +++ b/.drone2.yml @@ -0,0 +1,34 @@ +kind: pipeline # 定义一个管道 +type: docker # 当前管道的类型 +name: test # 当前管道的名称 +clone: + disable: true #禁用默认克隆 + +steps: # 定义管道的执行步骤 + - name: clone-test + image: alpine/git + commands: + - git clone http://gong.cool:3002/gong/hyperf.git #自定义克隆地址 + - git version + - pwd + - ls -a + - name: build # 步骤名称 + image: gong921123/debian-nginx-php114-74:latest # 当前步骤使用的镜像 image: docker/compose + commands: # 当前步骤执行的命令 + - composer -v + - ls -a + - cd hyperf + #- composer require firebase/php-jwt # 没有composer.json 和 lock文件 + # 如果第一次使用composer 就使用composer require 包名,可以自动创建 vend 和对应的文件 + # 当然这是在本地的时候去创建【本地有了 拉取代码的时候 才能去执行自动拉取】 拉取代码的时候 直接composer install 即可 + + # 本地的endor文件 不需要上传到git上,需要创建一个 .gitignore 文件 把不需要上传git的文件夹,文件按照绝对路径写到这个文件中。 + - composer install -v + - ls -a + - name: deploy-push-images + image: plugins/docker + settings: + repo: gong921123/hyperf # 推送到dockerhub仓库去 + registry: docker.io + insecure: true # 不使用https +