Skip to content
This repository was archived by the owner on Sep 3, 2024. It is now read-only.

Commit dbb6139

Browse files
publishing to myget
1 parent 2b30ab2 commit dbb6139

File tree

2 files changed

+14
-1
lines changed

2 files changed

+14
-1
lines changed

Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
FROM node:10.12.0-alpine AS build
2+
ARG MYGET_API_KEY
3+
ARG VERSION
24

35
RUN apk add --no-cache git
46

@@ -11,8 +13,16 @@ RUN yarn --frozen-lockfile
1113
COPY . .
1214

1315
RUN yarn build && \
16+
yarn build:dist && \
1417
yarn cache clean
1518

19+
RUN echo "https://www.myget.org/F/sqlstreamstore/npm/:_authToken=${MYGET_API_KEY}" > .npmrc && \
20+
echo "@sql-stream-store:registry=https://www.myget.org/F/sqlstreamstore/npm/" >> .npmrc
21+
22+
RUN test -z "$MYGET_API_KEY" || \
23+
yarn publish --new-version $VERSION && \
24+
echo "No API key found, skipping publishing..."
25+
1626
FROM nginx:1.15.5-alpine AS runtime
1727

1828
COPY ./nginx/nginx.conf /etc/nginx/nginx.conf

build.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
#!/usr/bin/env bash
22
DOCKERTAG=${TRAVIS_TAG:-latest}
33

4-
docker build --build-arg semver=TRAVIS_TAG --tag sql-stream-store-browser:${DOCKERTAG} .
4+
docker build \
5+
--build-arg VERSION=$VERSION \
6+
--build-arg MYGET_API_KEY=$MYGET_API_KEY \
7+
--tag sql-stream-store-browser:${DOCKERTAG} .
58

69
docker images --filter=reference="sql-stream-store-browser:${DOCKERTAG}"

0 commit comments

Comments
 (0)