Skip to content

Comments

Breeze start-airflow command wasn't able to initialize the db in 1.10.x#11207

Merged
potiuk merged 4 commits intoapache:masterfrom
francescomucio:master
Oct 6, 2020
Merged

Breeze start-airflow command wasn't able to initialize the db in 1.10.x#11207
potiuk merged 4 commits intoapache:masterfrom
francescomucio:master

Conversation

@francescomucio
Copy link
Contributor

The database initialization needs a different cli command (the old initdb).

Also it is not necessary to create a dummy user in version 1.10.x to allow people to login in the Web UI.


^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code change, Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in UPDATING.md.

airflow initdb
else
airflow db init
airflow users create -u admin -p admin -f Thor -l Adminstra -r Admin -e dummy@dummy.email
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
airflow users create -u admin -p admin -f Thor -l Adminstra -r Admin -e dummy@dummy.email
airflow users create -u admin -p admin -f Thor -l Adminstra -r Admin -e dummy@dummy.email || true

This will help in case of no RBAC.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually that line is only for version 2 onward, but it gave me an idea to include create_user also for the RBAC setup. See my next commit.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@potiuk there won't be any RBAC option in 2.0 anymore, right?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ther won't be indeed. But we are still able to install 1.10 in the ./breeze from 2.0 (for convenience) via --install-airflow-version . So we should add this option just for that case. I am going to do it shortly.

airflow initdb
else
airflow db init
airflow users create -u admin -p admin -f Thor -l Adminstra -r Admin -e dummy@dummy.email
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ther won't be indeed. But we are still able to install 1.10 in the ./breeze from 2.0 (for convenience) via --install-airflow-version . So we should add this option just for that case. I am going to do it shortly.

@potiuk potiuk merged commit 03e0ff2 into apache:master Oct 6, 2020
@potiuk potiuk added this to the Airflow 1.10.13 milestone Oct 11, 2020
potiuk pushed a commit that referenced this pull request Oct 11, 2020
RaviTezu pushed a commit to RaviTezu/airflow that referenced this pull request Oct 25, 2020
kaxil pushed a commit that referenced this pull request Nov 12, 2020
@potiuk potiuk added the type:misc/internal Changelog: Misc changes that should appear in change log label Nov 14, 2020
potiuk pushed a commit that referenced this pull request Nov 16, 2020
kaxil pushed a commit that referenced this pull request Nov 18, 2020
cfei18 pushed a commit to cfei18/incubator-airflow that referenced this pull request Mar 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:dev-tools type:misc/internal Changelog: Misc changes that should appear in change log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants