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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 octavia-cli: fix interactive octavia, set version to 0.1.0, update readme #11155

Merged
merged 3 commits into from
Mar 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 14 additions & 22 deletions octavia-cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ It has the following features:
* Safe resources update through diff display and validation.
* Simple secret management to avoid versioning credentials.

The project is under development: readers can refer to our [tech spec deck](https://docs.google.com/presentation/d/10RjkCzBiVhCivnjSh63icYI7wG6S0N0ZIErEIsmXTqM/edit?usp=sharing) for an introduction to the tool.
## Disclaimer
The project is in **alpha** version.
Readers can refer to our [opened GitHub issues](https://github.com/airbytehq/airbyte/issues?q=is%3Aopen+is%3Aissue+label%3Aarea%2Foctavia-cli) to check the ongoing work on this project.

# Install

Expand All @@ -23,17 +25,14 @@ curl -o- https://raw.githubusercontent.com/airbytehq/airbyte/master/octavia-cli/
This script:
1. Pulls the [octavia-cli image](https://hub.docker.com/r/airbyte/octavia-cli/tags) from our Docker registry.
2. Creates an `octavia` alias in your profile.
3. Creates a `~/.octavia` file whose values are mapped to the octavia container's environment variables.

## 2.b If you want to directly run the CLI without alias in your current directory:
```bash
mkdir my_octavia_project_directory # Create your octavia project directory where YAML configurations will be stored.
docker run --rm -v ./my_octavia_project_directory:/home/octavia-project --network host -e AIRBYTE_URL="http://localhost:8000" airbyte/octavia-cli:dev
````
docker run -i --rm -v ./my_octavia_project_directory:/home/octavia-project --network host -e AIRBYTE_URL="http://localhost:8000" airbyte/octavia-cli:dev
```

# Current development status
Octavia is currently under development.
You can find a detailed and updated execution plan [here](https://docs.google.com/spreadsheets/d/1weB9nf0Zx3IR_QvpkxtjBAzyfGb7B0PWpsVt6iMB5Us/edit#gid=0).
We welcome community contributions!

# Secret management
Sources and destinations configurations have credential fields that you **do not want to store as plain text and version on Git**.
Expand All @@ -44,20 +43,6 @@ configuration:
```
If you have set a `MY_PASSWORD` environment variable, `octavia apply` will load its value into the `password` field.

**Summary of achievements**:

| Date | Milestone |
|------------|-------------------------------------|
| 2022-03-09 | Implement secret management through environment variable expansion |
| 2022-03-09 | Implement `octavia generate connection`|
| 2022-03-09 | Implement `octavia apply` for connections|
| 2022-03-02 | Implement `octavia apply` (sources and destination only)|
| 2022-02-06 | Implement `octavia generate` (sources and destination only)|
| 2022-01-25 | Implement `octavia init` + some context checks|
| 2022-01-19 | Implement `octavia list workspace sources`, `octavia list workspace destinations`, `octavia list workspace connections`|
| 2022-01-17 | Implement `octavia list connectors source` and `octavia list connectors destinations`|
| 2022-01-17 | Generate an API Python client from our Open API spec |
| 2021-12-22 | Bootstrapping the project's code base |

# Developing locally
1. Install Python 3.8.12. We suggest doing it through `pyenv`
Expand All @@ -76,4 +61,11 @@ SUB_BUILD=OCTAVIA_CLI ./gradlew build # from the root directory of the repo
# Contributing
1. Please sign up to [Airbyte's Slack workspace](https://slack.airbyte.io/) and join the `#octavia-cli`. We'll sync up community efforts in this channel.
2. Read the [execution plan](https://docs.google.com/spreadsheets/d/1weB9nf0Zx3IR_QvpkxtjBAzyfGb7B0PWpsVt6iMB5Us/edit#gid=0) and find a task you'd like to work on.
3. Open a PR, make sure to test your code thoroughly.
3. Open a PR, make sure to test your code thoroughly.


# Changelog

| Version | Date | Description | PR |
|---------|------------|------------------|----------------------------------------------------------|
| 0.1.0 | 2022-03-15 | Alpha release | [EPIC](https://github.com/airbytehq/airbyte/issues/10704)|
6 changes: 3 additions & 3 deletions octavia-cli/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# This install scripts currently only works for ZSH and Bash profiles.
# It creates an octavia alias in your profile bound to a docker run command

VERSION=dev
VERSION=0.1.0
OCTAVIA_ENV_FILE=${HOME}/.octavia

detect_profile() {
Expand Down Expand Up @@ -55,8 +55,8 @@ create_octavia_env_file() {


add_alias() {
echo 'alias octavia="pwd | xargs -I {} docker run --rm -v {}:/home/octavia-project --network host --env-file \${OCTAVIA_ENV_FILE} airbyte/octavia-cli:'${VERSION}'"' >> ${DETECTED_PROFILE}
echo "馃悪 - 馃帀 octavia alias was added to ${DETECTED_PROFILE} , please open a new terminal window or run source ${DETECTED_PROFILE}"
echo 'alias octavia="pwd | xargs -o -I {} docker run -i --rm -v {}:/home/octavia-project --network host --env-file \${OCTAVIA_ENV_FILE} airbyte/octavia-cli:'${VERSION}'"' >> ${DETECTED_PROFILE}
echo "馃悪 - 馃帀 octavia alias was added to ${DETECTED_PROFILE}, please open a new terminal window or run source ${DETECTED_PROFILE}"
}

install() {
Expand Down