Skip to content

Instantly share code, notes, and snippets.

View Meg4R0M's full-sized avatar
🏠
Working from home

Durano "Meg4R0M" Florian Meg4R0M

🏠
Working from home
View GitHub Profile
.cicd_before_running: &cicd_before_running |
function prereq() {
echo "Preparing environment"
## Login to Harbor registry
echo "$DOCKER_PASSWORD" | docker login docker-registry.kaliop.net -u "$DOCKER_USER" --password-stdin
## Run ssh-agent (inside the build environment)
eval $(ssh-agent -s)
## Add the SSH key stored in SSH_PRIVATE_KEY variable to the agent store
echo "$SSH_PRIVATE_KEY" | tr -d '\r' | ssh-add - > /dev/null
echo "$SSH_ANCA_PRIVATE_KEY" | tr -d '\r' | ssh-add - > /dev/null