From 34793849bb5fd3848840bd6831234a760276b3d5 Mon Sep 17 00:00:00 2001 From: kjuulh Date: Sat, 2 Mar 2024 23:49:28 +0100 Subject: [PATCH] feat: update template Signed-off-by: kjuulh --- cuddle-rust-service/.drone.yml | 61 +++++++++------------------------- 1 file changed, 15 insertions(+), 46 deletions(-) diff --git a/cuddle-rust-service/.drone.yml b/cuddle-rust-service/.drone.yml index 2813783..92152d1 100644 --- a/cuddle-rust-service/.drone.yml +++ b/cuddle-rust-service/.drone.yml @@ -26,20 +26,26 @@ steps: - chmod 700 ~/.ssh/config - name: build pr - image: kasperhermansen/cuddle:latest + image: kasperhermansen/cuddle-rust-service-plan:main-1708174719 pull: always volumes: - name: ssh path: /root/.ssh/ - - name: ci - path: /mnt/ci commands: - eval `ssh-agent` - ssh-add - echo "$DOCKER_PASSWORD" | docker login --password-stdin --username="$DOCKER_USERNAME" docker.io - - apk add git - - $CI_PREFIX pr + - export CLUSTER=clank-dev + - cuddle-infrastructure-plan pr environment: + REGISTRY_CACHE_USERNAME: + from_secret: registry_cache_username + REGISTRY_CACHE_PASSWORD: + from_secret: registry_cache_password + REGISTRY_CACHE_TOKEN: + from_secret: registry_cache_token + REGISTRY_CACHE_url: + from_secret: registry_cache_url DOCKER_BUILDKIT: 1 DOCKER_PASSWORD: from_secret: docker_password @@ -48,7 +54,10 @@ steps: CUDDLE_SECRETS_PROVIDER: 1password CUDDLE_ONE_PASSWORD_DOT_ENV: ".env.ci" CUDDLE_SSH_AGENT: "true" + GIT_PASSWORD: + from_secret: git_password CI_PREFIX: "/mnt/ci/ci" + DOCKER_HOST: "tcp://192.168.1.233:2376" CUDDLE_PLEASE_TOKEN: from_secret: cuddle_please_token OP_SERVICE_ACCOUNT_TOKEN: @@ -63,7 +72,7 @@ steps: - "load_secret" - name: build main - image: kasperhermansen/cuddle-infrastructure-plan:main-1706481826 + image: kasperhermansen/cuddle-rust-service-plan:main-1708174719 pull: always volumes: - name: ssh @@ -73,7 +82,6 @@ steps: - ssh-add - echo "$DOCKER_PASSWORD" | docker login --password-stdin --username="$DOCKER_USERNAME" docker.io - export CLUSTER=clank-prod - - export IMAGE_TAG=something - cuddle-infrastructure-plan main environment: REGISTRY_CACHE_USERNAME: @@ -111,45 +119,6 @@ steps: depends_on: - "load_secret" - - name: deploy release - image: kasperhermansen/cuddle:latest - pull: always - volumes: - - name: ssh - path: /root/.ssh/ - - name: dockersock - path: /var/run - - name: ci - path: /mnt/ci - commands: - - eval `ssh-agent` - - ssh-add - - echo "$DOCKER_PASSWORD" | docker login --password-stdin --username="$DOCKER_USERNAME" docker.io - - apk add git - - cuddle x ci:release - environment: - DOCKER_BUILDKIT: 1 - DOCKER_PASSWORD: - from_secret: docker_password - DOCKER_USERNAME: - from_secret: docker_username - CUDDLE_SECRETS_PROVIDER: 1password - CUDDLE_ONE_PASSWORD_DOT_ENV: ".env.ci" - CUDDLE_SSH_AGENT: "true" - CI_PREFIX: "/mnt/ci/ci" - CUDDLE_PLEASE_TOKEN: - from_secret: cuddle_please_token - OP_SERVICE_ACCOUNT_TOKEN: - from_secret: op_service_account_token - when: - event: - - tag - ref: - include: - - refs/tags/v* - depends_on: - - "load_secret" - volumes: - name: ssh temp: {}