Skip to content

Commit

Permalink
Update ui branch
Browse files Browse the repository at this point in the history
  • Loading branch information
NHAS committed Feb 10, 2025
2 parents 0de7443 + b3cdc14 commit 1febda2
Show file tree
Hide file tree
Showing 18 changed files with 551 additions and 267 deletions.
14 changes: 4 additions & 10 deletions .github/workflows/test_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
run: sudo apt update && sudo apt upgrade

- name: Install build tools
run: sudo apt install -y make git npm gulp libpam0g-dev
run: sudo apt install -y gcc make git npm libpam0g-dev

- name: Install NPM tools
working-directory: adminui/frontend
Expand Down Expand Up @@ -60,20 +60,14 @@ jobs:
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
platforms: linux/amd64
tags: wagvpn/wag:latest
push: true

deploy-ghcr:
runs-on: ubuntu-latest
needs: test
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/unstable'
strategy:
fail-fast: true
matrix:
platform:
- linux/amd64
- linux/arm64
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -103,10 +97,10 @@ jobs:
type=raw,value=unstable,enable=${{ github.ref == 'refs/heads/unstable' }}
- name: Build and push
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64,linux/arm64
platforms: linux/amd64
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
push: true
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,6 @@
"typeinfo": "c",
"in.h": "c",
"numbers": "c"
}
},
"git.ignoreLimitWarning": true
}
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,9 @@ Full config example
"IssuerURL": "http://localhost:8080/",
"ClientSecret": "<OMITTED>",
"ClientID": "account",
"GroupsClaimName": "groups"
"GroupsClaimName": "groups",
"DeviceUsernameClaim": "",
"Scopes": []
}
},
"Clustering": {
Expand Down
1 change: 1 addition & 0 deletions adminui/frontend/src/api/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,7 @@ export interface OidcResponseDTO {
client_id: string
group_claim_name: string
device_username_claim: string
scopes: string[]
}

export interface PamResponseDTO {
Expand Down
12 changes: 12 additions & 0 deletions adminui/frontend/src/pages/Settings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,18 @@ function doesTunnelHaveTLS() {
</label>
<input v-model="loginSettingsData.oidc.device_username_claim" type="text" class="input input-bordered w-full" />
</div>
<div class="form-control">
<label class="label font-bold">
<span class="label-text">Scopes</span>
</label>
<input
:value="loginSettingsData.oidc.scopes?.join(' ')"
@input="e => loginSettingsData.oidc.scopes = (e.target as HTMLInputElement).value.split(' ')"
type="text"
class="input input-bordered w-full"
placeholder="Enter scopes separated by spaces"
/>
</div>
</div>
</div>
<div class="card bg-base-100 shadow-xl min-w-[350px] h-max">
Expand Down
2 changes: 1 addition & 1 deletion commands/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ func (g *start) Run() error {
wagType += " Learner"
}

log.Printf("%s starting, Ctrl + C to stop", wagType)
log.Printf("%s (%s) starting, Ctrl + C to stop", wagType, config.Version)

err = <-errorChan
cancel <- true
Expand Down
4 changes: 3 additions & 1 deletion docker-test-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@
"OIDC": {
"IssuerURL": "",
"ClientSecret": "",
"ClientID": ""
"ClientID": "",
"DeviceUsernameClaim": "",
"Scopes": []
},
"PAM": {
"ServiceName": ""
Expand Down
114 changes: 57 additions & 57 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,123 +6,123 @@ toolchain go1.23.2

require (
github.com/NHAS/autoetcdtls v0.0.0-20240225231227-9d5906c5b4f2
github.com/NHAS/session v0.0.0-20241124222245-5e27e2e39187
github.com/NHAS/session v0.0.0-20241210092238-534610261793
github.com/NHAS/webauthn v0.0.0-20240606085832-ea3172ef4dfa
github.com/boombuler/barcode v1.0.2
github.com/caddyserver/certmagic v0.21.7
github.com/coreos/go-iptables v0.8.0
github.com/gaissmai/bart v0.13.1
github.com/go-acme/lego/v4 v4.20.4
github.com/go-playground/validator/v10 v10.22.1
github.com/gaissmai/bart v0.17.10
github.com/go-playground/validator/v10 v10.24.0
github.com/gorilla/websocket v1.5.3
github.com/libdns/cloudflare v0.1.1
github.com/mattn/go-sqlite3 v1.14.24
github.com/mdlayher/netlink v1.7.2
github.com/mdlayher/netlink v1.7.3-0.20250113171957-fbb4dce95f42
github.com/msteinert/pam v1.2.0
github.com/pquerna/otp v1.4.0
github.com/zitadel/oidc/v3 v3.33.1
go.etcd.io/etcd/api/v3 v3.5.17
go.etcd.io/etcd/client/pkg/v3 v3.5.17
go.etcd.io/etcd/client/v3 v3.5.17
go.etcd.io/etcd/server/v3 v3.5.17
golang.org/x/crypto v0.29.0
golang.org/x/exp v0.0.0-20241108190413-2d47ceb2692f
golang.org/x/net v0.31.0
golang.org/x/sys v0.27.0
golang.zx2c4.com/wireguard v0.0.0-20230325221338-052af4a8072b
golang.zx2c4.com/wireguard/wgctrl v0.0.0-20230429144221-925a1e7659e6
tailscale.com v1.76.6
github.com/stretchr/testify v1.10.0
github.com/zitadel/oidc/v3 v3.34.1
go.etcd.io/etcd/api/v3 v3.5.18
go.etcd.io/etcd/client/pkg/v3 v3.5.18
go.etcd.io/etcd/client/v3 v3.5.18
go.etcd.io/etcd/server/v3 v3.5.18
golang.org/x/crypto v0.33.0
golang.org/x/exp v0.0.0-20250207012021-f9890c6ad9f3
golang.org/x/net v0.34.0
golang.org/x/sys v0.30.0
golang.zx2c4.com/wireguard v0.0.0-20231211153847-12269c276173
golang.zx2c4.com/wireguard/wgctrl v0.0.0-20241231184526-a9ab2273dd10
tailscale.com v1.80.1
)

require (
github.com/beorn7/perks v1.0.1 // indirect
github.com/bits-and-blooms/bitset v1.15.0 // indirect
github.com/caddyserver/certmagic v0.21.4 // indirect
github.com/caddyserver/zerossl v0.1.3 // indirect
github.com/cenkalti/backoff/v4 v4.3.0 // indirect
github.com/cespare/xxhash/v2 v2.3.0 // indirect
github.com/cloudflare/cloudflare-go v0.108.0 // indirect
github.com/coreos/go-semver v0.3.1 // indirect
github.com/coreos/go-systemd/v22 v22.5.0 // indirect
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
github.com/dustin/go-humanize v1.0.1 // indirect
github.com/fxamacker/cbor/v2 v2.7.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.6 // indirect
github.com/gabriel-vasile/mimetype v1.4.8 // indirect
github.com/go-jose/go-jose/v4 v4.0.4 // indirect
github.com/go-logr/logr v1.4.2 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-playground/locales v0.14.1 // indirect
github.com/go-playground/universal-translator v0.18.1 // indirect
github.com/go-webauthn/x v0.1.15 // indirect
github.com/goccy/go-json v0.10.3 // indirect
github.com/go-webauthn/x v0.1.16 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang-jwt/jwt/v4 v4.5.1 // indirect
github.com/golang-jwt/jwt/v5 v5.2.1 // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/btree v1.1.3 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/go-querystring v1.1.0 // indirect
github.com/google/go-tpm v0.9.1 // indirect
github.com/google/go-tpm v0.9.3 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/gorilla/securecookie v1.1.2 // indirect
github.com/grpc-ecosystem/go-grpc-middleware v1.4.0 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.23.0 // indirect
github.com/jonboulle/clockwork v0.4.0 // indirect
github.com/josharian/native v1.1.1-0.20230202152459-5c7d0dd6ab86 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 // indirect
github.com/jonboulle/clockwork v0.5.0 // indirect
github.com/json-iterator/go v1.1.12 // indirect
github.com/klauspost/compress v1.17.11 // indirect
github.com/klauspost/cpuid/v2 v2.2.8 // indirect
github.com/klauspost/cpuid/v2 v2.2.9 // indirect
github.com/leodido/go-urn v1.4.0 // indirect
github.com/libdns/cloudflare v0.1.1 // indirect
github.com/libdns/libdns v0.2.2 // indirect
github.com/mdlayher/genetlink v1.3.2 // indirect
github.com/mdlayher/socket v0.5.1 // indirect
github.com/mholt/acmez/v2 v2.0.3 // indirect
github.com/miekg/dns v1.1.62 // indirect
github.com/mholt/acmez/v3 v3.0.1 // indirect
github.com/miekg/dns v1.1.63 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/muhlemmer/gu v0.3.1 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
github.com/prometheus/client_golang v1.20.5 // indirect
github.com/prometheus/client_model v0.6.1 // indirect
github.com/prometheus/common v0.60.1 // indirect
github.com/prometheus/common v0.62.0 // indirect
github.com/prometheus/procfs v0.15.1 // indirect
github.com/sirupsen/logrus v1.9.3 // indirect
github.com/soheilhy/cmux v0.1.5 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/spf13/pflag v1.0.6 // indirect
github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75 // indirect
github.com/x448/float16 v0.8.4 // indirect
github.com/xiang90/probing v0.0.0-20221125231312-a49e3df8f510 // indirect
github.com/zeebo/blake3 v0.2.4 // indirect
github.com/zitadel/logging v0.6.1 // indirect
github.com/zitadel/schema v1.3.0 // indirect
go.etcd.io/bbolt v1.3.11 // indirect
go.etcd.io/etcd/client/v2 v2.305.17 // indirect
go.etcd.io/etcd/pkg/v3 v3.5.17 // indirect
go.etcd.io/etcd/raft/v3 v3.5.17 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.57.0 // indirect
go.opentelemetry.io/otel v1.32.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.32.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.32.0 // indirect
go.opentelemetry.io/otel/metric v1.32.0 // indirect
go.opentelemetry.io/otel/sdk v1.32.0 // indirect
go.opentelemetry.io/otel/trace v1.32.0 // indirect
go.opentelemetry.io/proto/otlp v1.3.1 // indirect
go.etcd.io/bbolt v1.4.0 // indirect
go.etcd.io/etcd/client/v2 v2.305.18 // indirect
go.etcd.io/etcd/pkg/v3 v3.5.18 // indirect
go.etcd.io/etcd/raft/v3 v3.5.18 // indirect
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 // indirect
go.opentelemetry.io/otel v1.34.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect
go.opentelemetry.io/otel/metric v1.34.0 // indirect
go.opentelemetry.io/otel/sdk v1.34.0 // indirect
go.opentelemetry.io/otel/trace v1.34.0 // indirect
go.opentelemetry.io/proto/otlp v1.5.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
go.uber.org/zap v1.27.0 // indirect
golang.org/x/mod v0.22.0 // indirect
golang.org/x/oauth2 v0.24.0 // indirect
golang.org/x/sync v0.9.0 // indirect
golang.org/x/text v0.20.0 // indirect
golang.org/x/time v0.8.0 // indirect
golang.org/x/tools v0.27.0 // indirect
go.uber.org/zap/exp v0.3.0 // indirect
golang.org/x/mod v0.23.0 // indirect
golang.org/x/oauth2 v0.26.0 // indirect
golang.org/x/sync v0.11.0 // indirect
golang.org/x/text v0.22.0 // indirect
golang.org/x/time v0.10.0 // indirect
golang.org/x/tools v0.29.0 // indirect
golang.zx2c4.com/wintun v0.0.0-20230126152724-0fa3db229ce2 // indirect
google.golang.org/genproto v0.0.0-20241113202542-65e8d215514f // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20241113202542-65e8d215514f // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241113202542-65e8d215514f // indirect
google.golang.org/grpc v1.68.0 // indirect
google.golang.org/protobuf v1.35.2 // indirect
google.golang.org/genproto v0.0.0-20250207221924-e9438ea467c6 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20250207221924-e9438ea467c6 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 // indirect
google.golang.org/grpc v1.70.0 // indirect
google.golang.org/protobuf v1.36.5 // indirect
gopkg.in/natefinch/lumberjack.v2 v2.2.1 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
sigs.k8s.io/yaml v1.4.0 // indirect
)

Expand Down
Loading

0 comments on commit 1febda2

Please sign in to comment.