mirror of
https://github.com/sstent/containers.git
synced 2025-12-06 08:01:51 +00:00
adding gitbackup container
This commit is contained in:
40
.github/workflows/github-backup.yml
vendored
Normal file
40
.github/workflows/github-backup.yml
vendored
Normal file
@@ -0,0 +1,40 @@
|
||||
on:
|
||||
push:
|
||||
branches: [ master ]
|
||||
paths:
|
||||
- 'github-backup/*'
|
||||
- '.github/workflows/github-backup.yml'
|
||||
pull_request:
|
||||
branches: [ master ]
|
||||
|
||||
jobs:
|
||||
docker:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
-
|
||||
name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
||||
-
|
||||
name: Log into registry
|
||||
uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
-
|
||||
name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v1
|
||||
-
|
||||
name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
-
|
||||
name: Build and push
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
context: github-backup/
|
||||
platforms: linux/arm/v7, Linux/amd64, linux/arm64/v8
|
||||
push: true
|
||||
file: github-backup/Dockerfile
|
||||
tags: ghcr.io/sstent/github-backup:latest
|
||||
|
||||
12
github-backup/Dockerfile
Normal file
12
github-backup/Dockerfile
Normal file
@@ -0,0 +1,12 @@
|
||||
FROM alpine:latest
|
||||
|
||||
RUN echo "http://dl-cdn.alpinelinux.org/alpine/edge/testing/" >> /etc/apk/repositories
|
||||
|
||||
RUN apk add --no-cache python3 && \
|
||||
python3 -m ensurepip && \
|
||||
rm -r /usr/lib/python*/ensurepip && \
|
||||
pip3 install --upgrade pip setuptools && \
|
||||
if [ ! -e /usr/bin/pip ]; then ln -s pip3 /usr/bin/pip ; fi && \
|
||||
if [[ ! -e /usr/bin/python ]]; then ln -sf /usr/bin/python3 /usr/bin/python; fi
|
||||
RUN pip3 install github-backup
|
||||
ENTRYPOINT ["github-backup"]
|
||||
Reference in New Issue
Block a user