Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-abort-release/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command cancels the scheduled release for the selected dedicated server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-abort-release/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A comand to cancel the scheduled release for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds abort-release ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-add-network/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command adds a network to the selected server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-add-network/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to add a network to the server with the "ex4mp1eID" ID.

```
srvctl hosts ds add-network ex4mp1eID --distribution-method route --mask 32 --type private
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-add-ptr/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command adds a PTR record to the selected server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-add-ptr/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A commands to add a PTR record for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds add-ptr ex4mp1eID --domain example.com --ip X.X.X.X --priority 1 --ttl 360
```
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-add/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to create a dedicated server. It allows to pass parameters of a server in two ways:

- Input - server parameters are described in a file, a path to the file is specified via the `-i` or `–input` flag. The path can be absolute or relative to the srvctl file. Parameters should be described as a request body of the [Public API request](https://developers.servers.com/api-documentation/v1/#tag/Dedicated-Server/operation/CreateADedicatedServer). There is also an option to use standard input (stdin) when specifying the flag this way: `--input -`

- Flags - parameters are specified via flags inside the command and hostnames are listed as position arguments. As many arguments, as many servers of this configuration will be created. The only available authentication method is password. An SSH key can be added only via the input process.
98 changes: 98 additions & 0 deletions docs/srvctl-hosts-ds-add/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
#### Create server via input

An example of a command for a file in the same directory with srvctl:
```
srvctl hosts ds add --input <file name>
```

An example of the file's content:
```
{
"server_model_id": 10515,
"location_id": 2,
"ram_size": 32,
"uplink_models": {
"public": {
"id": 10198,
"bandwidth_model_id": 13744
},
"private": {
"id": 10201
}
},
"drives": {
"slots": [
{
"position": 0,
"drive_model_id": 10306
},
{
"position": 1,
"drive_model_id": 10306
}
],
"layout": [
{
"slot_positions": [
0,
1
],
"raid": 1,
"partitions": [
{
"target": "/",
"size": 10240,
"fill": false,
"fs": "ext4"
},
{
"target": "/boot",
"size": 1024,
"fill": false,
"fs": "ext4"
},
{
"target": "/home",
"size": 1,
"fill": true,
"fs": "ext4"
}
]
}
]
},
"ipv6": false,
"hosts": [
{
"hostname": "<give a name>"
}
],
"operating_system_id": 62,
"ssh_key_fingerprints": [
"<fingerprint of an SSH key>"
]
}
```

#### Create server via flags

This is an example of a command to create a dedicated server via flags:
```
srvctl hosts ds add \
--location-id 2 \
--server-model-id 10515 \
--ram-size 32 \
--operating-system-id 62 \
--public-uplink-id 10198 \
--public-bandwidth-id 13744 \
--private-uplink-id 10201 \
--drive-slots 1=10306 \
--drive-slots 2=10306 \
--layout=slot=0,slot=1,raid=1 \
--partition=slot=0,slot=1,target=/,fs=ext4,size=10240,fill=false \
--partition=slot=0,slot=1,target=/boot,fs=ext4,size=1024,fill=false \
--partition=slot=0,slot=1,target=/home,fs=ext4,size=1,fill=true \
--feature no_private_ip \
--ipv6 \
<hostname>
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-delete-network/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command deletes a specified network for the selected server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-delete-network/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command that deletes a network for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds delete-network ex4mp1eID_server --network-id ex4mp1eID_network
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-delete-ptr/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command deletes a specified PTR record for the selected server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-delete-ptr/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to delete a PTR record for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds delete-ptr ex4mp1eID_server --ptr-id ex4mp1eID_ptr
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-get-network/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command provides information about a specified network of the selected server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-get-network/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to get information about a network for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds get-network ex4mp1eID_server --network-id ex4mp1eID_network
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-get-oob-credentials/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command provides OOB credentials for the selected server. A GPG key fingerprint is needed.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-get-oob-credentials/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to get OOB credentials for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds get-oob-credentials ex4mp1eID --fingerprint GPGKEYEX4MP1E
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-get/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command provides information for the selected server.
4 changes: 4 additions & 0 deletions docs/srvctl-hosts-ds-get/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
A command to get information for the server with the "ex4mp1eID" ID.
```
srvctl hosts ds get ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-connections/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists connections for the selected dedicated server. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-connections/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list connections for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-connections ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-drive-slots/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists drive slots for the selected dedicated server. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-drive-slots/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list drive slots for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-drive-slots ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-features/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists features for the selected dedicated server. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-features/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list features for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-features ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-networks/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists networks for the selected dedicated server. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-networks/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list networks for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-networks ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-power-feeds/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists power feeds for the selected dedicated server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-power-feeds/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list power feeds for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-power-feeds ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-ptr/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists PTR records for the selected dedicated server. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-ptr/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list PTR records for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-ptr ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-list-services/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists services for the selected dedicated server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-list-services/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list services for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list-services ex4mp1eID
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-ls/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command lists dedicated servers of the account. Use `--help` to see available flags.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-ls/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list all dedicated servers for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds list ex4mp1eID --all
```
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-power/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
This command manages power operations for the selected dedicated server.

- `--command off` - a flag to power off a server.
- `--command on` - a flag to power on a server.
- `--command cycle` - a flag for the power cycle command.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-power/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to switch off the server with the "ex4mp1eID" ID.

```
srvctl hosts ds power ex4mp1eID --command off
```
3 changes: 3 additions & 0 deletions docs/srvctl-hosts-ds-reinstall/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
This command reinstalls an operating system for the selected dedicated server. The `-i`, `--input` allows to provide parameters of a created server in a local file. Parameters should be described as a request body of the [Public API request](https://developers.servers.com/api-documentation/v1/#tag/Dedicated-Server/operation/CreateADedicatedServer).

There is also an option to use standard input (stdin) when specifying the flag this way: `--input -`
54 changes: 54 additions & 0 deletions docs/srvctl-hosts-ds-reinstall/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
An example of a command for the server with the "ex4mp1eID" ID to reinstall OS using a file in the same directory with srvctl:

```
srvctl hosts ds reinstall ex4mp1eID --input <file name>
```

An example of the file's content:
```
{
"hostname": "<give a name>",
"drives": {
"slots": [
{
"position": 0,
"drive_model_id": 10306
},
{
"position": 1,
"drive_model_id": 10306
}
],
"layout": [
{
"slot_positions": [
0,
1
],
"raid": 1,
"partitions": [
{
"target": "/",
"size": 10240,
"fill": false,
"fs": "ext4"
},
{
"target": "/boot",
"size": 1024,
"fill": false,
"fs": "ext4"
},
{
"target": "/home",
"size": 1,
"fill": true,
"fs": "ext4"
}
]
}
]
},
"operating_system_id": 49
}
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-schedule-release/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command schedules release on YYYY-MM-DDTHH:MM:SS+HH:MM (dateTtime+time zone from UTC) for the selected dedicated server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-schedule-release/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to schedule release for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds schedule-release ex4mp1eID --release-after 2022-05-24T12:48:00+03:00
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds-update/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command updates parameters and labels for the selected dedicated server.
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds-update/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to assign labels for the server with the "ex4mp1eID" ID.

```
srvctl hosts ds update ex4mp1eID --label environment=production --label team=frontend
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts-ds/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This command allows to manage dedicated servers (Enterprise bare metal).
5 changes: 5 additions & 0 deletions docs/srvctl-hosts-ds/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
A command to list all dedicated servers for the account:

```
srvctl hosts ds list --all
```
1 change: 1 addition & 0 deletions docs/srvctl-hosts/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
A host is a bare metal-based service that includes dedicated servers, Kubernetes bare metal nodes and scalable bare metal. It has subcommands for each specific service.
4 changes: 4 additions & 0 deletions docs/srvctl-hosts/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
A command to list all account hosts showing their ID, Title and Status:
```
srvctl hosts list -f ID -f Title -f Status --all
```
31 changes: 31 additions & 0 deletions docs/srvctl/description.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
srvctl is a Command Line Interface to manage Servers.com services.

## Getting started

1) Get a Public API token from the Servers.com [Customer Portal](https://portal.servers.com/iam/api-tokens).

2) Open terminal and perform commands that are described below.

3) Log in to the context:

```
srvctl login <context-name>
```

There is no context yet; so, this operation will create a context and give it a name that you entered within this command.

4) Enter your Public API token and confirm.

The newly created context will be setup as default.

5) When a context is successfully created, it will be shown by the listing contexts command:

```
srvctl context list
```

6) Use the help command to explore other possibilities of the agent:

```
srvctl help
```
5 changes: 5 additions & 0 deletions docs/srvctl/examples.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
An example of the help command:

```
srvctl --help
```