Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
11bf349
Initial work on bulk apply using rest endpoint
thokra-nav Mar 11, 2026
74c312b
cluster -> environment
thokra-nav Mar 11, 2026
14b48b7
Use latest tester
thokra-nav Mar 11, 2026
821cb3f
Move activitylog to correct resources, when applicable
thokra-nav Mar 11, 2026
f4237b0
Refactor apply activity log to support unknown resource types
thokra-nav Mar 12, 2026
f5434ff
Consolidate context setup
thokra-nav Mar 12, 2026
836f92e
Rename activitylog for k8s types
thokra-nav Mar 13, 2026
35750c3
Use modern Go
thokra-nav Mar 13, 2026
730c48e
change activity log resource type name
thokra-nav Mar 13, 2026
5cbd4aa
Add more resources
thokra-nav Mar 16, 2026
2c5caf0
Add Github claims when applied using gh workflow
thokra-nav Mar 16, 2026
63369f2
Move migration
thokra-nav Mar 16, 2026
299795e
build(mise): use EmmyLuaCodeStyle from toolchain
sechmann Mar 17, 2026
422dbe9
refactor(apply): make endpoint handler stateful
sechmann Mar 17, 2026
f5d44b9
refactor(apply): inject dynamic client factory for environment clients
sechmann Mar 18, 2026
b2c7d73
fix: bump migration id
sechmann Mar 18, 2026
b490fcb
fix: regenerate
sechmann Mar 18, 2026
a1b2d92
fix: use exported ActivityLogEntryResourceTypeJob constant
sechmann Mar 18, 2026
3705bba
fix: re-add and rename managementWatcherMgr
sechmann Mar 18, 2026
fb7c199
refactor: simplify dynamic client override for apply
sechmann Mar 18, 2026
db7e4e7
fix: costupdater test use localhost
sechmann Mar 18, 2026
78b1baf
refactor: make GitHub OIDC middleware injectable to avoid network cal…
sechmann Mar 18, 2026
321b052
Add /api/v1/ path to ingress and support dynamic client factory in API
thokra-nav Mar 19, 2026
90b6a64
Log enabled middlewares
thokra-nav Mar 19, 2026
cc70248
Require team membership
thokra-nav Mar 20, 2026
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
1 change: 1 addition & 0 deletions .configs/gqlgen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ autobind:
- "github.com/99designs/gqlgen/graphql/introspection" # Without this line in the beginning, a `prelude.resolver.go` is generated
- "github.com/nais/api/internal/activitylog"
- "github.com/nais/api/internal/alerts"
- "github.com/nais/api/internal/apply"
- "github.com/nais/api/internal/auth/authz"
- "github.com/nais/api/internal/cost"
- "github.com/nais/api/internal/deployment"
Expand Down
45 changes: 1 addition & 44 deletions .mise-tasks/fmt/lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,47 +3,4 @@

set -e

LUA_FORMATTER_VERSION=1.5.6
BIN_DIR=./bin
LUAFMT="$BIN_DIR/luafmt-$LUA_FORMATTER_VERSION"
LUA_FORMATTER_URL="https://github.com/CppCXY/EmmyLuaCodeStyle/releases/download/$LUA_FORMATTER_VERSION"

if [ ! -d "$LUAFMT" ]; then
OS=$(uname -s)
ARCH=$(uname -m)
if [ "$OS" = "Darwin" ]; then
if [ "$ARCH" = "x86_64" ]; then
LUA_FORMATTER_FILE=darwin-x64
else
if [ "$ARCH" = "arm64" ]; then
LUA_FORMATTER_FILE=darwin-arm64
else
echo "Unsupported architecture: $ARCH on macOS"
exit 1
fi
fi
elif [ "$OS" = "Linux" ]; then
if [ "$ARCH" = "x86_64" ]; then
LUA_FORMATTER_FILE=linux-x64
else
if [ "$ARCH" = "aarch64" ]; then
LUA_FORMATTER_FILE=linux-aarch64
else
echo "Unsupported architecture: $ARCH on Linux"
exit 1
fi
fi
else
echo "Unsupported OS: $OS"
exit 1
fi

mkdir -p "$LUAFMT"
curl -L "$LUA_FORMATTER_URL/$LUA_FORMATTER_FILE.tar.gz" -o /tmp/luafmt.tar.gz
tar -xzf /tmp/luafmt.tar.gz -C "$LUAFMT"
rm /tmp/luafmt.tar.gz
mv "$LUAFMT/$LUA_FORMATTER_FILE/"* "$LUAFMT/"
rmdir "$LUAFMT/$LUA_FORMATTER_FILE"
fi

$LUAFMT/bin/CodeFormat format -w . --ignores-file ".gitignore" -c ./integration_tests/.editorconfig
CodeFormat format -w . --ignores-file ".gitignore" -c ./integration_tests/.editorconfig
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ go test -v -tags=integration_test -run "TestIntegration/<testnavn>" ./integratio

1. **Før du endrer kode**: Les relevante filer for å forstå eksisterende mønstre
2. **Etter endringer i `.graphqls`**: Kjør `mise run generate:graphql`
1. Hvis det havner modeller i `internal/graph/model/donotuse/models_gen.go`, flytt disse til riktig pakke/domene og generer på nytt
3. **Etter endringer i `.sql`**: Kjør `mise run generate:sql`
4. **Etter alle endringer**: Kjør `mise run test` og `mise run fmt`
5. **Ved kompileringsfeil**: Sjekk at generert kode er oppdatert
Expand Down
7 changes: 7 additions & 0 deletions charts/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,10 @@ spec:
name: rest
path: /teams/
pathType: Prefix
- backend:
service:
name: "{{ .Release.Name }}"
port:
name: rest
path: /api/v1/
pathType: Prefix
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ require (
github.com/nais/bifrost v0.0.0-20260106105449-911627ac2c61
github.com/nais/liberator v0.0.0-20260216142648-ee49a9372bc4
github.com/nais/pgrator/pkg/api v0.0.0-20260219115817-cf954d58c04e
github.com/nais/tester v0.1.0
github.com/nais/tester v0.1.1
github.com/nais/unleasherator v0.0.0-20251216221129-efebc54203fe
github.com/nais/v13s/pkg/api v0.0.0-20260313084546-caca6d4cd742
github.com/patrickmn/go-cache v2.1.0+incompatible
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -800,6 +800,8 @@ github.com/nais/pgrator/pkg/api v0.0.0-20260219115817-cf954d58c04e h1:FWPwIgFlNj
github.com/nais/pgrator/pkg/api v0.0.0-20260219115817-cf954d58c04e/go.mod h1:iDLbi5Ss8Fs6L5+ot8jBLStR5/bdiPgblt7OsN06n50=
github.com/nais/tester v0.1.0 h1:dojqSFT3RB8bPZ0Wv0QlBAa/MVPitftpkErC2awVHmU=
github.com/nais/tester v0.1.0/go.mod h1:NCQMcgftHz/EXorob1XwDTOqkQmImDqr51YQ2Uea9Pc=
github.com/nais/tester v0.1.1 h1:tpJ5HKpu3mEIWX/mec0Yj0xLHEpt+MwTAsj282n0Py0=
github.com/nais/tester v0.1.1/go.mod h1:NCQMcgftHz/EXorob1XwDTOqkQmImDqr51YQ2Uea9Pc=
github.com/nais/unleasherator v0.0.0-20251216221129-efebc54203fe h1:CdRVopOihru4tXVwKZjhg6C8SbPLCQYOhJKpjBZYhjg=
github.com/nais/unleasherator v0.0.0-20251216221129-efebc54203fe/go.mod h1:Tiz/1If3WgcfvNhmsO5DiQC+L+1XhBG3KWbIfbjx4EU=
github.com/nais/v13s/pkg/api v0.0.0-20260313084546-caca6d4cd742 h1:OQ3n3/UjTf7pO5GzxU+wWRGP3skyOqdoTruS3wm28N4=
Expand Down
Loading
Loading