refactor: Update Woodpecker CI config and StorageHierarchy component
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
This commit is contained in:
parent
6400eb9513
commit
c5f992c8fe
2 changed files with 45 additions and 33 deletions
|
@ -1,14 +1,17 @@
|
|||
pipeline:
|
||||
variables:
|
||||
- &golang_image 'golang:1.24'
|
||||
|
||||
steps:
|
||||
backend-lint:
|
||||
image: golang:1.21
|
||||
group: lint
|
||||
image: *golang_image
|
||||
commands:
|
||||
- go vet ./...
|
||||
- go fmt ./...
|
||||
when:
|
||||
event: [push, tag]
|
||||
|
||||
frontend-lint:
|
||||
image: node:20
|
||||
group: lint
|
||||
commands:
|
||||
- cd web
|
||||
- npm ci
|
||||
|
@ -20,18 +23,23 @@ pipeline:
|
|||
- cd web
|
||||
- npm ci
|
||||
- npm run build
|
||||
depends_on:
|
||||
- frontend-lint
|
||||
when:
|
||||
status: [success]
|
||||
event: [ push, tag ]
|
||||
|
||||
backend-build:
|
||||
image: golang:1.21
|
||||
image: *golang_image
|
||||
commands:
|
||||
- go mod download
|
||||
- go generate ./...
|
||||
# Build with embedded frontend
|
||||
- go build -o inventory -ldflags="-s -w" .
|
||||
depends_on:
|
||||
- frontend-build
|
||||
- backend-lint
|
||||
when:
|
||||
status: [success]
|
||||
event: [ push, tag ]
|
||||
|
||||
# Create artifacts
|
||||
artifacts:
|
||||
|
@ -40,19 +48,23 @@ pipeline:
|
|||
- mkdir -p artifacts
|
||||
- cp inventory artifacts/
|
||||
- tar -czvf artifacts/inventory.tar.gz inventory
|
||||
depends_on:
|
||||
- backend-build
|
||||
when:
|
||||
status: [success]
|
||||
event: [ push, tag ]
|
||||
|
||||
# Optional step for creating a Docker image
|
||||
docker-build:
|
||||
image: plugins/docker
|
||||
settings:
|
||||
repo: ${DRONE_REPO_OWNER}/inventory
|
||||
tags:
|
||||
- latest
|
||||
- ${DRONE_TAG##v}
|
||||
dockerfile: Dockerfile
|
||||
when:
|
||||
branch: main
|
||||
event: [push, tag]
|
||||
status: [success]
|
||||
#docker-build:
|
||||
# image: plugins/docker
|
||||
# settings:
|
||||
# repo: ${DRONE_REPO_OWNER}/inventory
|
||||
# tags:
|
||||
# - latest
|
||||
# - ${DRONE_TAG##v}
|
||||
# dockerfile: Dockerfile
|
||||
# depends_on:
|
||||
# - backend-lint
|
||||
# - frontend-lint
|
||||
# when:
|
||||
# branch: main
|
||||
# event: [push, tag]
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<v-select
|
||||
v-model="selectedStorageId"
|
||||
:items="storageSpaces"
|
||||
item-title="location"
|
||||
item-title="name"
|
||||
item-value="id"
|
||||
label="Select Storage Space"
|
||||
density="compact"
|
||||
|
|
Loading…
Add table
Reference in a new issue