commit 5164abb6cfddbe9fb9a40122c44d034e1d9edc1b Author: Lauri Võsandi Date: Fri Apr 22 01:15:48 2022 +0300 Initial commit diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..e7b5dfa --- /dev/null +++ b/.drone.yml @@ -0,0 +1,2 @@ +kind: template +load: docker.yaml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1a44989 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.save diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..4681a42 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,16 @@ +FROM python:alpine +RUN apk add git bash openssh curl +RUN pip install pymongo +ADD ssh_config /etc/ssh/ + +# Inject public SSH key of git.k-space.ee +RUN bash -c "ssh-keyscan -t ecdsa git.k-space.ee >> /etc/ssh/ssh_known_hosts" + +# For git commits use user `minion`, note that this is distinct from user +# used for SSH authentication, including one going towards git.k-space.ee +RUN git config --global user.email "minion@k-space.ee" +RUN git config --global user.name "Minion" + +LABEL name="k-space/microscript-base" \ + version="rc" \ + maintainer="Lauri Võsandi " diff --git a/README.md b/README.md new file mode 100644 index 0000000..8f051bd --- /dev/null +++ b/README.md @@ -0,0 +1,12 @@ +# Introduction + +This repository is a skeleton for a microscript container image -- that +is container that get's started either by Kubernetes Job or CronJob and +that does not run forever. + +In this particular example MongoDB is included in the setup. + +# How to use this repository + +Just mount scripts using ConfigMap and run +`harbor.k-space.ee/k-space/microscript-base` directly from Kubernetes diff --git a/ssh_config b/ssh_config new file mode 100644 index 0000000..58584f5 --- /dev/null +++ b/ssh_config @@ -0,0 +1,4 @@ +Host * + IdentityFile /config/ssh_identity + UserKnownHostsFile /config/ssh_known_hosts + HostKeyAlgorithms +ssh-rsa # TODO: Remove this after ROS7 upgrades