adamant-refrigerator-93887
05/31/2024, 6:17 AMchilly-king-10285
05/31/2024, 6:17 AMchilly-king-10285
05/31/2024, 6:17 AMadamant-refrigerator-93887
05/31/2024, 6:56 AMdocker pull oryd/kratos:<version-you-want>
docker run --rm -it oryd/kratos:<version-you-want> help
chilly-king-10285
05/31/2024, 6:56 AMchilly-king-10285
05/31/2024, 6:56 AM<version-you-want>
placeholder in the commands should be replaced with the actual version of Ory Kratos that you want to pull and run. For example, if you want to pull and run version v0.7.6-alpha.1
, the commands would be: bash docker pull oryd/kratos:v0.7.6-alpha.1 docker run --rm -it oryd/kratos:v0.7.6-alpha.1 help
Please replace v0.7.6-alpha.1
with the actual version you intend to use. You can find the available versions on the [Ory Kratos Docker Hub page](https://hub.docker.com/r/oryd/kratos/tags). If you're still having issues, could you please provide the error message you're seeing? That will help me understand the problem better.adamant-refrigerator-93887
05/31/2024, 7:00 AMchilly-king-10285
05/31/2024, 7:00 AMchilly-king-10285
05/31/2024, 7:00 AMbash git clone <https://github.com/ory/kratos.git>
2. Navigate to the cloned repository: bash cd kratos
3. Checkout to the master branch: bash git checkout master
4. Run the Docker Compose command: bash docker-compose -f quickstart.yml -f quickstart-standalone.yml up --build --force-recreate
If you have SELinux, run: bash docker-compose -f quickstart.yml -f quickstart-selinux.yml -f quickstart-standalone.yml up --build --force-recreate
This process might take a minute or two. Once the output slows down and logs indicate a healthy system, you're ready to go! A healthy system will show something along the lines of: bash kratos_1 | time="2020-01-20T14:52:13Z" level=info msg="Starting the admin httpd on: 0.0.0.0:4434" kratos_1 | time="2020-01-20T14:52:13Z" level=info msg="Starting the public httpd on: 0.0.0.0:4433"
(Source: [Clone Ory Kratos and run it in Docker](https://www.ory.sh/docs/kratos/quickstart#clone-ory-kratos-and-run-it-in-docker)) Please note that you need to make sure that ports 4455
, 4433
, 4434
, and 4436
are free and always use 127.0.0.1
as the hostname; never use localhost
. This is important because browsers treat these two as separate domains and will therefore have issues with setting and using cookies. (Source: [Clone Ory Kratos and run it in Docker Part 2](https://www.ory.sh/docs/kratos/quickstart#clone-ory-kratos-and-run-it-in-docker))adamant-refrigerator-93887
05/31/2024, 7:11 AMchilly-king-10285
05/31/2024, 7:11 AMchilly-king-10285
05/31/2024, 7:12 AMtemplates
property under courier.smtp
. The templates
property should be at the same level as smtp
under courier
, not nested within smtp
. Here's how your configuration should look: yaml courier: smtp: connection_uri: <smtps://test:test@mailslurper:1025/?skip_ssl_verify=true> from_name: MyProject via Ory templates: recovery: invalid: email: body: html: "<base64://SGksIHBsZWFzZSByZWNvdmVyIGFjY2VzcyB0byB5b3VyIGFjY291bnQgYnkgZW5>>0ZXJpbmcgdGhlIGZvbGxvd2luZyBjb2RlOnt7LlJlY292ZXJ5Q29kZX19Cgo8YSBocmVmPSJ7eyAuUmVjb3ZlcnlDb2RlIH19Ij57eyAuUmVjb3ZlcnlDb2RlIH19PC9hPg==" plaintext: "<base64://SGksIHBsZWFzZSByZWNvdmVyIGFjY2VzcyB0byB5b3VyIGFjY291bnQgYnkgZW5>>0ZXJpbmcgdGhlIGZvbGxvd2luZyBjb2RlOnt7LlJlY292ZXJ5Q29kZX19Cg==" valid: email: body: html: "<base64://SGVsbG8sIHRoaXMgaXMgYSB2YWxpZCByZWNvdmVyeSBjb2RlIGVtYWlsLg>>==" plaintext: "<base64://SGVsbG8sIHRoaXMgaXMgYSB2YWxpZCByZWNvdmVyeSBjb2RlIGVtYWlsLg>>=="
Please adjust your configuration accordingly and try restarting your Kratos container. (Source: [Custom Email Templates](https://www.ory.sh/docs/kratos/emails-sms/custom-email-templates#using-custom-message-templates))adamant-refrigerator-93887
05/31/2024, 7:24 AMchilly-king-10285
05/31/2024, 7:24 AMchilly-king-10285
05/31/2024, 7:24 AMadamant-refrigerator-93887
05/31/2024, 7:26 AMchilly-king-10285
05/31/2024, 7:26 AMchilly-king-10285
05/31/2024, 7:26 AMbase64://
prefix should not be inside the quotation marks, and there should not be any <>
characters around the base64 string. Here's how your configuration should look: yaml email: body: html: <base64://SGksIHBsZWFzZSByZWNvdmVyIGFjY2VzcyB0byB5b3VyIGFjY291bnQgYnkgZW50ZXJpbmcgdGhlIGZvbGxvd2luZyBjb2RlOnt7LlJlY292ZXJ5Q29kZX19Cgo8YSBocmVmPSJ7eyAuUmVjb3ZlcnlDb2RlIH19Ij57eyAuUmVjb3ZlcnlDb2RlIH19PC9hPg>== plaintext: <base64://SGksIHBsZWFzZSByZWNvdmVyIGFjY2VzcyB0byB5b3VyIGFjY291bnQgYnkgZW50ZXJpbmcgdGhlIGZvbGxvd2luZyBjb2RlOnt7LlJlY292ZXJ5Q29kZX19Cg>==
Also, make sure that the base64 strings are valid. You can use an online tool like [base64decode.net](https://www.base64decode.net/base64-decoder) to decode the base64 strings and check if the decoded text is what you expect. If you're still having issues, please provide more details about the error message you're seeing.adamant-refrigerator-93887
05/31/2024, 7:39 AMdocker run --rm -it oryd/kratos:<version-you-want>
by runnning this i got error
The configuration contains values or keys which are invalid:
The configuration contains values or keys which are invalid:
dsn: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
identity.schemas: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
selfservice.default_browser_return_url: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
courier.smtp.connection_uri: <nil>
^-- one or more required properties are missing
ERRO[2024-05-31T193812Z] Unable to instantiate configuration. audience=application error=map[message:I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"] service_name=Ory Kratos service_version=v1.1.0
Error: I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"
Usage:
kratos serve [flags]
Flags:
-c, --config strings Path to one or more .json, .yaml, .yml, .toml config files. Values are loaded in the order provided, meaning that the last config file overwrites values from the previous config file.
--dev Disables critical security features to make development easier
-h, --help help for serve
--sqa-opt-out Disable anonymized telemetry reports - for more information please visit https://www.ory.sh/docs/ecosystem/sqa
--watch-courier Run the message courier as a background task, to simplify single-instance setup
I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"adamant-refrigerator-93887
05/31/2024, 7:41 AMdocker run --rm -it oryd/kratos:<version-you-want>
by runnning this i got error
The configuration contains values or keys which are invalid:
The configuration contains values or keys which are invalid:
dsn: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
identity.schemas: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
selfservice.default_browser_return_url: <nil>
^-- one or more required properties are missing
The configuration contains values or keys which are invalid:
courier.smtp.connection_uri: <nil>
^-- one or more required properties are missing
ERRO[2024-05-31T193812Z] Unable to instantiate configuration. audience=application error=map[message:I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"] service_name=Ory Kratos service_version=v1.1.0
Error: I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"
Usage:
kratos serve [flags]
Flags:
-c, --config strings Path to one or more .json, .yaml, .yml, .toml config files. Values are loaded in the order provided, meaning that the last config file overwrites values from the previous config file.
--dev Disables critical security features to make development easier
-h, --help help for serve
--sqa-opt-out Disable anonymized telemetry reports - for more information please visit https://www.ory.sh/docs/ecosystem/sqa
--watch-courier Run the message courier as a background task, to simplify single-instance setup
I[#] S[#] validation failed
I[#] S[#/required] missing properties: "dsn"
I[#/identity] S[#/properties/identity/required] missing properties: "schemas"
I[#/selfservice] S[#/properties/selfservice/required] missing properties: "default_browser_return_url"
I[#/courier/smtp] S[#/properties/courier/properties/smtp/required] missing properties: "connection_uri"
@chilly-king-10285chilly-king-10285
05/31/2024, 7:41 AMchilly-king-10285
05/31/2024, 7:41 AMbash docker run -e DSN="your_database_URL" oryd/kratos:<version-you-want>
(Source: [Using the images](https://www.ory.sh/docs/kratos/guides/docker#using-the-images)) - `identity.schemas`: This is required for defining the identity data model and validation. You need to provide a path to your identity schema files in your configuration. - `selfservice.default_browser_return_url`: This is the default return-to URL for browser flows. You need to provide a valid URL in your configuration. - `courier.smtp.connection_uri`: This is the connection URI for the SMTP server used for sending out emails. You need to provide a valid SMTP connection URI in your configuration. You need to provide these values in your configuration file or through environment variables. If you're using a configuration file, you can specify the path to the config file via the --config
flag when running the Docker command: bash docker run --config /path/to/your/config/file oryd/kratos:<version-you-want>
(Source: [Configuration file](https://www.ory.sh/docs/kratos/configuring#configuration-file)) If you're still having issues, please provide more details about your setup and configuration.adamant-refrigerator-93887
05/31/2024, 7:47 AMchilly-king-10285
05/31/2024, 7:47 AMchilly-king-10285
05/31/2024, 7:47 AMkratos.yml
configuration file, you need to make sure that the Docker container has access to this file. You can do this by mounting the directory containing the configuration file as a volume in the Docker container. Here's an example of how to do this: bash docker run -v /path/to/your/config/directory:/etc/config/ oryd/kratos:<version-you-want> serve -c /etc/config/kratos.yml
In this command, /path/to/your/config/directory
should be replaced with the path to the directory on your host system that contains the kratos.yml
file. This directory is mounted as /etc/config/
in the Docker container. The -c /etc/config/kratos.yml
option tells Kratos to use /etc/config/kratos.yml
as the configuration file. If you're still having issues, please double-check that the paths and values in your configuration file are correct. If everything seems to be in order, you might want to consider reaching out to the Ory community or the Ory team for more help. They have a [Slack channel](https://slack.ory.sh/) and a [forum](https://community.ory.sh/) where you can ask for help.adamant-refrigerator-93887
05/31/2024, 7:54 AMchilly-king-10285
05/31/2024, 7:54 AMchilly-king-10285
05/31/2024, 7:55 AMkratos.yml
configuration file at the specified path (/etc/config/kratos.yml
). This could be due to a few reasons: 1. The kratos.yml
file does not exist at the specified location on your host system. 2. The path to the kratos.yml
file is incorrect. 3. The Docker container does not have the correct permissions to access the kratos.yml
file. Here's how you can troubleshoot this issue: 1. Check that the kratos.yml
file exists at the specified location on your host system. You can do this by running the command ls /path/to/your/config/directory
in your terminal. Replace /path/to/your/config/directory
with the actual path to the directory that contains your kratos.yml
file. 2. Make sure that you're mounting the directory that contains the kratos.yml
file as a volume in the Docker container. Here's an example of how to do this: bash docker run -v /path/to/your/config/directory:/home/ory/ oryd/kratos:<version-you-want> serve --config /home/ory/kratos.yml
In this command, replace /path/to/your/config/directory
with the actual path to the directory on your host system that contains the kratos.yml
file. This directory is mounted as /home/ory/
in the Docker container. The --config /home/ory/kratos.yml
option tells Kratos to use /home/ory/kratos.yml
as the configuration file. 3. If you're still having issues, check the permissions of the kratos.yml
file and its parent directory. The Docker container needs to have read access to the file and execute access to the directory. You can change the permissions using the chmod
and chown
commands. If you're still having issues after trying these steps, please provide more details about your setup and configuration. (Source: [Binding configuration directory](https://www.ory.sh/docs/kratos/guides/docker#binding-configuration-directory))adamant-refrigerator-93887
05/31/2024, 8:03 AMchilly-king-10285
05/31/2024, 8:03 AMchilly-king-10285
05/31/2024, 8:03 AMkratos.yml
file is located in the contrib/quickstart/kratos/email-password/
directory, you can run the following Docker command: bash docker run -v $(pwd)/contrib/quickstart/kratos/email-password:/home/ory/ oryd/kratos:<version-you-want> serve --config /home/ory/kratos.yml
In this command, $(pwd)/contrib/quickstart/kratos/email-password
is the absolute path to the directory on your host system that contains the kratos.yml
file. This directory is mounted as /home/ory/
in the Docker container. The --config /home/ory/kratos.yml
option tells Kratos to use /home/ory/kratos.yml
as the configuration file. Please replace <version-you-want>
with the version of the Ory Kratos Docker image that you want to use. (Source: [Binding configuration directory](https://www.ory.sh/docs/kratos/guides/docker#binding-configuration-directory))adamant-refrigerator-93887
05/31/2024, 8:04 AMchilly-king-10285
05/31/2024, 8:04 AMchilly-king-10285
05/31/2024, 8:05 AM<version-you-want>
with the actual version of the Ory Kratos Docker image that you want to use. Here's an example of how to do this: bash docker run -v $(pwd)/contrib/quickstart/kratos/email-password:/home/ory/ oryd/kratos:v0.7.6-alpha.1 serve --config /home/ory/kratos.yml
In this command, v0.7.6-alpha.1
is the version of the Ory Kratos Docker image. Please replace it with the version that you want to use. If you're still having issues, please provide the exact Docker command that you're trying to run.adamant-refrigerator-93887
05/31/2024, 8:06 AMchilly-king-10285
05/31/2024, 8:06 AMchilly-king-10285
05/31/2024, 8:07 AMrepository:tag
. For example, oryd/kratos:v0.7.6-alpha.1
. 2. Make sure that the Docker image name and tag are correct. You can check the available tags for the Ory Kratos Docker image on the [Docker Hub page for Ory Kratos](https://hub.docker.com/r/oryd/kratos/tags). 3. If you're running the Docker command in a script, make sure that there are no hidden characters or line breaks that could be causing issues. If you're still having issues, please provide the exact Docker command that you're trying to run.adamant-refrigerator-93887
05/31/2024, 8:09 AMdocker run -v $(pwd)/contrib/quickstart/kratos/email-password:/home/ory/ oryd/kratos:v0.7.6-alpha.1 serve --config /home/ory/kratos.ym
here is the command i am running @chilly-king-10285chilly-king-10285
05/31/2024, 8:09 AMchilly-king-10285
05/31/2024, 8:10 AMkratos.yml
, not kratos.ym
. Here's the corrected command: bash docker run -v $(pwd)/contrib/quickstart/kratos/email-password:/home/ory/ oryd/kratos:v0.7.6-alpha.1 serve --config /home/ory/kratos.yml
This command mounts your local directory contrib/quickstart/kratos/email-password
(which contains your kratos.yml
file) to the /home/ory/
directory in the Docker container. It then tells Kratos to use /home/ory/kratos.yml
as the configuration file. Please replace v0.7.6-alpha.1
with the version of the Ory Kratos Docker image that you want to use. (Source: [Binding configuration directory](https://www.ory.sh/docs/kratos/guides/docker#binding-configuration-directory))adamant-refrigerator-93887
05/31/2024, 9:33 AMchilly-king-10285
05/31/2024, 9:33 AMchilly-king-10285
05/31/2024, 9:33 AMkratos.yml
configuration file and restart the Docker container. The [Ory Kratos documentation](https://www.ory.sh/docs/kratos/) provides detailed information about all the available configuration options. 3. Deploy your setup: If you're ready to move to a production environment, you'll need to deploy your setup. This typically involves setting up a database, configuring a reverse proxy, and possibly setting up other Ory components like Ory Hydra for OAuth 2.0 and OpenID Connect capabilities. The [Ory Kratos guides](https://www.ory.sh/docs/kratos/guides/) provide detailed instructions for various deployment scenarios. Remember, if you encounter any issues or have any questions, you can always refer to the [Ory documentation](https://www.ory.sh/docs/), or ask for help in the [Ory community forum](https://community.ory.sh/) or [Slack channel](https://slack.ory.sh/).adamant-refrigerator-93887
05/31/2024, 9:34 AMchilly-king-10285
05/31/2024, 9:34 AMchilly-king-10285
05/31/2024, 9:34 AMdocker run
command. You can list all running Docker containers by using the docker ps
command in your terminal. If you want to see all containers, not just the running ones, you can use the docker ps -a
command. If the Ory Kratos container is not listed, it means that the container is not running. You might want to check the output of the docker run
command for any error messages. If the container exited immediately after starting, there might be an issue with your configuration or the Docker image. If you're still having issues, please provide more details about the commands you're running and any output or error messages you're seeing.