add github actions

This commit is contained in:
Jun Kurihara 2022-07-05 21:44:55 +09:00
commit baa23e5925
No known key found for this signature in database
GPG key ID: 48ADFD173ED22B03
4 changed files with 74 additions and 0 deletions

1
.github/FUNDING.yml vendored Normal file
View file

@ -0,0 +1 @@
github: junkurihara

27
.github/dependabot.yml vendored Normal file
View file

@ -0,0 +1,27 @@
# Basic dependabot.yml file with
# minimum configuration for two package managers
version: 2
updates:
# Enable version updates for cargo
- package-ecosystem: "cargo"
# Look for `Cargo.toml` and `lock` files in the `root` directory
directory: "/"
# Check the crates.io for updates every day (weekdays)
schedule:
interval: "daily"
# Enable version updates for Docker
- package-ecosystem: "docker"
# Look for a `Dockerfile` in the `root` directory
directory: "/"
# Check for updates everyday
schedule:
interval: "daily"
# Enable version updates for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
# Check for updates everyday
interval: "daily"

34
.github/workflows/docker_build_push.yml vendored Normal file
View file

@ -0,0 +1,34 @@
name: Build and Publish Docker
on:
push:
branches:
- main
jobs:
build_and_push:
runs-on: ubuntu-latest
env:
IMAGE_NAME: rpxy
steps:
- name: checkout
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v3
with:
context: .
push: true
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/${{ env.IMAGE_NAME }}:latest
file: ./Dockerfile

12
docker-compose.yml Normal file
View file

@ -0,0 +1,12 @@
version: "3"
services:
rpxy-rp:
image: jqtype/rpxy
container_name: rpxy
restart: unless-stopped
ports:
- 127.0.0.1:8080:8080
tty: false
privileged: true
volumes:
- ./config-example.toml:/etc/rpxy.toml:ro