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

💥 [DevOps] Authentik: Change script to have sql dump #888

Closed
5 tasks
Elweyn opened this issue May 17, 2024 · 0 comments · Fixed by #1373
Closed
5 tasks

💥 [DevOps] Authentik: Change script to have sql dump #888

Elweyn opened this issue May 17, 2024 · 0 comments · Fixed by #1373

Comments

@Elweyn
Copy link
Member

Elweyn commented May 17, 2024

💥 DevOps

As reviewer I want to see the changes on the database in a file and not a a binary file.

  • Application and provider export script
  • Flow and stages export script
  • System export script

🤖 ToDo

  • Change binary dump to sql dump
    • Application and provider
    • Flow and stages
    • System export
  • Add .env to add local, stage or live url
@Elweyn Elweyn self-assigned this May 22, 2024
roschaefer added a commit that referenced this issue Jul 8, 2024
Motivation
----------
This will implement seed data as SQL dumps.

I updated the `README.md` for instructions.

As another benefit you can now `docker compose down -v` to wipe out
authentik and start fresh.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 8, 2024
Motivation
----------
This will implement seed data as SQL dumps.

I updated the `README.md` for instructions.

As another benefit you can now `docker compose down -v` to wipe out
authentik and start fresh.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 9, 2024
Motivation
----------
This will implement seed data as SQL dumps.

I updated the `README.md` for instructions.

As another benefit you can now `docker compose down -v` to wipe out
authentik and start fresh.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 10, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 10, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 10, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 11, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 11, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 11, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
roschaefer added a commit that referenced this issue Jul 12, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
@Elweyn Elweyn removed their assignment Jul 16, 2024
roschaefer added a commit that referenced this issue Jul 16, 2024
Motivation
----------
See #888 - we want to be able to see the plaintext seeds and we want to
see the delta between versions when the seeds change.

This will implement seed data as SQL dumps. I created the dump by
executing the `unpack` script on `master` and `pg_dump` from within the
docker container.

The `README.md` now contains instructions how to update the seeds and
how to restore the seeds dump.

Unfortunately it is not possible to only dump certain tables with
`pg_dump --table <table_name>` because there are foreign key constraints
which `pg_dump` is not able to resolve.

Side quest of this PR:
* `docker compose down -v` to wipes out the authentik database for
  a clean start
* no more permission denied errors because the docker user (running as
  `root`) created the `authentik/database/` bound volume.

How to test
-----------
1. Follow the README

close #888
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ✅ Done
Development

Successfully merging a pull request may close this issue.

2 participants