Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker compose broken? #287

Closed
gabrielesilinic opened this issue Dec 12, 2023 · 3 comments
Closed

Docker compose broken? #287

gabrielesilinic opened this issue Dec 12, 2023 · 3 comments

Comments

@gabrielesilinic
Copy link

gabrielesilinic commented Dec 12, 2023

do you people have any clue about what is going on here? how is everything supposed to be?

here the log when docker compose up gets run on WSL (ubuntu, latest version)

$ docker compose up
[+] Running 4/0
 ✔ Container spid-cie-oidc-django-wallet.trust-anchor.org-1  Created                                                                       0.0s
 ✔ Container spid-cie-oidc-django-trust-anchor.org-1         Created                                                                       0.0s
 ✔ Container spid-cie-oidc-django-relying-party.org-1        Created                                                                       0.0s
 ✔ Container spid-cie-oidc-django-cie-provider.org-1         Created                                                                       0.0s
Attaching to spid-cie-oidc-django-cie-provider.org-1, spid-cie-oidc-django-relying-party.org-1, spid-cie-oidc-django-trust-anchor.org-1, spid-cie-oidc-django-wallet.trust-anchor.org-1
spid-cie-oidc-django-trust-anchor.org-1         | python3: can't open file '/django-project/manage.py': [Errno 2] No such file or directory
spid-cie-oidc-django-wallet.trust-anchor.org-1  | python3: can't open file '/django-project/manage.py': [Errno 2] No such file or directory
spid-cie-oidc-django-wallet.trust-anchor.org-1 exited with code 2
spid-cie-oidc-django-cie-provider.org-1         | python3: can't open file '/django-project/manage.py': [Errno 2] No such file or directory
spid-cie-oidc-django-trust-anchor.org-1 exited with code 2
spid-cie-oidc-django-relying-party.org-1        | python3: can't open file '/django-project/manage.py': [Errno 2] No such file or directory
spid-cie-oidc-django-cie-provider.org-1 exited with code 2
spid-cie-oidc-django-relying-party.org-1 exited with code 2

i also tried to uncomment the lines inside the docker-compose file so it would build directly from the current version but even that did not work, i am working on main at the latest commit (I did a git reset) 2b0c2ef Merge pull request #285 from vernans/add-migrations

also i do lack a localsettings.py but the thing is that i also don't know it's supposed path or format and i also don't really need to customize anything for now (I hoped the docker compose would just run, or at least warn me about the lack of an .env file)

Status

update1: apparently you wanted the developer to copy-paste the examples directory and rename it as examples-docker? why would you do that? still broken but at least know i know that it wants the configuration file

update2: maybe having to configure the image using entire files was not really the reason they invented docker in the first place, i hope i will be able to figure out how to fix it and if i will have the time i will try to introduce good defaults, also the .env file can be useful.

update3: now it decided that it won't parse the records in the json files, cool django.core.serializers.base.DeserializationError: Problem installing fixture '/django-project/dumps/example.json':

update4: okay, so, since for some reason the restoring of the dump is likely just incompatible with whatever models django currently migrates the db to i just replaced all files with a json containing an empty array like this [], now the fun part is figuring out why every page the readme said existed just returns error 404, the Django admin page does that as well.

update5: so, turns out that Django is set up to be sensitive to the last slash / in the URL, and the thing is that you won't ever know when it wants one or when it does not

@rglauco
Copy link
Collaborator

rglauco commented Dec 12, 2023

A new Docker image has been released, and the migrations will apply correctly now. Please try again (NB delete the previous docker image, the examples-docker folder, and restart the docker-prepare.sh script).

@rglauco
Copy link
Collaborator

rglauco commented Dec 12, 2023

Thank you for spotting the issue, the default usernames are:
admin/oidcadmin
user/oidcuser

@gabrielesilinic
Copy link
Author

@rglauco thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants