Skip to content

feat: create a function to update data in redis cache #6

feat: create a function to update data in redis cache

feat: create a function to update data in redis cache #6

name: Continuous deployment workflow
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
continuous-deployment:
runs-on: ubuntu-latest
steps:
- name: Fetch the repository
uses: actions/checkout@v4
- name: Install the dependencies
run: npm install
- name: Create `.env.secret` file
run: echo "${{ secrets.TESTING_ENV_FILE_CONTENT }}" >> .env.secret
- name: Run tests
run: npm run test
- name: Build the Docker Image
run: docker build -t ${{ secrets.DOCKERHUB_USERNAME }}/am-store-server .
- name: Log in to Docker hub
run: echo ${{ secrets.DOCKERHUB_PASSWORD }} | docker login -u ${{ secrets.DOCKERHUB_USERNAME }} --password-stdin
- name: Push the Docker Image
run: docker push ${{ secrets.DOCKERHUB_USERNAME }}/am-store-server
- name: Trigger deploy event for the server
run: curl ${{ secrets.RENDER_DEPLOY_HOOK_URL }}