Docker speedbuild
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
4da3cea59f
commit
36ce64a79d
24
.drone.yml
24
.drone.yml
|
@ -12,6 +12,20 @@ get:
|
|||
path: odit-registry-builder
|
||||
name: password
|
||||
|
||||
---
|
||||
kind: secret
|
||||
name: npmjs_domain
|
||||
get:
|
||||
path: odit-npm-bot
|
||||
name: domain
|
||||
|
||||
---
|
||||
kind: secret
|
||||
name: npmjs_token
|
||||
get:
|
||||
path: odit-npm-bot
|
||||
name: token
|
||||
|
||||
---
|
||||
kind: pipeline
|
||||
type: kubernetes
|
||||
|
@ -30,6 +44,11 @@ steps:
|
|||
tags:
|
||||
- latest
|
||||
registry: registry.odit.services
|
||||
build_args:
|
||||
- NPM_REGISTRY_DOMAIN:
|
||||
from_secret: npmjs_domain
|
||||
- NPM_REGISTRY_TOKEN:
|
||||
from_secret: npmjs_token
|
||||
mtu: 1000
|
||||
when:
|
||||
branch:
|
||||
|
@ -53,6 +72,11 @@ steps:
|
|||
tags:
|
||||
- '${DRONE_TAG}'
|
||||
registry: registry.odit.services
|
||||
build_args:
|
||||
- NPM_REGISTRY_DOMAIN:
|
||||
from_secret: npmjs_domain
|
||||
- NPM_REGISTRY_TOKEN:
|
||||
from_secret: npmjs_token
|
||||
mtu: 1000
|
||||
trigger:
|
||||
event:
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
FROM registry.odit.services/hub/library/node:17.0.1-alpine3.14
|
||||
ARG NPM_REGISTRY_DOMAIN=registry.npmjs.org
|
||||
ARG NPM_REGISTRY_TOKEN=null
|
||||
WORKDIR /app
|
||||
COPY package.json .
|
||||
# COPY yarn.lock .
|
||||
RUN yarn --production --frozen-lockfile
|
||||
RUN npm config set registry https://$NPM_REGISTRY_DOMAIN && npm config set //$NPM_REGISTRY_DOMAIN/:_authToken $NPM_REGISTRY_TOKEN
|
||||
RUN npm i -g pnpm && pnpm i
|
||||
COPY migrations ./migrations
|
||||
COPY src ./src
|
||||
COPY knexfile.js ./
|
||||
RUN mkdir db
|
||||
#
|
||||
# FROM astefanutti/scratch-node:16.0.0
|
||||
|
||||
FROM registry.odit.services/hub/library/node:17.0.1-alpine3.14
|
||||
WORKDIR /app
|
||||
COPY --from=0 /app /app
|
||||
|
|
Loading…
Reference in New Issue