Skip to content

Commit

Permalink
update npm chat-core publish config
Browse files Browse the repository at this point in the history
  • Loading branch information
mongodben committed Nov 1, 2023
1 parent d3e20a2 commit 5be4922
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 30 deletions.
36 changes: 8 additions & 28 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ name: staging-build-chat-server
trigger:
branch:
- main
- oss-refactor-pt-2 # TODO: remove before merge
event:
- push

Expand Down Expand Up @@ -136,7 +135,6 @@ trigger:
- chat-ui/**/*
branch:
- main
- oss-refactor-pt-2 # TODO: remove before merge

steps:
# Deploys docker image associated with staging build that triggered promotion
Expand Down Expand Up @@ -329,7 +327,6 @@ name: staging-build-ingest-mongodb-public
trigger:
branch:
- main
- oss-refactor-pt-2 # TODO: remove before merge
event:
- push
paths:
Expand Down Expand Up @@ -393,7 +390,6 @@ trigger:
- chat-core/**/*
branch:
- main
- oss-refactor-pt-2 # TODO: remove before merge

steps:
# Deploys docker image associated with staging build that triggered promotion
Expand Down Expand Up @@ -494,27 +490,28 @@ steps:
from_secret: prod_kubernetes_token

# ---
# mongodb-rag-ingest package
# mongodb-rag-core package
# ---
---
kind: pipeline
type: kubernetes
name: publish-mongodb-rag-ingest
name: publish-mongodb-rag-core
depends_on: ["test-all"]

trigger:
event:
- tag
ref:
include:
- refs/tags/mongodb-rag-ingest-v*
- refs/tags/mongodb-rag-core-v*

steps:
- name: build package
image: node:18
commands:
- npm ci
- npm run build
- cd chat-core && npm publish
environment:
PORT: 3000
OPENAI_EMBEDDING_MODEL: text-embedding-ada-002
Expand Down Expand Up @@ -542,40 +539,24 @@ steps:
from_secret: lg_artifactory_email
GITHUB_ACCESS_TOKEN:
from_secret: github_access_token
- name: npm
image: plugins/npm
environment:
LG_ARTIFACTORY_PASSWORD:
from_secret: lg_artifactory_password
LG_ARTIFACTORY_USERNAME:
from_secret: lg_artifactory_username
LG_ARTIFACTORY_EMAIL:
from_secret: lg_artifactory_email
settings:
folder: chat-core
registry: https://registry.npmjs.org/
username:
from_secret: mongodb_ai_npm_username
email:
from_secret: mongodb_ai_npm_email
password:
NPM_TOKEN:
from_secret: mongodb_ai_npm_token

# ---
# mongodb-rag-core package
# mongodb-rag-ingest package
# ---
---
kind: pipeline
type: kubernetes
name: publish-mongodb-rag-core
name: publish-mongodb-rag-ingest
depends_on: ["test-all"]

trigger:
event:
- tag
ref:
include:
- refs/tags/mongodb-rag-core-v*
- refs/tags/mongodb-rag-ingest-v*

steps:
- name: build package
Expand Down Expand Up @@ -628,7 +609,6 @@ steps:
from_secret: mongodb_ai_npm_email
password:
from_secret: mongodb_ai_npm_token

# ---
# mongodb-chatbot-server package
# ---
Expand Down
6 changes: 4 additions & 2 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
@lg-chat:registry=https://artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/
//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/

@lg-tools:registry=https://artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/

//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/
//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/:_password=${LG_ARTIFACTORY_PASSWORD}
//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/:username=${LG_ARTIFACTORY_USERNAME}
//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/:email=${LG_ARTIFACTORY_EMAIL}
//artifactory.corp.mongodb.com/artifactory/api/npm/leafygreen-ui/:always-auth=true

//registry.npmjs.org/:_authToken=${NPM_TOKEN}

0 comments on commit 5be4922

Please sign in to comment.