Skip to content

Mick-Mi/docker-sdp-perforce-server-for-unreal-engine

 
 

Repository files navigation

docker-sdp-perforce-server-for-unreal-engine

Docker perforce server using SDP(Server Deployment Package), configured for Unreal Engine(a unicode, case-insensitive Perforce server with Unreal Engine's recommended Typemap).

How to use

1. Get the Docker image

You can get the Docker image from Docker Hub or build it yourself.

  • Use prebuilt image

You can use the prebuilt image from Docker Hub: zhaojunmeng/sdp-perforce-server-for-unreal-engine

  • Build it yourself

In the project root directory, use the following command to build the image (using p4d version r23.1 as default).

docker build . -t sdp-perforce-server-for-unreal-engine:r23.1 --no-cache
    

If you want to run the container on NAS, you must save the image as a tar file, so you can upload it to the NAS.

docker save sdp-perforce-server-for-unreal-engine:r23.1 -o sdp-perforce-server-for-unreal-engine-r23.1.tar

Available --build-arg:

ARG default value meaning
OS_DISTRO jammy ubuntu version
SDP_VERSION .2023.1.29621 SDP version
P4_VERSION r23.1 P4 binaries version
P4_BIN_LIST p4,p4d Helix binaries, for minal usage, only p4 and p4d need to be downloaded

Also you can tweak the .cfg files in the "files_for_run" folder, when you build your own image.

2. Run the container

Here's an example running on Docker Desktop.

To run the container from image, the following is required:

Ports: port to connect

Volumes: 4 folders to mount for "/hxmetadata", "/hxdepots", "/hxlogs", "/p4" on the container.(The 4 folders is explained here: Volume Layout and Hardware)

Docker parameters

After clicked "Run" button, see the Docker Logs and wait perforce server(p4d) to start in a few seconds.

Logs output

3. Connect to Perforce server

After the container's first setup, use P4Admin to login to Perforce to create new depots, groups and users.

Server: the ip address or domain of your server, for Docker Desktop, it's 127.0.0.1:1666.

User: the default and the only user is "perforce"(configured in p4-protect.cfg), enter the server ip

Login as user perforce

After click "OK", you must change the default password for user "perforce" (because security level is set to 3).

The old password is F@stSCM! by default (configured in Dockerfile: P4_PASSWD).

Change default password

After login, you can create new depots, groups and users.

在群晖(NAS)上面如何运行,参考:如何在群晖(NAS)上,部署一个为UnrealEngine定制的Perforce服务器

Enjoy!

Disclaimer

I decline any responsibility in case of data loss or in case of a difficult (or even impossible) maintenance if you use this solution.
I did this as a hobby for a small project.
If you still want to use it for your project, I would suggest to setup or to do regularly backups of your project.

About

Docker Perforce server using SDP, configured for Unreal Engine, prebuilt Docker image can be found at https://registry.hub.docker.com/r/zhaojunmeng/sdp-perforce-server-for-unreal-engine/

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Shell 90.2%
  • Dockerfile 9.8%