Skip to content
This repository has been archived by the owner on Jun 29, 2022. It is now read-only.

Commit

Permalink
Merge pull request #612 from kinvolk/johananl/packet-default-dev-type
Browse files Browse the repository at this point in the history
packet: Use c3.small.x86 by default
  • Loading branch information
johananl authored Jul 6, 2020
2 parents d7a05da + c660564 commit 7225aa9
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@ variable "controller_count" {

variable "controller_type" {
type = string
# This is Packet's internal name for "t1.small.x86"
default = "baremetal_0"
default = "c3.small.x86"
description = "Packet instance type for controllers"
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ variable "worker_count" {

variable "type" {
type = string
# This is Packet's internal name for "t1.small.x86"
default = "baremetal_0"
default = "c3.small.x86"
description = "Packet instance type for workers, can be changed afterwards to recreate the nodes"
}

Expand Down
1 change: 1 addition & 0 deletions ci/packet/packet-cluster.lokocfg.envsubst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ cluster "packet" {
asset_dir = pathexpand("~/lokoctl-assets")
cluster_name = "$CLUSTER_ID"
controller_count = 1
controller_type = "t1.small.x86"

controller_clc_snippets = [
<<EOF
Expand Down
4 changes: 2 additions & 2 deletions docs/configuration-reference/components/cluster-autoscaler.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ component "cluster-autoscaler" {
facility = "sjc1"
# Optional arguments
worker_type = "t1.small.x86"
worker_type = "c3.small.x86"
worker_channel = "stable"
}
}
Expand All @@ -84,7 +84,7 @@ Example:
| `service_monitor` | Specifies how metrics can be retrieved from a set of services. | false | bool | false |
| `packet.project_id` | Packet Project ID where the cluster is running. | - | string | true |
| `packet.facility` | Packet Facility where the cluster is running. | - | string | true |
| `packet.worker_type` | Machine type for workers spawned by the Cluster Autoscaler. | "t1.small.x86" | string | false |
| `packet.worker_type` | Machine type for workers spawned by the Cluster Autoscaler. | "c3.small.x86" | string | false |
| `packet_worker_channel` | Flatcar Container Linux channel to be used in workers spawned by the Cluster Autoscaler. | "stable" | string | false |


Expand Down
11 changes: 5 additions & 6 deletions docs/configuration-reference/platforms/packet.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ cluster "packet" {
controller_count = var.controllers_count
controller_type = "t1.small.x86"
controller_type = "c3.small.x86"
controller_clc_snippets = var.controller_clc.snippets
Expand Down Expand Up @@ -171,9 +171,8 @@ block in the cluster configuration.

Example:

The default for node_type is `baremetal_0` (which is Packet's internal name for
`t1.small.x86`). If you wish to change the default, then you define the
variable and use it to refer in the cluster configuration.
The default for node_type is `c3.small.x86`. If you wish to change the default, then you
define the variable and use it to refer in the cluster configuration.

```tf
variable "custom_default_worker_type" {
Expand All @@ -199,7 +198,7 @@ node_type = var.custom_default_worker_type
| `cluster_name` | Name of the cluster. | - | string | true |
| `tags` | List of tags that will be propagated to master nodes. | - | map(string) | false |
| `controller_count` | Number of controller nodes. | 1 | number | false |
| `controller_type` | Packet instance type for controllers. | "baremetal_0" | string | false |
| `controller_type` | Packet instance type for controllers. | "c3.small.x86" | string | false |
| `controller_clc_snippets` | Controller Flatcar Container Linux Config snippets. | [] | list(string) | false |
| `dns` | DNS configuration block. | - | object | true |
| `dns.zone` | A DNS zone to use for the cluster. The following format is used for cluster-related DNS records: `<record>.<cluster_name>.<dns_zone>` | - | string | true |
Expand Down Expand Up @@ -236,7 +235,7 @@ node_type = var.custom_default_worker_type
| `worker_pool.os_arch` | Flatcar Container Linux architecture to install (amd64, arm64). | "amd64" | string | false |
| `worker_pool.os_channel` | Flatcar Container Linux channel to install from (stable, beta, alpha, edge). | "stable" | string | false |
| `worker_pool.os_version` | Flatcar Container Linux version to install. Version such as "2303.3.1" or "current". | "current" | string | false |
| `worker_pool.node_type` | Packet instance type for worker nodes. | "baremetal_0" | string | false |
| `worker_pool.node_type` | Packet instance type for worker nodes. | "c3.small.x86" | string | false |
| `worker_pool.labels` | Custom labels to assign to worker nodes. | - | string | false |
| `worker_pool.taints` | Taints to assign to worker nodes. | - | string | false |
| `worker_pool.reservation_ids` | Block with Packet hardware reservation IDs for worker nodes. Each key must have the format `worker-${index}` and the value is the reservation UUID. Can't be combined with `reservation_ids_default`. Example: `reservation_ids = { worker-0 = "<reservation_id>" }`. | - | map(string) | false |
Expand Down
7 changes: 5 additions & 2 deletions docs/quickstarts/packet.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,12 @@ This guide shows how to create a Lokomotive cluster on [Packet](https://www.pack
end of this guide, you'll have a basic Lokomotive cluster running on Packet with a demo application
deployed.

The guide uses `t1.small.x86` as the Packet device type for all created nodes. This is also the
The guide uses `c3.small.x86` as the Packet device type for all created nodes. This is also the
default device type.

>NOTE: Visit the Packet [website](https://www.packet.com/cloud/servers/) to see all available device
>types as well as their pricing.
Lokomotive runs on top of [Flatcar Container Linux](https://www.flatcar-linux.org/). This guide
uses the `stable` channel.

Expand Down Expand Up @@ -293,7 +296,7 @@ Sometimes there may not be enough hardware available at a given Packet facility
type, in which case the following error is shown:

```
The facility ams1 has no provisionable t1.small.x86 servers matching your criteria
The facility ams1 has no provisionable c3.small.x86 servers matching your criteria
```

In this case, either select a different node type and/or Packet facility, or wait for a while until
Expand Down
8 changes: 4 additions & 4 deletions pkg/assets/generated_assets.go

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion pkg/components/cluster-autoscaler/component.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ func newComponent() *component {
switch c.Provider {
case "packet":
c.Packet = &packetConfiguration{
WorkerType: "t1.small.x86",
WorkerType: "c3.small.x86",
WorkerChannel: "stable",
}
}
Expand Down

0 comments on commit 7225aa9

Please sign in to comment.