Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions .github/workflows/on_deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Build and deploy
on:
workflow_dispatch:

push:
branches:
- main
jobs:
build_and_deploy:
name: Build, push and deploy
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v4
- name: Build and push image and SBOM to OCI registry
uses: nais/docker-build-push@v0
id: docker-build-push
with:
team: ${{ vars.NAIS_TEAM }}
identity_provider: ${{ secrets.NAIS_WORKLOAD_IDENTITY_PROVIDER }}
project_id: ${{ secrets.NAIS_MANAGEMENT_PROJECT_ID }}
- name: Deploy to Nais
uses: nais/deploy/actions/deploy@v2
env:
CLUSTER: test
RESOURCE: .nais/test.yaml
VAR: image=${{ steps.docker-build-push.outputs.image }}
TELEMETRY: ${{ steps.docker-build-push.outputs.telemetry }}
DEPLOY_SERVER: deploy.ssb.cloud.nais.io:443
17 changes: 17 additions & 0 deletions .nais/test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
apiVersion: nais.io/v1alpha1
kind: Application
metadata:
name: kontrollprogram
namespace: kostra
spec:
ingresses:
- https://kostra-kontrollprogram.test.ssb.no
image: {{image}}
port: 8080
replicas:
max: 1
min: 1
resources:
requests:
cpu: 50m
memory: 160Mi
Loading