This repository has been archived by the owner on Sep 3, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 79
Set up script for Composer and support for getting gcsDagLocation from Composer environment #585
Merged
Merged
Changes from 2 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
ad956cc
Bash script for setting up Composer
b5eafa6
Parameterizing more stuff
0172ad8
Merge branch 'master' into rajivpb-composer-setup
57111a7
Removing commented out commands and adding default values for the par…
ac9104c
Finishing up the Composer setup script and starting the airflow setup…
c422b10
Merge branch 'master' into rajivpb-composer-setup
rajivpb a14ae52
Re-organizing some of the comments
94a3a75
Support for fetching gcs dag location from Composer environment
d5ad2f9
Merge branch 'master' into rajivpb-composer-setup
rajivpb 2a7f891
Add verification of bucket name
4bf2a61
Merge branch 'rajivpb-composer-setup' of github.com:googledatalab/pyd…
3646d44
Minor refactoring, and added comments
959d4d5
Unit-tests for Composer.gcs_dag_location
dc02c7c
Add stop-gap contrib imports to enable e2e
e642b2f
Add comments to release script
a44f131
Remove timeoutMs from call to Composer API; this arg is invalid
9774d10
Fix flake8 errors
bb69916
Correct wrong index for shell script arguments
2934bd5
Refactor all gcs_dag_location checks into the property.
4d6162d
Disallow trailing slash in gcs_dag_location from Composer
009a5e5
Allow trailing slash in gcs dag location
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
ZONE=us-central1 | ||
PROJECT=$1 | ||
EMAIL=$2 | ||
ZONE=$3 | ||
ENVIRONMENT=$4 | ||
|
||
|
||
gcloud config set project $PROJECT | ||
gcloud auth login --activate $EMAIL | ||
sudo gcloud components repositories add https://storage.googleapis.com/composer-trusted-tester/components-2.json | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. First thing is to install composer specific gcloud and it may vary slightly depending on the environment (e.g., VM, shell, local) before any gcloud * operations. |
||
|
||
#gcloud components update -q | ||
sudo apt-get update | ||
sudo apt-get --only-upgrade install kubectl google-cloud-sdk google-cloud-sdk-datastore-emulator \ | ||
google-cloud-sdk-pubsub-emulator google-cloud-sdk-app-engine-go google-cloud-sdk-app-engine-java \ | ||
google-cloud-sdk-app-engine-python google-cloud-sdk-cbt google-cloud-sdk-bigtable-emulator \ | ||
google-cloud-sdk-datalab | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can put apt-get first, and then composer gcloud installation, and finally composer related configs and environment creation. |
||
|
||
#gcloud components install -q alpha kubectl | ||
sudo apt-get install google-cloud-sdk kubectl | ||
|
||
gcloud config set composer/location $ZONE | ||
gcloud alpha composer environments create $ENVIRONMENT | ||
gcloud alpha composer environments describe $ENVIRONMENT | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
--activate is the default
Is this setup.sh only ever run manually? (Asking because users shouldn't gcloud auth login on a VM.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, setup.sh is only ever run manually on a local machine at the moment. It's not for the VM scenario.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Removed --activate)