Copyright 2024 Google LLC
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Please note this tool will move files from Google Workspace and your Google Workspace terms of service to Google Cloud and the Google Cloud terms of service. Costs may be occured for use of Google Cloud Storage and Vertex AI
This project creates an App Engine to operate periodically to check a Google Drive Folder and move content to Google Cloud storage for a Search and Conversation Chat bot to index on.
- Create a project
- Enable https://console.developers.google.com/apis/api/serviceusage.googleapis.com/overview?project=
- Deploy the App Engine App
gcloud app deploy
- Create a Search and Conversation Configuration; Chat app.
- Create a Datastore in the configuration for Cloud Storage. Datastore Folder should be a cloud storage bucket listed as {GOOGLE_CLOUD_PROJECT}_{BUCKET_NAME}
- Optional: Navigate to the bot and capture the dialog flow agent id
- Update the app.yaml environment variables with the Datastore ID, Project, Folder ID, Storage bucket unique name, Agent ID, and Location ("global", "us" or "eu")
- Grant the App Engine Serice Account the following roles:
- roles/storage.admin
- roles/storage.objectAdmin
- roles/storage.objectCreator
- roles/aiplatform.admin
- Redeploy the App Engine App
gcloud app deploy
- Deploy the cron.yaml
gcloud app deploy cron.yaml
- Share the Google Drive Folder with View access to the App Engine service account
- Launch the Initialization by navigating to the root web url provided on deployment.