Skip to content

Update dependency jquery to v4 #787

Update dependency jquery to v4

Update dependency jquery to v4 #787

Workflow file for this run

name: calendar-api
on:
workflow_dispatch:
push:
paths:
- "calendar-api/**"
- ".github/workflows/calendar-api.yml"
jobs:
build:
permissions:
contents: read
packages: write
runs-on: ubuntu-latest
defaults:
run:
working-directory: calendar-api
steps:
- uses: actions/checkout@v6
- uses: pnpm/action-setup@v4
with:
package_json_file: calendar-api/package.json
- uses: actions/setup-node@v6
with:
node-version: "24"
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- run: pnpm install
- run: pnpm lint
- run: pnpm typecheck
- run: pnpm test
- name: Build container
uses: docker/build-push-action@v6
with:
context: calendar-api
load: true
tags: ghcr.io/blindern/intern-calendar-api:latest
cache-from: type=gha
cache-to: type=gha,mode=max
- run: scripts/docker-test-image.sh ghcr.io/blindern/intern-calendar-api
- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push container
if: github.ref == 'refs/heads/main'
id: docker_build
uses: docker/build-push-action@v6
with:
context: calendar-api
push: true
tags: ghcr.io/blindern/intern-calendar-api:latest
- name: Deploy
if: github.ref == 'refs/heads/main'
run: |
curl --fail -L -i -H "authorization: bearer $DEPLOYER_TOKEN" -H "content-type: application/json" -X POST https://deployer.foreningenbs.no/deploy -d '
{
"service": "intern",
"attributes": {
"calendar_api_image": "ghcr.io/blindern/intern-calendar-api@${{ steps.docker_build.outputs.digest }}"
}
}'
env:
DEPLOYER_TOKEN: ${{ secrets.DEPLOYER_TOKEN }}