Skip to content

Commit

Permalink
fix: httpscaledobject yaml (#137)
Browse files Browse the repository at this point in the history
* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* fix: httpscaledobject yaml

* wip

* wip

* wip

* wip

* wip

* wip

---------

Co-authored-by: Reeve Lorena <reeve@vio.com>
  • Loading branch information
reeve24 and Reeve Lorena authored Nov 19, 2024
1 parent ce044a6 commit a696272
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v5
uses: docker/build-push-action@v6
env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
with:
Expand Down
5 changes: 3 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,9 @@ RUN apk --no-cache --quiet update \
&& apk add --no-cache --quiet rhash gettext moreutils curl bash git jq python3 py3-pip

# AWS CLI
RUN pip3 install --no-python-version-warning --upgrade --quiet pip \
&& pip3 install --no-python-version-warning --quiet awscli
RUN pip3 install --no-python-version-warning --break-system-packages --upgrade pip

RUN apk add --no-cache aws-cli

# Kubectl #
RUN curl -LO --silent https://storage.googleapis.com/kubernetes-release/release/${KUBECTL_VERSION}/bin/linux/amd64/kubectl \
Expand Down
32 changes: 20 additions & 12 deletions src/deploy/resources/base/httpscaledobject.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,23 @@
apiVersion: http.keda.sh/v1alpha1
kind: HTTPScaledObject
apiVersion: http.keda.sh/v1alpha1
metadata:
name: keda-http
name: keda-http
spec:
host: "PLACEHOLDER"
targetPendingRequests: 100
scaleTargetRef:
deployment: kube-review-deployment
service: kube-review-service
port: 80
scaledownPeriod: 900
replicas:
min: 0
max: 1
hosts:
- "PLACEHOLDER"
pathPrefixes:
- /
scaleTargetRef:
name: kube-review-deployment
kind: Deployment
apiVersion: apps/v1
service: kube-review-service
port: 80
replicas:
min: 0
max: 1
scalingMetric:
requestRate:
granularity: 1s
targetValue: 100
window: 1m
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[
{
"op": "replace",
"path": "/spec/host",
"path": "/spec/hosts/0",
"value": "$KR_NAMESPACE.$KR_DOMAIN"
}
]

0 comments on commit a696272

Please sign in to comment.