This commit is contained in:
+6
-12
@@ -4,16 +4,13 @@ name: pr-check
|
|||||||
trigger:
|
trigger:
|
||||||
event:
|
event:
|
||||||
- pull_request
|
- pull_request
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: build-angular
|
- name: build-angular
|
||||||
image: node:22-alpine
|
image: node:22-alpine
|
||||||
commands:
|
commands:
|
||||||
- npm ci
|
- npm ci
|
||||||
- npm run build
|
- npm run build
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
kind: pipeline
|
kind: pipeline
|
||||||
type: kubernetes
|
type: kubernetes
|
||||||
name: deploy
|
name: deploy
|
||||||
@@ -22,14 +19,12 @@ trigger:
|
|||||||
- main
|
- main
|
||||||
event:
|
event:
|
||||||
- push
|
- push
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: build-angular
|
- name: build-angular
|
||||||
image: node:22-alpine
|
image: node:22-alpine
|
||||||
commands:
|
commands:
|
||||||
- npm ci
|
- npm ci
|
||||||
- npm run build
|
- npm run build
|
||||||
|
|
||||||
- name: build-and-push
|
- name: build-and-push
|
||||||
image: plugins/docker
|
image: plugins/docker
|
||||||
settings:
|
settings:
|
||||||
@@ -41,18 +36,17 @@ steps:
|
|||||||
from_secret: gitea_username
|
from_secret: gitea_username
|
||||||
password:
|
password:
|
||||||
from_secret: gitea_password
|
from_secret: gitea_password
|
||||||
|
|
||||||
- name: update-manifest
|
- name: update-manifest
|
||||||
image: alpine/git
|
image: alpine/git
|
||||||
environment:
|
|
||||||
GITEA_TOKEN:
|
|
||||||
from_secret: gitea_token
|
|
||||||
commands:
|
commands:
|
||||||
- git clone https://mnky:$GITEA_TOKEN@gitea.mnky-code.de/mnky/k8s-manifests
|
- git clone https://mnky:$GITEA_TOKEN@gitea.mnky-code.de/mnky/k8s-manifests
|
||||||
- cd k8s-manifests
|
- cd k8s-manifests
|
||||||
- sed -i "s|image:.*ngrx-playground.*|image: gitea.mnky-code.de/mnky/ngrx-playground:${DRONE_COMMIT_SHA:0:8}|" ngrx-playground/deployment.yaml
|
- sed -i "s|image:.*ngrx-playground.*|image: gitea.mnky-code.de/mnky/ngrx-playground:$DRONE_COMMIT_SHA|" ngrx-playground/deployment.yaml
|
||||||
- git config user.email "drone@ci"
|
- git config user.email "drone@ci"
|
||||||
- git config user.name "Drone CI"
|
- git config user.name "Drone CI"
|
||||||
- git add .
|
- git add .
|
||||||
- git commit -m "Update image to ${DRONE_COMMIT_SHA:0:8}"
|
- git commit -m "update image"
|
||||||
- git push
|
- git push
|
||||||
|
environment:
|
||||||
|
GITEA_TOKEN:
|
||||||
|
from_secret: gitea_token
|
||||||
Reference in New Issue
Block a user