From 86368acfac802103c420c74591e5e063b6666d34 Mon Sep 17 00:00:00 2001 From: David Newhall II Date: Mon, 27 May 2024 08:48:49 -0700 Subject: [PATCH 1/2] fix two bugs --- go.mod | 2 +- go.sum | 4 ++-- pkg/logs/logs.go | 5 +++++ 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index ca4efdbd9..a0e52e56f 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/go-ping/ping v1.1.0 github.com/go-sql-driver/mysql v1.8.1 github.com/gorilla/mux v1.8.1 - github.com/gorilla/schema v1.3.0 + github.com/gorilla/schema v1.2.1 github.com/gorilla/securecookie v1.1.2 github.com/gorilla/websocket v1.5.0 github.com/hako/durafmt v0.0.0-20210608085754-5c1018a4e16b diff --git a/go.sum b/go.sum index 191553980..5e2d69181 100644 --- a/go.sum +++ b/go.sum @@ -132,8 +132,8 @@ github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= github.com/gorilla/rpc v1.2.1 h1:yC+LMV5esttgpVvNORL/xX4jvTTEUE30UZhZ5JF7K9k= github.com/gorilla/rpc v1.2.1/go.mod h1:uNpOihAlF5xRFLuTYhfR0yfCTm0WTQSQttkMSptRfGk= -github.com/gorilla/schema v1.3.0 h1:rbciOzXAx3IB8stEFnfTwO3sYa6EWlQk79XdyustPDA= -github.com/gorilla/schema v1.3.0/go.mod h1:Dg5SSm5PV60mhF2NFaTV1xuYYj8tV8NOPRo4FggUMnM= +github.com/gorilla/schema v1.2.1 h1:tjDxcmdb+siIqkTNoV+qRH2mjYdr2hHe5MKXbp61ziM= +github.com/gorilla/schema v1.2.1/go.mod h1:Dg5SSm5PV60mhF2NFaTV1xuYYj8tV8NOPRo4FggUMnM= github.com/gorilla/securecookie v1.1.2 h1:YCIWL56dvtr73r6715mJs5ZvhtnY73hBvEF8kXD8ePA= github.com/gorilla/securecookie v1.1.2/go.mod h1:NfCASbcHqRSY+3a8tlWJwsQap2VX5pwzwo4h3eOamfo= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= diff --git a/pkg/logs/logs.go b/pkg/logs/logs.go index 2aee0d47d..8b756f03b 100644 --- a/pkg/logs/logs.go +++ b/pkg/logs/logs.go @@ -95,6 +95,11 @@ func (l *Logger) SetupLogging(config *LogConfig) { logFiles = config.LogFiles logFileMb = config.LogFileMb l.LogConfig = config + + if mnd.IsWindows { + config.Quiet = true + } + l.setDefaultLogPaths() l.setLogPaths() l.openLogFile() From 2a05ae4cbd47d3a7068492f60f94e928e9debb86 Mon Sep 17 00:00:00 2001 From: David Newhall II Date: Mon, 27 May 2024 09:24:14 -0700 Subject: [PATCH 2/2] fix docker build tags --- .github/workflows/ghcr.yml | 11 ++++++----- init/docker/{Dockerfile.scratch => Dockerfile.latest} | 0 init/docker/makedocker.sh | 2 +- settings.sh | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) rename init/docker/{Dockerfile.scratch => Dockerfile.latest} (100%) diff --git a/.github/workflows/ghcr.yml b/.github/workflows/ghcr.yml index 49993d6cb..0a039a801 100644 --- a/.github/workflows/ghcr.yml +++ b/.github/workflows/ghcr.yml @@ -13,7 +13,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - docker: [ {name: 'scratch', sfx: ''}, {name: 'cuda', sfx: '-cuda'}, {name: 'alpine', sfx: '-alpine'} ] + docker: [ {name: 'latest', sfx: ''}, {name: 'cuda', sfx: '-cuda'}, {name: 'alpine', sfx: '-alpine'} ] permissions: contents: read packages: write @@ -60,10 +60,11 @@ jobs: with: images: ghcr.io/${{ github.repository }} tags: | - type=semver,pattern=v{{version}}${{ matrix.docker.sfx }} - type=semver,pattern={{version}}${{ matrix.docker.sfx }} - type=semver,pattern={{major}}.{{minor}}${{ matrix.docker.sfx }} - type=semver,pattern={{major}}${{ matrix.docker.sfx }} + type=semver,priority=1010,pattern=${{ matrix.docker.name }} + type=semver,priority=1009,pattern={{major}}${{ matrix.docker.sfx }} + type=semver,priority=1008,pattern={{major}}.{{minor}}${{ matrix.docker.sfx }} + type=semver,priority=1007,pattern={{version}}${{ matrix.docker.sfx }} + type=semver,priority=1006,pattern=v{{version}}${{ matrix.docker.sfx }} type=ref,enable=true,event=branch,suffix=${{ matrix.docker.sfx }} # Build and push Docker image with Buildx diff --git a/init/docker/Dockerfile.scratch b/init/docker/Dockerfile.latest similarity index 100% rename from init/docker/Dockerfile.scratch rename to init/docker/Dockerfile.latest diff --git a/init/docker/makedocker.sh b/init/docker/makedocker.sh index 4a3f2938f..7c58ef1de 100755 --- a/init/docker/makedocker.sh +++ b/init/docker/makedocker.sh @@ -17,4 +17,4 @@ docker buildx build --load --pull --tag notifiarr \ --build-arg "VENDOR=${VENDOR}" \ --build-arg "AUTHOR=${MAINT}" \ --build-arg "SOURCE_URL=${SOURCE_URL}" \ - --file init/docker/Dockerfile.scratch . + --file init/docker/Dockerfile.latest . diff --git a/settings.sh b/settings.sh index a768e919b..6cece1c54 100644 --- a/settings.sh +++ b/settings.sh @@ -29,4 +29,4 @@ fi [ -n "$DOCKER_TAG" ] || export DOCKER_TAG=$(echo $SOURCE_BRANCH | sed 's/^v*\([0-9].*\)/\1/') [ -n "$DOCKER_REPO" ] || export DOCKER_REPO="golift/notifiarr" [ -n "$IMAGE_NAME" ] || export IMAGE_NAME="${DOCKER_REPO}:${DOCKER_TAG}" -[ -n "$DOCKERFILE_PATH" ] || export DOCKERFILE_PATH="init/docker/Dockerfile.scratch" +[ -n "$DOCKERFILE_PATH" ] || export DOCKERFILE_PATH="init/docker/Dockerfile.latest"