Commit 9e412e96 authored by Raphaël Flores's avatar Raphaël Flores
Browse files

Merge branch 'chore/restart-config-server-before-deployment' into 'master'

Restart config-server before any deployment.

See merge request urgi-is/data-discovery!317
parents 604b3313 f503f009
......@@ -220,6 +220,29 @@ build-data-discovery:
APP_NAME: ${DATADISCOVERY_APP_NAME}
<<: *build_app # Merge the contents of the 'build_app' alias
.restart-config-server: &restart_config_server
stage: build
script:
- eval $(ssh-agent -s)
- ssh-add <(echo "${SSH_PRIVATE_KEY}")
- ssh -o StrictHostKeyChecking=no ${SERVER_USER}@${SERVER_IP} 'echo "Successfully connected on $(hostname)"'
- ssh ${SERVER_USER}@${SERVER_IP} "sudo systemctl restart bootapp@config-server"
- eval $(ssh-agent -k)
allow_failure: true
restart-config-server-proxmox:
variables:
SERVER_IP: ${SERVER_IP_PROXMOX}
SERVER_USER: ${SERVER_USER_PROXMOX}
<<: *restart_config_server
restart-config-server-openstack:
tags:
- openstack
variables:
SERVER_IP: ${SERVER_IP_OPENSTACK_DEV}
SERVER_USER: ${SERVER_USER_OPENSTACK}
<<: *restart_config_server
.deploy-to-vm-proxmox: &deploy_to_vm_proxmox
# Hidden job which serves as template for executed jobs below.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment