-
Nicolas KAROLAK authoredNicolas KAROLAK authored
Configuration
SSH
The Ansible deployment will be done through SSH, so you must be able to connect to all the involved hosts by using SSH public key authentication.
If you or your team do not have a SSH key pair, please create one with ssh-keygen
:
ssh-keygen -t ed25519
The SSH public key (~/.ssh/id_ed25519.pub
) must then be added to the authorized keys (~/.ssh/authorized_keys
) of the root
account of all the involved hosts (mymediaserver, mymediaworker, mymediavault, etc.).
It is recommended to also use a SSH config file for your hosts, especially if some of them are protected by a bastion host. For example, let's assume that "mymediaserver" is used as a bastion to join "mymediaworker" and "mymediavault":
Host mymediaserver
Hostname 1.2.3.4
IdentityFile ~/.ssh/id_ed25519
User root
Host mymediaworker
Hostname 10.0.0.2
IdentityFile ~/.ssh/id_ed25519
User root
# use mymediaserver as a jump host
ProxyJump mymediaserver
Host mymediavault
Hostname 10.0.0.3
IdentityFile ~/.ssh/id_ed25519
User root
# use mymediaserver as a jump host
ProxyJump mymediaserver
Customer informations
The customer must provides some informations about its network, desired URLs, etc. You can use this deployment form template as a base to send to the customer.
When the deployment form is completed by the customer, send it to the UbiCast deployment team who will put the data in the fleet management tool.
Once the deployment team have updated the data for the hosts, the deployment can begin.
Inventory
Make a copy of the example
inventory and eventually customize it with the customer informations.
cp -r inventories/example inventories/my-customer
Hosts and Groups
Edit inventories/my-customer/hosts
to match with my-customer
inrastructure.
For example, if there is only a MediaServer and a MediaWorker you can remove all other hosts and groups:
mymediaserver
mymediaworker
mymediavault
[msmonitor]
mymediaserver
[postgres]
mymediaserver
[mirismanager]
mymediaserver
[mediaserver]
mymediaserver
[wowza]
mymediaserver
[celerity]
mymediaserver
[mediaworker]
mymediaworker
[mediavault]
mymediavault
Variables
You must at least configure:
-
skyreach_system_key
values ininventories/my-customer/host_vars/<host>.yml
If you want to set/override a variable for:
- all:
inventories/my-customer/group_vars/all.yml
. - a group:
inventories/my-customer/group_vars/<group>.yml
. - a host:
inventories/my-customer/host_vars/<host>.yml
.
Testing
Make sure Ansible can connect to all the hosts:
ansible -i inventories/my-customer -m ping all
If it works, it should looks like this:
mymediaserver | SUCCESS => {
"changed": false,
"ping": "pong"
}
mymediaworker | SUCCESS => {
"changed": false,
"ping": "pong"
}
mymediavault | SUCCESS => {
"changed": false,
"ping": "pong"
}