Skip to content

Commit e30bbfa

Browse files
committed
Merge branch 'main' into nb-frontend-vpc & fix linodego dependency conflict
2 parents 7f21106 + f9d4092 commit e30bbfa

14 files changed

Lines changed: 85 additions & 71 deletions

File tree

.github/workflows/automerge.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212

1313
steps:
1414
- name: Checkout
15-
uses: actions/checkout@v5
15+
uses: actions/checkout@v6
1616
with:
1717
fetch-depth: 0 # Full clone necessary for proper merge
1818

.github/workflows/build-test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
outputs:
2121
paths: ${{ steps.filter.outputs.changes }}
2222
steps:
23-
- uses: actions/checkout@v5
23+
- uses: actions/checkout@v6
2424
with:
2525
ref: ${{ github.event.pull_request.head.sha }}
2626
- name: Harden Runner
@@ -61,7 +61,7 @@ jobs:
6161
get.helm.sh:443
6262
golangci-lint.run:443
6363
64-
- uses: actions/checkout@v5
64+
- uses: actions/checkout@v6
6565
with:
6666
fetch-depth: 0
6767
- uses: actions/setup-go@v6
@@ -90,7 +90,7 @@ jobs:
9090
docker-build:
9191
runs-on: ubuntu-latest
9292
steps:
93-
- uses: actions/checkout@v5
93+
- uses: actions/checkout@v6
9494
with:
9595
fetch-depth: 0
9696
- name: Docker Meta

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
outputs:
2222
paths: ${{ steps.filter.outputs.changes }}
2323
steps:
24-
- uses: actions/checkout@v5
24+
- uses: actions/checkout@v6
2525
with:
2626
ref: ${{ github.event.pull_request.head.sha }}
2727
- name: Harden Runner
@@ -40,7 +40,7 @@ jobs:
4040

4141
codecov:
4242
runs-on: ubuntu-latest
43-
environment: ${{ github.event.pull_request.head.repo.fork == true && 'prod-external' || 'prod' }}
43+
environment: ${{ (github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository) && 'prod-external' || 'prod' }}
4444
needs: changes
4545
if: ${{ contains(fromJSON(needs.changes.outputs.paths), 'src') }}
4646
steps:
@@ -61,7 +61,7 @@ jobs:
6161
api.codecov.io:443
6262
ingest.codecov.io:443
6363
64-
- uses: actions/checkout@v5
64+
- uses: actions/checkout@v6
6565
with:
6666
ref: ${{ github.event.pull_request.head.sha }}
6767
- uses: actions/setup-go@v6
@@ -82,7 +82,7 @@ jobs:
8282

8383
e2e-tests:
8484
runs-on: ubuntu-latest
85-
environment: ${{ github.event.pull_request.head.repo.fork == true && 'prod-external' || 'prod' }}
85+
environment: ${{ (github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository) && 'prod-external' || 'prod' }}
8686
needs: changes
8787
if: ${{ contains(fromJSON(needs.changes.outputs.paths), 'src') }}
8888
env:
@@ -94,7 +94,7 @@ jobs:
9494
LINODE_MACHINE_TYPE: g6-standard-2
9595
WORKER_NODES: '2'
9696
steps:
97-
- uses: actions/checkout@v5
97+
- uses: actions/checkout@v6
9898
with:
9999
ref: ${{ github.event.pull_request.head.sha }}
100100

.github/workflows/helm.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: Checkout
18-
uses: actions/checkout@v5
18+
uses: actions/checkout@v6
1919
with:
2020
fetch-depth: 0
2121

@@ -34,7 +34,7 @@ jobs:
3434
check-latest: true
3535

3636
- name: Set up chart-testing
37-
uses: helm/chart-testing-action@v2.7.0
37+
uses: helm/chart-testing-action@v2.8.0
3838

3939
- name: Run chart-testing (lint)
4040
run: ct lint --check-version-increment=false --chart-dirs deploy --target-branch ${{ github.event.repository.default_branch }}
@@ -54,7 +54,7 @@ jobs:
5454
runs-on: ubuntu-latest
5555
steps:
5656
- name: Checkout
57-
uses: actions/checkout@v5
57+
uses: actions/checkout@v6
5858
with:
5959
fetch-depth: 0
6060

.github/workflows/label-sync.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
build:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/checkout@ff7abcd0c3c05ccf6adc123a8cd1fd4fb30fb493 # pin@v2
12+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # pin@v2
1313
- uses: micnncim/action-label-syncer@3abd5ab72fda571e69fffd97bd4e0033dd5f495c # pin@v1
1414
env:
1515
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/pr-labeler.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- name: Checkout repository
17-
uses: actions/checkout@v5
17+
uses: actions/checkout@v6
1818
with:
1919
fetch-depth: 0
2020
- name: Label PR

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@ jobs:
88
release:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v5
11+
- uses: actions/checkout@v6
1212
with:
1313
fetch-depth: 0
1414
- name: Create Release Artifacts
1515
run: make release
1616
env:
1717
IMAGE_VERSION: ${{ github.ref_name }}
1818
- name: Upload Release Artifacts
19-
uses: softprops/action-gh-release@v2.4.1
19+
uses: softprops/action-gh-release@v2.5.0
2020
with:
2121
files: |
2222
./release/helm-chart-${{ github.ref_name }}.tgz

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ COPY sentry ./sentry
1111
RUN go mod download
1212
RUN go build -a -ldflags '-extldflags "-static"' -o /bin/linode-cloud-controller-manager-linux /linode
1313

14-
FROM alpine:3.22.2
14+
FROM alpine:3.23.2
1515
RUN apk add --update --no-cache ca-certificates
1616
LABEL maintainers="Linode"
1717
LABEL description="Linode Cloud Controller Manager"

cloud/linode/loadbalancers.go

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -773,8 +773,20 @@ func (l *loadbalancers) GetLoadBalancerTags(_ context.Context, clusterName strin
773773
// GetLinodeNBType returns the NodeBalancer type for the service.
774774
func (l *loadbalancers) GetLinodeNBType(service *v1.Service) linodego.NodeBalancerPlanType {
775775
typeStr, ok := service.GetAnnotations()[annotations.AnnLinodeNodeBalancerType]
776-
if ok && linodego.NodeBalancerPlanType(typeStr) == linodego.NBTypePremium {
777-
return linodego.NBTypePremium
776+
if ok {
777+
// For Safety - avoid typos and inconsistent casing
778+
typeStr = strings.ToLower(typeStr)
779+
switch linodego.NodeBalancerPlanType(typeStr) {
780+
case linodego.NBTypeCommon: // need to add this because of the golint check
781+
return linodego.NBTypeCommon
782+
case linodego.NBTypePremium:
783+
return linodego.NBTypePremium
784+
case linodego.NBTypePremium40GB:
785+
return linodego.NBTypePremium40GB
786+
default:
787+
klog.Warningf("Invalid NodeBalancer type '%s' specified in annotation for service %s/%s. Valid types are: %s, %s, %s. Defaulting to %s.",
788+
typeStr, service.Namespace, service.Name, linodego.NBTypeCommon, linodego.NBTypePremium, linodego.NBTypePremium40GB, options.Options.DefaultNBType)
789+
}
778790
}
779791

780792
return linodego.NodeBalancerPlanType(options.Options.DefaultNBType)

docs/configuration/annotations.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ The keys and the values in [annotations must be strings](https://kubernetes.io/d
3838
| `tags` | string | | A comma separated list of tags to be applied to the NodeBalancer instance |
3939
| `firewall-id` | int | | An existing Cloud Firewall ID to be attached to the NodeBalancer instance. See [Firewall Setup](firewall.md) |
4040
| `firewall-acl` | string | | The Firewall rules to be applied to the NodeBalancer. See [Firewall Configuration](#firewall-configuration) |
41-
| `nodebalancer-type` | string | | The type of NodeBalancer to create (options: common, premium). See [NodeBalancer Types](#nodebalancer-type) |
41+
| `nodebalancer-type` | string | | The type of NodeBalancer to create (options: common, premium, premium_40gb). See [NodeBalancer Types](#nodebalancer-type). Note: NodeBalancer types should always be specified in lowercase. |
4242
| `enable-ipv6-ingress` | bool | `false` | When `true`, both IPv4 and IPv6 addresses will be included in the LoadBalancerStatus ingress |
4343
| `backend-ipv4-range` | string | | The IPv4 range from VPC subnet to be applied to the NodeBalancer backend. See [Nodebalancer VPC Configuration](#nodebalancer-vpc-configuration) |
4444
| `backend-vpc-name` | string | | VPC which is connected to the NodeBalancer backend. See [Nodebalancer VPC Configuration](#nodebalancer-vpc-configuration) |
@@ -129,7 +129,9 @@ metadata:
129129
```
130130

131131
### NodeBalancer Type
132-
Linode supports nodebalancers of different types: common and premium. By default, nodebalancers of type common are provisioned. If an account is allowed to provision premium nodebalancers and one wants to use them, it can be achieved by specifying the annotation:
132+
Linode supports nodebalancers of different types: common, premium, and premium_40gb. By default, nodebalancers of type common are provisioned. If an account is allowed to provision premium nodebalancers and one wants to use them, it can be achieved by specifying the annotation:
133+
134+
**Note:** NodeBalancer types should always be specified in lowercase. The controller will automatically convert uppercase values to lowercase for safety.
133135
```yaml
134136
metadata:
135137
annotations:

0 commit comments

Comments
 (0)