[GH-ISSUE #3478] [Feature Request] Dockerfile & docker-entrypoint.sh #2780

Closed
opened 2026-05-05 13:47:35 -06:00 by gitea-mirror · 5 comments
Owner

Originally created by @Zhou-Tx on GitHub (Jun 5, 2023).
Original GitHub issue: https://github.com/fatedier/frp/issues/3478

Describe the feature request

I would like to create a release version of frps on docker(maybe frpc can be built as well), for more and more users need to run this application on cloud-native environment.

Describe alternatives you've considered

As we know, docker container is a single-process model, thus we can put frps into a container and run with custom arguments.
Firstly, create a docker-entrypoint.sh to load custom arguments and startup frps application;
secondly, generate a multi-platform Dockerfile to build images for different os/arch, and we may push these images to docker hub.

Affected area

  • Docs
  • Installation
  • Performance and Scalability
  • Security
  • User Experience
  • Test and Release
  • Developer Infrastructure
  • Client Plugin
  • Server Plugin
  • Extensions
  • Others
Originally created by @Zhou-Tx on GitHub (Jun 5, 2023). Original GitHub issue: https://github.com/fatedier/frp/issues/3478 ### Describe the feature request I would like to create a release version of frps on docker(maybe frpc can be built as well), for more and more users need to run this application on cloud-native environment. ### Describe alternatives you've considered As we know, docker container is a single-process model, thus we can put frps into a container and run with custom arguments. Firstly, create a `docker-entrypoint.sh` to load custom arguments and startup frps application; secondly, generate a multi-platform `Dockerfile` to build images for different os/arch, and we may push these images to docker hub. ### Affected area - [X] Docs - [X] Installation - [ ] Performance and Scalability - [ ] Security - [X] User Experience - [ ] Test and Release - [ ] Developer Infrastructure - [ ] Client Plugin - [ ] Server Plugin - [ ] Extensions - [x] Others
Author
Owner

@Zhou-Tx commented on GitHub (Jun 5, 2023):

I saw there is a directory named dockerfiles which contains Dockerfile-for-frps and Dockerfile-for-frpc, but I think that it can only build a executable file but cannot startup conveniently, so I would like to create a docker-entrypoint.sh to simplify the process when starting, loading custom startup parameter included.

<!-- gh-comment-id:1577025898 --> @Zhou-Tx commented on GitHub (Jun 5, 2023): I saw there is a directory named `dockerfiles` which contains `Dockerfile-for-frps` and `Dockerfile-for-frpc`, but I think that it can only build a executable file but cannot startup conveniently, so I would like to create a `docker-entrypoint.sh` to simplify the process when starting, loading custom startup parameter included.
Author
Owner

@fatedier commented on GitHub (Jun 6, 2023):

You can check the Docker official documentation to learn how to use custom commands to start a container.

<!-- gh-comment-id:1577815442 --> @fatedier commented on GitHub (Jun 6, 2023): You can check the Docker official documentation to learn how to use custom commands to start a container.
Author
Owner

@Zhou-Tx commented on GitHub (Jun 6, 2023):

Excuse me, perhaps I didn't describe the appeal clearly. I would like to optimize the Dockerfile and publish to docker hub officially, since there isn't a unified platform standard image.

<!-- gh-comment-id:1577853631 --> @Zhou-Tx commented on GitHub (Jun 6, 2023): Excuse me, perhaps I didn't describe the appeal clearly. I would like to optimize the `Dockerfile` and publish to docker hub officially, since there isn't a unified platform standard image.
Author
Owner

@Becods commented on GitHub (Jun 6, 2023):

  1. The start-up and use of frp does not require too many parameters.

    Usually the user only needs to specify the frp configuration file, and then almost all the configuration is edited in the configuration file.

    So you can start frp with a simple command :docker run -it `pwd`/frpc.ini:/frpc.ini fatedier/frpc:v0.49.0 -c /frpc.ini

    It seems to me that starting frp via entrypoint.sh is an unnecessary operation.

  1. Several different architecture compilation operations have been implemented in the github action of frp's automatic build and push.
    da51adc276/.github/workflows/build-and-push-image.yml (L67-L68)
<!-- gh-comment-id:1578479927 --> @Becods commented on GitHub (Jun 6, 2023): 1. The start-up and use of frp does not require too many parameters.<br><br>Usually the user only needs to specify the frp configuration file, and then almost all the configuration is edited in the configuration file.<br><br>So you can start frp with a simple command :```docker run -it `pwd`/frpc.ini:/frpc.ini fatedier/frpc:v0.49.0 -c /frpc.ini```<br><br>It seems to me that starting frp via entrypoint.sh is an unnecessary operation. <br> 2. Several different architecture compilation operations have been implemented in the github action of frp's automatic build and push. https://github.com/fatedier/frp/blob/da51adc27670f495478f50634462954319e4fc14/.github/workflows/build-and-push-image.yml#L67-L68
Author
Owner

@Zhou-Tx commented on GitHub (Jun 6, 2023):

All right, it's my fault that I didn't found the image fatedier/frpc for it has not been ranked first on DockerHub https://hub.docker.com/search?q=frps

P.s. What I was originally thinking was that using command line to starup frps instead of an ini file, and you are right that starting frp via entrypoint.sh is an unnecessary operation even though using command line arguments.
Thanks a lot.

<!-- gh-comment-id:1578535998 --> @Zhou-Tx commented on GitHub (Jun 6, 2023): All right, it's my fault that I didn't found the image `fatedier/frpc` for it has not been ranked first on DockerHub <https://hub.docker.com/search?q=frps> P.s. What I was originally thinking was that using command line to starup frps instead of an ini file, and you are right that starting frp via entrypoint.sh is an unnecessary operation even though using command line arguments. Thanks a lot.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/frp#2780
No description provided.