Skip to content

Latest commit

 

History

25 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Home Server - Ansible Deployment

Automated deployment of tibia-mkt to a home server via Ansible.

Prerequisites

  1. SSH key setup on your Ansible node:

    ssh-keygen -t ed25519 -C "ansible"
    ssh-copy-id -i ~/.ssh/ansible.pub [server-ip]
  2. Create ansible_vault_password.txt (gitignored) with your vault password.

Usage

# Full deployment (build + deploy + migrate + health check)
make run

# Build artifact only (localhost)
make build-only

# Deploy without rebuilding (uses existing artifact)
make deploy-no-build

# Update env vars and restart containers only
make config-only

# Run pre-flight checks only
make preflight

Or with tags directly:

ansible-playbook tibia-mkt-playbook.yml -i inventory.yml \
  -e @ansible_vault.enc --key-file ~/.ssh/ansible \
  --ask-become-pass --vault-password-file ansible_vault_password.txt \
  --tags "deploy,health"

Vault

To encrypt or re-encrypt the vault file:

ansible-vault encrypt ansible_vault.enc

Architecture

Role Runs On Purpose
pre-flight Remote Connectivity, disk space, DB reachability
tibia-mkt-zip Localhost Create deployment artifact
docker-install Remote Install Docker Engine + plugins
tibia-mkt-build Remote Extract artifact, backup old deployment
tibia-mkt-set-env-vars Remote Generate .env (mode 0600)
tibia-mkt-run Remote Docker compose down/up
tibia-mkt-run-migrations Remote Run PostgreSQL migrations (idempotent)
health-check Remote Verify containers + app health
cleanup Remote Remove temp files

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages