{"id":17695992,"url":"https://github.com/sonodar/dify-aws-terraform","last_synced_at":"2025-05-05T22:33:15.616Z","repository":{"id":255601356,"uuid":"805488057","full_name":"sonodar/dify-aws-terraform","owner":"sonodar","description":"Terraform template for Dify on AWS","archived":false,"fork":false,"pushed_at":"2024-09-05T02:26:51.000Z","size":26,"stargazers_count":36,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-31T00:18:02.444Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sonodar.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-24T17:28:48.000Z","updated_at":"2025-03-06T06:06:02.000Z","dependencies_parsed_at":"2024-09-06T08:38:54.435Z","dependency_job_id":"625a8d46-610d-46b3-a54f-597877ed5791","html_url":"https://github.com/sonodar/dify-aws-terraform","commit_stats":null,"previous_names":["sonodar/dify-aws-terraform"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonodar%2Fdify-aws-terraform","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonodar%2Fdify-aws-terraform/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonodar%2Fdify-aws-terraform/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sonodar%2Fdify-aws-terraform/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sonodar","download_url":"https://codeload.github.com/sonodar/dify-aws-terraform/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252586059,"owners_count":21772247,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-24T14:42:57.655Z","updated_at":"2025-05-05T22:33:15.570Z","avatar_url":"https://github.com/sonodar.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# dify-aws-terraform\n\nTerraform template for Dify on AWS\n\n## Premise and summary\n\n- VPC はすでに構築済みであるものとします\n- 公式では SSRF 対策の Forward Proxy として Squid を利用していますが、ここでは省略しています\n- ElastiCache Redis のクラスターモードは接続エラーになったため無効にしています\n- PostgreSQL の `pgvector` を Vector Storage として利用しています\n- Aurora PostgreSQL Serverless で構築していますが、通常のものでも可能です\n\n## Prerequisites\n\n- Terraform\n\n## Usage\n\n1. Clone this repository\n2. Edit `terraform.tfvars` to set your variables\n3. Edit `backend.tf` to set your S3 bucket and DynamoDB table\n4. Run `terraform init`\n5. Run `terraform plan`\n6. Run `terraform apply -target aws_rds_cluster_instance.dify`\n7. Execute the following SQL in the RDS cluster\n\n    ```sql\n    CREATE ROLE dify WITH LOGIN PASSWORD 'your-password';\n    GRANT dify TO postgres;\n    CREATE DATABASE dify WITH OWNER dify;\n    \\c dify\n    CREATE EXTENSION vector;\n    ```\n\n8. Run `terraform apply`\n9. Run `terraform apply` again, if task is not started\n\n構築が完了し、ECS タスクがすべて起動したら Output の `dify_url` にアクセスしてください。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsonodar%2Fdify-aws-terraform","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsonodar%2Fdify-aws-terraform","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsonodar%2Fdify-aws-terraform/lists"}