initial commit

This commit is contained in:
quackerd 2020-07-09 15:47:27 +08:00
parent 6c25fee844
commit 5685df228e
Signed by: d
GPG Key ID: 590A22374D0B819F
3 changed files with 48 additions and 0 deletions

18
.drone.yml Normal file
View File

@ -0,0 +1,18 @@
kind: pipeline
type: docker
name: default
trigger:
branch:
- master
steps:
- name: build
image: plugins/docker
settings:
username:
from_secret: docker_username
password:
from_secret: docker_password
repo: quackerd/frp
tags: latest

22
Dockerfile Normal file
View File

@ -0,0 +1,22 @@
#
# Dockerfile for frp
# Based on: vimagick/frp
#
FROM alpine
ENV FRP_VERSION 0.31.2
ENV FRP_URL https://github.com/fatedier/frp/releases/download/v${FRP_VERSION}/frp_${FRP_VERSION}_linux_amd64.tar.gz
WORKDIR /opt/frp
RUN set -xe \
&& apk add --no-cache curl tar \
&& curl -sSL $FRP_URL | tar xz --strip 1 \
&& apk del curl tar
COPY ./run.sh /opt/run.sh
RUN chmod +x /opt/run.sh
CMD ["/opt/run.sh"]

8
run.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/sh
if [ -z $SERVER ] ; then
frpc -c frpc.ini
else
frps -c frps.ini
fi