Hello, I'm Maneshwar. I'm building git-lrc, an AI code reviewer that runs on every commit. It is free, unlimited, and source-available on Github. Star Us to help devs discover the project. Do give it a try and share your feedback for improving the product.
Hello, I'm Maneshwar. I'm working on FreeDevTools online currently building **one place for all dev tools, cheat codes, and TLDRs* — a free, open-source hub where developers can quickly find and use tools without any hassle of searching all over the internet.
Hi there! I'm . Right now, I’m building a first-of-its-kind tool that helps you automatically index API endpoints across all your repositories. makes it easier to discover, understand, and interact with APIs in large infrastructures.
Redis is a high-performance in-memory key-value sto
re.
If you're deploying it with Ansible and want full control over the version and configuration (including your own redis.conf), here's a clean and repeatable setup to automate the whole thing.
We’ll go from a blank Ansible structure to a fully provisioned Redis instance running version 7.4.1, with your custom config baked in.
Project Structure
We're using a standard Ansible role layout:
ansible/
├── ansible.cfg
├── db.yml
├── hosts.ini
└── roles/
└── db/
├── tasks/
│ ├── main.yml
│ └── install_redis.yml
├── handlers/
│ └── main.yml
├── templates/
│ └── redis.conf.j2
└── ...
Step-by-Step
1. ansible.cfg
Make sure you have a minimal config:
[defaults]
# Use YAML for cleaner stdout/stderr formatting
stdout_callback = yaml
stderr_callback = yaml
# Path to inventory file
inventory = hosts.ini
# Skip SSH host key checking (useful for automation)
host_key_checking = False
# SSH connection timeout in seconds
timeout = 30
# Number of parallel hosts to configure at once
forks = 10
# Speed up Ansible by reusing SSH connections and avoiding sudo temp files
pipelining = True
[ssh_connection]
ssh_args = -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null
pipelining = True
2. hosts.ini
Define your target host:
[db]
your-redis-host ansible_user=ubuntu
Replace your-redis-host with the IP or hostname.
3. db.yml — Entry Playbook
---
- name: Install Redis on DB hosts
hosts: db
become: yes
roles:
- db
4. roles/db/tasks/main.yml
---
- import_tasks: install_redis.yml
5. roles/db/tasks/install_redis.yml
This handles installing Redis 7.4.1 via Redis’s official APT repo, plus pushing your custom config:
---
- name: Install required packages
apt:
name: ['lsb-release', 'curl', 'gpg']
state: present
update_cache: yes
- name: Add Redis GPG key
shell: |
curl -fsSL https://packages.redis.io/gpg | gpg --dearmor -o /usr/share/keyrings/redis-archive-keyring.gpg
args:
creates: /usr/share/keyrings/redis-archive-keyring.gpg
- name: Set permissions on GPG key
file:
path: /usr/share/keyrings/redis-archive-keyring.gpg
mode: '0644'
- name: Add Redis APT repo
copy:
dest: /etc/apt/sources.list.d/redis.list
content: "deb [signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https://packages.redis.io/deb {{ ansible_lsb.codename }} main"
- name: Update APT
apt:
update_cache: yes
- name: Install Redis
apt:
name: redis
state: present
- name: Copy custom redis.conf
template:
src: redis.conf.j2
dest: /etc/redis/redis.conf
owner: redis
group: redis
mode: '0644'
notify: Restart Redis
- name: Enable Redis service
systemd:
name: redis-server
enabled: yes
- name: Start Redis
systemd:
name: redis-server
state: started
6. roles/db/handlers/main.yml
---
- name: Restart Redis
systemd:
name: redis-server
state: restarted
7. roles/db/templates/redis.conf.j2
This is your custom redis.conf. You can render variables in it using Jinja2, like:
bind 0.0.0.0
port 6379
requirepass {{ redis_password | default('changeme') }}
maxmemory 256mb
maxmemory-policy allkeys-lru
You can move sensitive stuff (like redis_password) to defaults/main.yml or vault.
Running the Playbook
ansible-playbook db.yml
Verifying
SSH into your target host:
systemctl status redis-server
redis-cli -a changeme ping
You should get:
PONG
Bonus Tips
- Pin exact Redis version by installing a
.debpackage or usingapt-mark hold redis. - Add Redis log/config location to your monitoring tools.
- Use Ansible Vault to store secrets (like the password).
- Write a test playbook under
roles/db/tests/test.ymlto verify installation.
Final Thoughts
This setup gives you:
- Precise version control with Redis’s upstream APT repo
- Full override of
redis.conf - Reusable, modular Ansible role
No surprises. No apt install redis-server with some random sSystem default version. You’re in charge.
A collection of UI/UX-focused tools crafted to simplify workflows, save time, and reduce friction in searching tools/materials.
Any feedback or contributors are welcome!
It’s online, open-source, and ready for anyone to use.
👉 Check it out:
⭐ Star it on GitHub:
Let’s make it even better together.
*AI agents write code fast. They also silently remove logic, change behavior, and introduce bugs -- without telling you. You often find out in production.
git-lrc fixes this. It hooks into git commit and reviews every diff before it lands. 60-second setup. Completely free.*
Any feedback or contributors are welcome! It's online, source-available, and ready for anyone to use.
⭐ Star it on GitHub:
HexmosTech
/
git-lrc
Free, Unlimited AI Code Reviews That Run on Commit
| 🇩🇰 Dansk | 🇪🇸 Español | 🇮🇷 Farsi | 🇫🇮 Suomi | 🇯🇵 日本語 | 🇳🇴 Norsk | 🇵🇹 Português | 🇷🇺 Русский | 🇦🇱 Shqip | 🇨🇳 中文 |
git-lrc
Free, Unlimited AI Code Reviews That Run on Commit
AI agents write code fast. They also silently remove logic, change behavior, and introduce bugs -- without telling you. You often find out in production.
git-lrc fixes this. It hooks into git commit and reviews every diff before it lands. 60-second setup. Completely free.
See It In Action
See git-lrc catch serious security issues such as leaked credentials, expensive cloud operations, and sensitive material in log statements
git-lrc-intro-60s.mp4
Why
- 🤖 AI agents silently break things. Code removed. Logic changed. Edge cases gone. You won't notice until production.
- 🔍 Catch it before it ships. AI-powered inline comments show you exactly what changed and what looks wrong.
- 🔁 Build a…
Top comments (0)
Some comments may only be visible to logged-in visitors. Sign in to view all comments.