GCP
Learn how to deploy Flowise on GCP
Last updated
git clone https://github.com/FlowiseAI/Flowise.gitcd Flowise
pnpm install
pnpm buildFROM --platform=linux/amd64 node:18-alpineRUN apk add --no-cache python3 make g++docker build -t gcr.io/[ProjectId]/flowise:dev .docker push gcr.io/[ProjectId]/flowise:dev# deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: flowise
labels:
app: flowise
spec:
selector:
matchLabels:
app: flowise
replicas: 1
template:
metadata:
labels:
app: flowise
spec:
containers:
- name: flowise
image: gcr.io/[ProjectID]/flowise:dev
imagePullPolicy: Always
resources:
requests:
cpu: "1"
memory: "1Gi"# service.yaml
apiVersion: "v1"
kind: "Service"
metadata:
name: "flowise-service"
namespace: "default"
labels:
app: "flowise"
spec:
ports:
- protocol: "TCP"
port: 80
targetPort: 3000
selector:
app: "flowise"
type: "LoadBalancer"kubectl apply -f yamls/deployment.yaml
kubectl apply -f yamls/service.yamlapiVersion: cloud.google.com/v1
kind: BackendConfig
metadata:
name: flowise-backendconfig
namespace: your-namespace
spec:
timeoutSec: 600apiVersion: v1
kind: Service
metadata:
annotations:
cloud.google.com/backend-config: '{"default": "flowise-backendconfig"}'
name: flowise-service
namespace: your-namespace
...