hi there! i am using kratos helm chart and cloned...
# ory-selfhosting
l
hi there! i am using kratos helm chart and cloned kratos-selfservice-node-ui(ory) on 127.0.0.1:3000 with KRATOS_PUBLIC_URL = 127.0.0.1:4000. and using kubectl prot-forward $POD_NAME 4000:4434 and now problem is that :- • when i click on signup it redirect to right form ui but when i click submit it actually submit to "https://$POD_NAME:4434/self-service/......" • here is my config file
Copy code
config:
        # ciphers:
        #   algorithm: aes
        dsn: "postgres://<user>:<pass>@host.minikube.internal:5432/<db>"
        selfservice:
            default_browser_return_url: <http://127.0.0.1:3000/>
            methods:
                password:
                    enabled: true
            flows:
                login:
                    ui_url: <http://127.0.0.1:3000/login>
                registration:
                    ui_url: <http://127.0.0.1:3000/registration>
                error:
                    ui_url: <http://127.0.0.1:3000/error>
        log:
            level: debug

        secrets:
            default:
                - PLEASE-CHANGE-ME-I-AM-VERY-INSECURE
                - "OG5XbmxXa3dYeGplQXpQanYxeEFuRUFa"
                - "foo bar 123 456 lorem"
                - "foo bar 123 456 lorem 1"
                - "foo bar 123 456 lorem 2"
                - "foo bar 123 456 lorem 3"
        hashers:
            argon2:
                parallelism: 1
                memory: 128MB
                iterations: 2
                salt_length: 16
                key_length: 16
        identity:
            default_schema_id: default
            schemas:
                - id: default
                  url: file:///etc/config/identity.default.schema.json
        courier:
            smtp:
                connection_uri: <smtps://mailhog:1025>
w
Hi there, if your UI app is outside of k8s and kratos is inside, and you connect to it via localhost, then you probably have some misconfig on the ui app level, which would use kratos service/pod name and not the url on which it is active-localhost
l
hi demon, after all these things not working on locally. i am now trying everything on domain associated with ingress ( both ory official helm chats -kratos-nodeui & kratos chart both) hosted on same domain and i ended up loop redirection, is your official node-ui example correct or that one have some issues? and kratos DSN (db connection) not working my db is hosted on aws postgres and the same connection uri working with other apps but when i logs the kratos pod - it says unable to connect to host =... databse = ... etc.
thnaks for your reply demon
but firstly when everything was running locally then my db connection (local postges) working fine. i know you will tell me to check db url carefully but i tried almost 20 times and i am pretty sure it's not working.
w
reagrind kratos <-> ui connection, as a base take a look at the docker-compose example https://github.com/ory/kratos/blob/master/quickstart.yml#L22-L23= in this case
kratos
would be the internal k8s network like
kratos-service.namespace.svc.cluster.local
and localhost would be the external domain name of your ingress
regarding db connection, i have no way of checking your connection to AWS, as is depends on where your app is (k8s on what provider, is it public? can the pod call and resolve external addresses?) and about the provider (do you need some keys? allowlist or vpc pairings?
l
thanks i will checkout everything and try to make another db and connect it.
hi demon Thanks you were right it was some provider network outbound problem. now past db error is gone but actually it changed into ->"Unable to determine network, retrying. audience=application error=map[debug: message:Unable to locate the table reason: stack_trace" <- this one message