Skip to content

Bump com.github.navikt.common-java-modules:cxf #1894

Bump com.github.navikt.common-java-modules:cxf

Bump com.github.navikt.common-java-modules:cxf #1894

name: Build-Deploy-Preprod
on:
push:
branches-ignore:
- 'main'
workflow_dispatch:
env:
IMAGE: ghcr.io/navikt/familie-oppdrag:${{ github.sha }}
jobs:
build:
name: Bygg app/image, push til github
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/setup-java@v4
with:
java-version: 21
distribution: 'temurin'
cache: 'maven'
- name: Bygg med maven
env:
GITHUB_USERNAME: x-access-token
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: mvn -B --no-transfer-progress package verify --settings .m2/maven-settings.xml --file pom.xml
- name: Bygg Docker image
run: |
docker build -t $IMAGE .
- name: Login to GitHub Container Registry
if: github.triggering_actor != 'dependabot[bot]'
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Push Docker image
if: github.triggering_actor != 'dependabot[bot]'
run: docker push $IMAGE
deploy:
name: Deploy to FSS
if: github.triggering_actor != 'dependabot[bot]'
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Deploy til dev-fss team namespace
uses: nais/deploy/actions/deploy@v2
env:
APIKEY: ${{ secrets.NAIS_DEPLOY_APIKEY }}
CLUSTER: dev-fss
RESOURCE: app-preprod.yaml