diff --git a/airflow/docker.go b/airflow/docker.go index 862a43a4e..22ea56b42 100644 --- a/airflow/docker.go +++ b/airflow/docker.go @@ -37,8 +37,6 @@ const ( deployTagPrefix = "cli-" dockerStateUp = "Up" dockerStateExited = "Exited" - // Default user/pass for local airflow, when RBAC enabled - airflowCreateUserCmd = "airflow create_user -r Admin -u admin -e admin@example.com -f admin -l user -p admin" ) var ( diff --git a/cmd/airflow.go b/cmd/airflow.go index 0992c799e..a67742f5f 100644 --- a/cmd/airflow.go +++ b/cmd/airflow.go @@ -33,8 +33,8 @@ var ( webserverLogs bool RunExample = ` - # Create default admin user. - astro airflow run create_user -r Admin -u admin -e admin@example.com -f admin -l user -p admin +# Create default admin user. +astro airflow run create_user -r Admin -u admin -e admin@example.com -f admin -l user -p admin ` airflowRootCmd = &cobra.Command{ diff --git a/dags/example-dag.py b/dags/example-dag.py deleted file mode 100644 index 802a211d3..000000000 --- a/dags/example-dag.py +++ /dev/null @@ -1,91 +0,0 @@ -from airflow import DAG -from airflow.operators.bash_operator import BashOperator -from datetime import datetime, timedelta - -default_args = { - 'owner': 'airflow', - 'depends_on_past': False, - 'start_date': datetime(2018, 1, 1), - 'email_on_failure': False, - 'email_on_retry': False, - 'retries': 1, - 'retry_delay': timedelta(minutes=5), -} - -dag = DAG('example_dag', - max_active_runs=3, - schedule_interval=timedelta(minutes=5), - default_args=default_args) - -t1 = BashOperator( - task_id='print_date1', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t2 = BashOperator( - task_id='print_date2', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t3 = BashOperator( - task_id='print_date3', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t4 = BashOperator( - task_id='print_date4', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t5 = BashOperator( - task_id='print_date5', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t6 = BashOperator( - task_id='print_date6', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t7 = BashOperator( - task_id='print_date7', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t8 = BashOperator( - task_id='print_date8', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t2.set_upstream(t1) -t3.set_upstream(t2) -t4.set_upstream(t3) -t5.set_upstream(t3) -t6.set_upstream(t3) -t7.set_upstream(t3) -t8.set_upstream(t3) - -t9 = BashOperator( - task_id='print_date9', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t10 = BashOperator( - task_id='print_date10', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t11 = BashOperator( - task_id='print_date11', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t12 = BashOperator( - task_id='print_date12', - bash_command='sleep $[ ( $RANDOM % 30 ) + 1 ]s', - dag=dag) - -t9.set_upstream(t8) -t10.set_upstream(t8) -t11.set_upstream(t8) -t12.set_upstream(t8) \ No newline at end of file diff --git a/plugins/example-plugin.py b/plugins/example-plugin.py deleted file mode 100644 index 0d1a82220..000000000 --- a/plugins/example-plugin.py +++ /dev/null @@ -1,30 +0,0 @@ -from airflow.plugins_manager import AirflowPlugin -from flask_admin.base import MenuLink - -""" -Look for the Astronomer tab in the UI. -""" -airflow_plugins_ml = MenuLink( - category='Astronomer', - name='Airflow-Plugins', - url='https://github.com/airflow-plugins/') - -astro_docs_ml = MenuLink( - category='Astronomer', - name='Astronomer Docs', - url='https://www.astronomer.io/docs/') - -astro_guides_ml = MenuLink( - category='Astronomer', - name='Airflow Guides', - url='https://www.astronomer.io/guides/') - -class AstroLinksPlugin(AirflowPlugin): - name = 'astronomer_menu_links' - operators = [] - flask_blueprints = [] - hooks = [] - executors = [] - macros = [] - admin_views = [] - menu_links = [airflow_plugins_ml, astro_docs_ml, astro_guides_ml] \ No newline at end of file