Easily deploy Airflow for local development
Project description
Dockflow CLI
This package requires docker to be installed and running on your machine.
Getting started
-
Install dockflow:
1.1.git clone https://gitlab.com/spatialedge/public/dockflow
1.2.cd dockflow
1.3.pip install .
-
Authenticate docker to pull from private GCR repository:
2.1. First make sure that yourgcloud
is authenticated.
2.2. Ensure you are in the correct project usinggcloud config set project <project name>
2.3. Usegcloud auth configure-docker
to auth docker to pull from private container repo.
Quickstart
- Ensure that your docker file sharing settings allows access to your development directory.
- Navigate to the root directory of your
dags
folder. - Use
dockflow config
and enter your container repo url excluding the version.- This will save the url in a config file.
- Eg.
gcr.io/<project>/<container>
- This should only be used if the container repo changes.
- If the image version tag is not
composer-1.10.6-airflow-1.10.6
specify the tag usingdockflow start -iv <version>
- Use
dockflow start
(This will mount the dag folder and start Airflow). - Use the UI to add connections.
- Admin -> Connections -> Create
- Use
dockflow refresh
to refresh the configs cache or to bundle configs. - Remember to use
dockflow stop
to shut down the instance to save local machine resources.- The state will be persisted in the same directory as the
dags
folder.
- The state will be persisted in the same directory as the
- To stop and remove the container use
dockflow stop --rm
Available composer versions
- composer-1.10.6-airflow-1.10.6 (default)
- composer-1.7.2-airflow-1.10.2
CloudSQL Proxy
docker run -d \
-v <PATH_TO_KEY_FILE>:/config \
-p 127.0.0.1:5432:5432 \
--network='dockflow' \
--name='cloudsql' \
gcr.io/cloudsql-docker/gce-proxy:1.17 /cloud_sql_proxy \
-instances=<INSTANCE_CONNECTION_NAME>=tcp:0.0.0.0:5432 -credential_file=/config
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dockflow-1.0.0b2.tar.gz
(7.7 kB
view details)
Built Distribution
File details
Details for the file dockflow-1.0.0b2.tar.gz
.
File metadata
- Download URL: dockflow-1.0.0b2.tar.gz
- Upload date:
- Size: 7.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/49.1.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27dd445d7ed3fb0ee6cdbfd2f0196c320ac511a4d4e5534d0f01e6c52924368b |
|
MD5 | 488d9c16a745dc875d5eb687c1d15079 |
|
BLAKE2b-256 | c2fe9994b71bc709cefdef9857fd3c55551e4fb8952f027997cbcfd6486e73cc |
File details
Details for the file dockflow-1.0.0b2-py3-none-any.whl
.
File metadata
- Download URL: dockflow-1.0.0b2-py3-none-any.whl
- Upload date:
- Size: 7.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/49.1.0 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cca971ef53b340f28808b72740e673044ab18460ff9e6affd3b13dcf576c3600 |
|
MD5 | b07e2b94780eaae4b9e246b46b15104b |
|
BLAKE2b-256 | 068799ee51969b48d19629e72ce50ee458ee680d38da7324973b2937b9c73ec9 |