-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #226 from Annopaolo/fwport-22.11
Forward port changes from 22.11
- Loading branch information
Showing
7 changed files
with
178 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
// Copyright © 2023 SECO Mind Srl | ||
// | ||
// 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. | ||
|
||
package deployment | ||
|
||
import ( | ||
"github.com/Masterminds/semver/v3" | ||
) | ||
|
||
var astarteBasicProfile11 AstarteClusterProfile = AstarteClusterProfile{ | ||
Name: "basic", | ||
Description: "Basic profile for test Clusters. Deterministic allocations, all Astarte Pods work on basics.", | ||
Requirements: AstarteProfileRequirements{ | ||
CPUAllocation: 3500, | ||
MemoryAllocation: 7 * 1024 * 1024 * 1024, | ||
}, | ||
Compatibility: AstarteProfileCompatibility{}, | ||
DefaultSpec: AstarteDeploymentSpec{}, | ||
CustomizableFields: []AstarteProfileCustomizableField{}, | ||
} | ||
|
||
func init() { | ||
astarteBasicProfile11.Compatibility.MaxAstarteVersion, _ = semver.NewVersion("1.1.99") | ||
astarteBasicProfile11.Compatibility.MinAstarteVersion, _ = semver.NewVersion("1.1.0") | ||
|
||
// Let components basic only | ||
astarteBasicProfile11.DefaultSpec.Components.Resources.Requests.CPU = "1200m" | ||
astarteBasicProfile11.DefaultSpec.Components.Resources.Requests.Memory = "2048M" | ||
astarteBasicProfile11.DefaultSpec.Components.Resources.Limits.CPU = "3000m" | ||
astarteBasicProfile11.DefaultSpec.Components.Resources.Limits.Memory = "3072M" | ||
|
||
// Queue size to a minimum, decent amount | ||
astarteBasicProfile11.DefaultSpec.Components.DataUpdaterPlant.DataQueueCount = 128 | ||
|
||
// Very tiny Cassandra installation | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Deploy = true | ||
astarteBasicProfile11.DefaultSpec.Cassandra.MaxHeapSize = "1024M" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.HeapNewSize = "256M" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Resources.Requests.CPU = "1000m" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Resources.Requests.Memory = "1024M" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Resources.Limits.CPU = "2000m" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Resources.Limits.Memory = "2048M" | ||
astarteBasicProfile11.DefaultSpec.Cassandra.Storage.Size = "30Gi" | ||
|
||
// Minimal CFSSL installation | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Deploy = true | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Resources.Requests.CPU = "100m" | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Resources.Requests.Memory = "128M" | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Resources.Limits.CPU = "200m" | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Resources.Limits.Memory = "256M" | ||
astarteBasicProfile11.DefaultSpec.Cfssl.Storage.Size = "2Gi" | ||
|
||
// Minimal RabbitMQ installation | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Deploy = true | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Resources.Requests.CPU = "300m" | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Resources.Requests.Memory = "512M" | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Resources.Limits.CPU = "1000m" | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Resources.Limits.Memory = "1024M" | ||
astarteBasicProfile11.DefaultSpec.Rabbitmq.Storage.Size = "4Gi" | ||
|
||
// Minimal VerneMQ installation | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Deploy = true | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Resources.Requests.CPU = "200m" | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Resources.Requests.Memory = "1024M" | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Resources.Limits.CPU = "1000m" | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Resources.Limits.Memory = "1024M" | ||
astarteBasicProfile11.DefaultSpec.Vernemq.Storage.Size = "4Gi" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
// Copyright © 2023 SECO Mind Srl | ||
// | ||
// 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. | ||
|
||
package deployment | ||
|
||
import ( | ||
"github.com/Masterminds/semver/v3" | ||
) | ||
|
||
var astarteBurstProfile11 AstarteClusterProfile = AstarteClusterProfile{ | ||
Name: "burst", | ||
Description: "Burst profile for CI Clusters. No deterministic allocations, all Astarte Pods work on bursts.", | ||
Requirements: AstarteProfileRequirements{ | ||
CPUAllocation: 2 * 1000, | ||
MemoryAllocation: 5 * 1024 * 1024 * 1024, | ||
}, | ||
Compatibility: AstarteProfileCompatibility{}, | ||
DefaultSpec: AstarteDeploymentSpec{}, | ||
CustomizableFields: []AstarteProfileCustomizableField{}, | ||
} | ||
|
||
func init() { | ||
astarteBurstProfile11.Compatibility.MaxAstarteVersion, _ = semver.NewVersion("1.1.99") | ||
astarteBurstProfile11.Compatibility.MinAstarteVersion, _ = semver.NewVersion("1.1.0") | ||
|
||
// Do not set resources, this will let components burst | ||
|
||
// Queue size to a minimum, decent amount | ||
astarteBurstProfile11.DefaultSpec.Components.DataUpdaterPlant.DataQueueCount = 128 | ||
|
||
// Very tiny Cassandra installation | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Deploy = true | ||
astarteBurstProfile11.DefaultSpec.Cassandra.MaxHeapSize = "512M" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.HeapNewSize = "256M" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Resources.Requests.CPU = "500m" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Resources.Requests.Memory = "1024M" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Resources.Limits.CPU = "1000m" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Resources.Limits.Memory = "2048M" | ||
astarteBurstProfile11.DefaultSpec.Cassandra.Storage.Size = "10Gi" | ||
|
||
// Minimal CFSSL installation | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Deploy = true | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Resources.Requests.CPU = "0m" | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Resources.Requests.Memory = "128M" | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Resources.Limits.CPU = "0m" | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Resources.Limits.Memory = "128M" | ||
astarteBurstProfile11.DefaultSpec.Cfssl.Storage.Size = "2Gi" | ||
|
||
// Minimal RabbitMQ installation | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Deploy = true | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Resources.Requests.CPU = "200m" | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Resources.Requests.Memory = "256M" | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Resources.Limits.CPU = "1000m" | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Resources.Limits.Memory = "256M" | ||
astarteBurstProfile11.DefaultSpec.Rabbitmq.Storage.Size = "4Gi" | ||
|
||
// Minimal VerneMQ installation | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Deploy = true | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Resources.Requests.CPU = "0m" | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Resources.Requests.Memory = "256M" | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Resources.Limits.CPU = "0m" | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Resources.Limits.Memory = "256M" | ||
astarteBurstProfile11.DefaultSpec.Vernemq.Storage.Size = "4Gi" | ||
} |