Skip to content
Merged
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
71 changes: 71 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
# SPDX-FileCopyrightText: 2025 INDUSTRIA DE DISEÑO TEXTIL S.A. (INDITEX S.A.)
# SPDX-License-Identifier: Apache-2.0
name: 🚀 Release
permissions: read-all

on:
release:
types:
- created

env:
REGISTRY: ghcr.io
IMAGE_NAME: inditextech/redkey-robin

jobs:
release:
name: 🏷️ Release
runs-on: ubuntu-latest
outputs:
version: ${{ steps.version.outputs.version }}
user_agent_version: ${{ steps.version.outputs.user_agent_version }}
steps:
- name: 🛎️ Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
fetch-depth: 0
- name: 📝 Load Robin version
id: version
run: |
echo "version=$(make version)" >> $GITHUB_OUTPUT
echo $GITHUB_OUTPUT

check:
name: 🔎 Check versions
needs: release
runs-on: ubuntu-latest
steps:
- name: 🔎 Check versions
run: |
echo "version: ${{ needs.release.outputs.version }}"
echo "tag_name: ${{ github.event.release.tag_name }}"

if [ "${{ github.event.release.tag_name }}" != "${{ needs.release.outputs.version }}" ]; then
echo "Version in Makefile does not match release tag"
exit 1
fi

build:
name: 🛠️ Build Robin image
needs: check
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
steps:
- name: 🛎️ Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
fetch-depth: 0

- name: 🔐 Login into ${{ env.REGISTRY }}
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: 🏗️ Build and push Robin image
run: |
make docker-build IMAGE_TAG_BASE=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
make docker-push IMAGE_TAG_BASE=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# SPDX-FileCopyrightText: 2025 INDUSTRIA DE DISEÑO TEXTIL S.A. (INDITEX S.A.)
# SPDX-License-Identifier: Apache-2.0
golang 1.25.6
golang 1.25.7
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
### Build stage

# Define the desired Golang version
ARG GOLANG_VERSION=1.25.6
ARG GOLANG_VERSION=1.25.7

# Use an official Golang image with a specific version based on Debian
FROM golang:${GOLANG_VERSION}-trixie AS builder
Expand Down
21 changes: 11 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@
.DEFAULT_GOAL := help
SHELL := /bin/bash

name := redkeyrobin
version := 1.0.0
redis_client_version := 8.2.3
golang_version := 1.25.6
delve_version := 1.25
package := github.com/inditextech/$(name)
NAME := redkeyrobin
VERSION := 0.1.0
REDIS_CLIENT_VERSION := 8.2.3
GOLANG_VERSION := 1.25.7
DELVE_VERSION := 1.25
PACKAGE := github.com/inditextech/$(NAME)

# Image URL to use for building/pushing image.
IMG ?= redkey-robin:$(version)
IMAGE_TAG_BASE ?= localhost:5001/redkey-robin
IMG ?= $(IMAGE_TAG_BASE):$(VERSION)

# .............................................................................
# DONT TOUCH THIS SECTION
Expand Down Expand Up @@ -206,19 +207,19 @@ dev-build: ## Build robin binary.
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 GO111MODULE=on go build -o bin/robin ./cmd/main.go

docker-build: ## Build docker image with the manager (uses `${IMG}` image name).
docker build -t ${IMG} --build-arg REDIS_CLIENT_VERSION=${redis_client_version} --build-arg GOLANG_VERSION=${golang_version} .
docker build -t ${IMG} --build-arg REDIS_CLIENT_VERSION=${REDIS_CLIENT_VERSION} --build-arg GOLANG_VERSION=${GOLANG_VERSION} .

docker-push: ## Push docker image with the manager (uses `${IMG}` image name).
docker push ${IMG}

dev-docker-build: ## Build docker image with the manager for development (uses `${IMG_DEV}` image name).
docker build -t ${IMG_DEV} --build-arg REDIS_CLIENT_VERSION=${redis_client_version} --build-arg GOLANG_VERSION=${golang_version} .
docker build -t ${IMG_DEV} --build-arg REDIS_CLIENT_VERSION=${REDIS_CLIENT_VERSION} --build-arg GOLANG_VERSION=${GOLANG_VERSION} .

dev-docker-push: ## Push docker image with the manager for development (uses `${IMG_DEV}` image name).
docker push ${IMG_DEV}

debug-docker-build: ## Build docker image for debugging from debug.Dockerfile (uses `${IMG_DEBUG}` image name).
docker build -t ${IMG_DEBUG} -f debug.Dockerfile --build-arg REDIS_CLIENT_VERSION=${redis_client_version} --build-arg GOLANG_VERSION=${golang_version} --build-arg DELVE_VERSION=${delve_version} .
docker build -t ${IMG_DEBUG} -f debug.Dockerfile --build-arg REDIS_CLIENT_VERSION=${REDIS_CLIENT_VERSION} --build-arg GOLANG_VERSION=${GOLANG_VERSION} --build-arg DELVE_VERSION=${DELVE_VERSION} .

debug-docker-push: ## Push docker image for debugging from debug.Dockerfile (uses `${IMG_DEBUG}` image name).
docker push ${IMG_DEBUG}
Expand Down
30 changes: 26 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,36 @@ SPDX-FileCopyrightText: 2025 INDUSTRIA DE DISEÑO TEXTIL S.A. (INDITEX S.A.)
SPDX-License-Identifier: Apache-2.0
-->

<!-- Add relevant badges here -->
![GitHub License](https://img.shields.io/github/license/InditexTech/redkeyrobin)
<div align="center">

# RedKey Robin

RedKey Robin is a faithful partner who assists the [RedKey Operator](https://github.com/InditexTech/redkeyoperator) in the dangerous Gotham. It is designed to help the Operator (Batman) in its duties and deployed by the RedKey Operator as a Deployment.
**RedKey Robin is a faithful partner who assists the [RedKey Operator](https://github.com/InditexTech/redkeyoperator) in the dangerous Gotham.**

## Features
Designed to help the Operator (Batman) in its duties and seamlessly deployed by the RedKey Operator as a Deployment.

[![GitHub License](https://img.shields.io/github/license/InditexTech/redkeyrobin)](LICENSE)
[![GitHub Release](https://img.shields.io/github/v/release/InditexTech/redkeyrobin)](https://github.com/InditexTech/redkeyrobin/releases)
[![Go Version](https://img.shields.io/github/go-mod/go-version/InditexTech/redkeyrobin)](go.mod)
[![Build Status](https://img.shields.io/github/actions/workflow/status/InditexTech/redkeyrobin/ci.yml?branch=main)](https://github.com/InditexTech/redkeyrobin/actions)

[![Kubernetes](https://img.shields.io/badge/Kubernetes-326CE5?style=flat&logo=kubernetes&logoColor=white)](https://kubernetes.io/)
[![Operator SDK](https://img.shields.io/badge/Operator%20SDK-326CE5?style=flat&logo=kubernetes&logoColor=white)](https://sdk.operatorframework.io/)
[![Go](https://img.shields.io/badge/Go-00ADD8?style=flat&logo=go&logoColor=white)](https://golang.org/)
[![REUSE Compliance](https://img.shields.io/badge/REUSE-compliant-green)](https://reuse.software/)

[![GitHub Issues](https://img.shields.io/github/issues/InditexTech/redkeyrobin)](https://github.com/InditexTech/redkeyrobin/issues)
[![GitHub Pull Requests](https://img.shields.io/github/issues-pr/InditexTech/redkeyrobin)](https://github.com/InditexTech/redkeyrobin/pulls)
[![GitHub Stars](https://img.shields.io/github/stars/InditexTech/redkeyrobin?style=social)](https://github.com/InditexTech/redkeyrobin/stargazers)
[![GitHub Forks](https://img.shields.io/github/forks/InditexTech/redkeyrobin?style=social)](https://github.com/InditexTech/redkeyrobin/network/members)

[📖 Documentation](./docs) • [🤝 Contributing](./CONTRIBUTING.md) • [📝 License](./LICENSE)

</div>

---

## Key Features

- Redis metrics
- Monitors the RedKey Cluster to ensure it is well-formed and balanced, performing the necessary operations to achieve this
Expand Down
2 changes: 1 addition & 1 deletion debug.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
### Build stage

# Define the desired Golang version
ARG GOLANG_VERSION=1.25.6
ARG GOLANG_VERSION=1.25.7

# Use an official Golang image with a specific version based on Debian
FROM golang:${GOLANG_VERSION}-trixie AS builder
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

module github.com/inditextech/redkeyrobin

go 1.25.6
go 1.25.7

require (
github.com/go-redis/redismock/v9 v9.2.0
Expand Down
Loading