refactored payment request type #45
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Capstone UI | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
name: Build and Deploy | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v4 | |
- name: Use Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20.x' | |
- name: NPM install | |
run: npm install | |
- name: Prettier format | |
run: npx prettier . --check | |
- name: Log into DockerHub | |
uses: docker/login-action@v3 | |
with: | |
username: emmanuelu17 | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Build image | |
run: docker build --tag capstone:latest . --progress=plain --build-arg="PORT=4200" | |
- name: Push image to dockerhub | |
run: | | |
docker image tag capstone:latest emmanuelu17/capstone:latest | |
docker push --all-tags emmanuelu17/capstone | |
# See https://buildpacks.io/docs/buildpack-author-guide/publishing-with-github-actions/ | |
# - name: Setup-tools | |
# uses: buildpacks/github-actions/setup-tools@v5.1.0 | |
# | |
# - name: Setup pack | |
# uses: buildpacks/github-actions/setup-pack@v5.1.0 | |
# See more on paketo web servers https://github.com/paketo-buildpacks/web-servers | |
# See for more on nginx config https://docs.vmware.com/en/VMware-Tanzu-Buildpacks/services/tanzu-buildpacks/GUID-nginx-nginx-buildpack.html | |
# - name: Build image | |
# run: | | |
# #!/usr/bin/env bash | |
# pack config default-builder paketobuildpacks/builder:base | |
# pack build emmanuelu17/capstone --buildpack paketo-buildpacks/web-servers \ | |
# --env "BP_WEB_SERVER=nginx" \ | |
# --env "BP_WEB_SERVER_ROOT=dist/capstone" \ | |
# --env "BP_WEB_SERVER_ENABLE_PUSH_STATE=true" \ | |
# --env "NODE_ENV=production" | |
# shell: bash | |
# | |
# - name: Set up Docker Build | |
# uses: docker/setup-buildx-action@v3 | |
# | |
# - name: Tag & Publish to Docker Hub | |
# run: docker push --all-tags emmanuelu17/capstone |