Compare commits

...

7 Commits

9 changed files with 27 additions and 24 deletions

View File

@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.7.11-beta
current_version = 0.7.12-beta
tag = True
commit = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)\-(?P<release>.*)

View File

@ -16,11 +16,11 @@ jobs:
- name: Building Docker Image
run: docker build
--no-cache
-t beryju/passbook:0.7.11-beta
-t beryju/passbook:0.7.12-beta
-t beryju/passbook:latest
-f Dockerfile .
- name: Push Docker Container to Registry (versioned)
run: docker push beryju/passbook:0.7.11-beta
run: docker push beryju/passbook:0.7.12-beta
- name: Push Docker Container to Registry (latest)
run: docker push beryju/passbook:latest
build-gatekeeper:
@ -33,13 +33,15 @@ jobs:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
run: docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD
- name: Building Docker Image
run: docker build
--no-cache
-t beryju/passbook-gatekeeper:0.7.11-beta
-t beryju/passbook-gatekeeper:latest
-f Dockerfile gatekeeper/
run: |
cd gatekeeper
docker build \
--no-cache \
-t beryju/passbook-gatekeeper:0.7.12-beta \
-t beryju/passbook-gatekeeper:latest \
-f Dockerfile .
- name: Push Docker Container to Registry (versioned)
run: docker push beryju/passbook-gatekeeper:0.7.11-beta
run: docker push beryju/passbook-gatekeeper:0.7.12-beta
- name: Push Docker Container to Registry (latest)
run: docker push beryju/passbook-gatekeeper:latest
build-static:
@ -64,11 +66,11 @@ jobs:
run: docker build
--no-cache
--network=$(docker network ls | grep github | awk '{print $1}')
-t beryju/passbook-static:0.7.11-beta
-t beryju/passbook-static:0.7.12-beta
-t beryju/passbook-static:latest
-f static.Dockerfile .
- name: Push Docker Container to Registry (versioned)
run: docker push beryju/passbook-static:0.7.11-beta
run: docker push beryju/passbook-static:0.7.12-beta
- name: Push Docker Container to Registry (latest)
run: docker push beryju/passbook-static:latest
test-release:

View File

@ -1,5 +1,7 @@
# passbook
![](https://github.com/BeryJu/passbook/workflows/passbook-ci/badge.svg)
## Quick instance
```

View File

@ -1,6 +1,6 @@
apiVersion: v1
appVersion: "0.7.11-beta"
appVersion: "0.7.12-beta"
description: A Helm chart for passbook.
name: passbook
version: "0.7.11-beta"
version: "0.7.12-beta"
icon: https://git.beryju.org/uploads/-/system/project/avatar/108/logo.png

View File

@ -2,7 +2,7 @@
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.
image:
tag: 0.7.11-beta
tag: 0.7.12-beta
nameOverride: ""

View File

@ -1,2 +1,2 @@
"""passbook"""
__version__ = "0.7.11-beta"
__version__ = "0.7.12-beta"

View File

@ -16,8 +16,8 @@ class ApplicationGatewayProviderForm(forms.ModelForm):
client_id=generate_client_id(), client_secret=generate_client_secret()
)
self.instance.client.name = self.instance.name
self.instance.client.response_types = ResponseType.objects.get_by_natural_key(
"code"
self.instance.client.response_types.set(
[ResponseType.objects.get_by_natural_key("code")]
)
self.instance.client.redirect_uris = [
f"http://{self.instance.external_host}/oauth2/callback",

View File

@ -2,14 +2,14 @@
from typing import Optional
from django.contrib import messages
from django.db.models.deletion import Collector
from django.http import HttpRequest, HttpResponse
from django.shortcuts import redirect
from oidc_provider.models import Client
from structlog import get_logger
from django.db.models.deletion import Collector
from passbook.audit.models import Event, EventAction
from passbook.core.models import Application, User, Provider
from passbook.core.models import Application, Provider, User
from passbook.policies.engine import PolicyEngine
LOGGER = get_logger()
@ -31,7 +31,7 @@ def check_permissions(
for _, related in collector.data.items():
related_object = next(iter(related))
if isinstance(related_object, Provider):
application = related.application
application = related_object.application
break
except Application.DoesNotExist:
return redirect("passbook_providers_oauth:oauth2-permission-denied")

View File

@ -34,8 +34,7 @@ ENV PASSBOOK_POSTGRESQL__USER=passbook
ENV PASSBOOK_POSTGRESQL__PASSWORD="EK-5jnKfjrGRm<77"
RUN ./manage.py collectstatic --no-input
FROM docker.beryju.org/pixie/server
FROM beryju/pixie:latest
COPY --from=static-build /app/static /data/static/
COPY --from=static-build /app/static/robots.txt /data/robots.txt
WORKDIR /data
COPY --from=static-build /app/static /web-root/static/
COPY --from=static-build /app/static/robots.txt /web-root/robots.txt