Skip to content

Commit

Permalink
Implement CI/CD
Browse files Browse the repository at this point in the history
  • Loading branch information
teguhbayu committed May 19, 2024
1 parent babd4e2 commit d13f29c
Showing 1 changed file with 19 additions and 3 deletions.
22 changes: 19 additions & 3 deletions .github/workflows/CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,22 @@ jobs:
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npx prisma generate
- run: npm run build --if-present
- name: create env
run: >
touch /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo DATABASE_URL=${{secrets.DATABASE_URL}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo NEXTAUTH_SECRET=${{secrets.NEXTAUTH_SECRET}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo CLOUDINARY_URL=${{secrets.CLOUDINARY_URL}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo NEXTAUTH_URL=${{secrets.NEXTAUTH_URL}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo GOOGLE_APP_PASSWORD=${{secrets.GOOGLE_APP_PASSWORD}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
echo GOOGLE_EMAIL=${{secrets.GOOGLE_EMAIL}} >> /home/mokletdev/actions-runner/_work/antareja/antareja/.env.local
- name: Install Modules
run: npm ci
- run: npm install dotenv-cli
- name: Generate prisma
run: npm run prisma:generate
- name: Build site
run: npm run build --if-present
- name: change dir
run: cd /home/mokletdev/actions-runner/_work/antareja/antareja
- run: pm2 restart 0

0 comments on commit d13f29c

Please sign in to comment.