Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move publishing of REST sample Image from AZP to GHA #1091

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/workflows/rest-sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,14 @@ jobs:
- name: Test REST Sample Application
run: npm test
working-directory: asset-transfer-basic/rest-api-typescript

- name: Build REST Sample Docker Image
run: docker build -t ghcr.io/hyperledger/fabric-rest-sample .
working-directory: asset-transfer-basic/rest-api-typescript

- name: Publish REST Sample Docker Image
if: github.event_name == 'push' && (github.ref == 'refs/heads/main')
run: |
echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin
docker push ghcr.io/hyperledger/fabric-rest-sample:latest
working-directory: asset-transfer-basic/rest-api-typescript
6 changes: 3 additions & 3 deletions asset-transfer-basic/rest-api-typescript/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:14-alpine3.14 AS build
FROM node:18-alpine3.14 AS build

RUN apk add --no-cache g++ make python3 dumb-init

Expand All @@ -10,14 +10,14 @@ RUN npm ci
RUN npm run build
RUN npm prune --production

FROM node:14-alpine3.14
FROM node:18-alpine3.14
ENV NODE_ENV production
WORKDIR /app

COPY --from=build /usr/bin/dumb-init /usr/bin/dumb-init
COPY --chown=node:node --from=build /app .

EXPOSE 3000
EXPOSE 3000

USER node

Expand Down
46 changes: 0 additions & 46 deletions ci/azure-pipelines.yml

This file was deleted.

Loading