Custom GitHub Actions to help you build CI/CD workflow to deploy JS/TS projects to Moralis server.
- Vanilla Javascript
- React
Note that this custom GitHub Action is tested to be working only with Vanilla Javascript and React project. For Vanilla, checkout main.yml within this repository. For React, checkout an example here
name: Moralis Deploy
on: [push]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Deploy
uses: YosephKS/moralis-deploy-action@<version>
env:
MORALIS_API_KEY: ${{ secrets.MORALIS_API_KEY }}
MORALIS_API_SECRET: ${{ secrets.MORALIS_API_SECRET }}
MORALIS_API_SUBDOMAIN: ${{ secrets.MORALIS_API_SUBDOMAIN }}
CUSTOM_FOLDER_PATH: ${{ secrets.CUSTOM_FOLDER_PATH }}The environment variables need to be stored in the repository's secrets. To get the value of the required environment variables, sign up for a free acccount here and create a new server.
MORALIS_API_KEY(required): GetCLI API KeyvalueMORALIS_API_SECRET(required): GetCLI API SecretvalueMORALIS_API_SUBDOMAIN(required): Get subdomain from theServer URL, e.g.If https://yjf6ilbm7qh5.usemoralis.com:2053/server is your Server URL, then the subdomain value will beyjf6ilbm7qh5.usemoralis.comCUSTOM FOLDER_PATH: The path to where your build folder (containingindex.html) is located; If no value is provided then it defaults to the root folder.
See CONTRIBUTING.md