Deploy P4 on Microsoft Azure | Admin
If you are the P4 administrator, you need to deploy P4 Server and configure it for your team. You can host P4 Server in your own cloud instance on Microsoft Azure. You deploy P4 using an Azure template.
On this page:
Prerequisites
Before you deploy P4 on Azure, you must have an Azure account.
Costs
For P4 on Azure, you only pay for the infrastructure you use. P4 is free for up to five users and less than 20 workspaces. If you have a larger team, contact Perforce Sales to get additional licenses.
Calculate your potential costs using the Azure pricing calculator.
Step 1: Sign up and subscribe
- Sign up for P4 on Azure. You will receive an email from Perforce with a link to the Azure template.
-
In the email, click the template link. Log in to your Azure account if needed.
-
On the Perforce - Enhanced Studio Pack page, click Get It Now.
-
In the Create this app in Azure dialog box, click Continue.
-
On the the Perforce - Enhanced Studio Pack page, click Create.
The Create Perforce Enhanced Studio Pack page opens.
Step 2: Define your Azure environment
On the Create Perforce Enhanced Studio Pack page, configure your P4 on Azure subscription. When you complete information on a tab, click Next to go to the next step.
Basics tab
All fields are required.
| Section | Field | Description |
|---|---|---|
| Project details | Subscription | The existing Azure subscription to use to deploy P4. An Azure account can have multiple subscriptions. If you do not have an Azure subscription, you can calculate your potential costs using the Azure pricing calculator. |
| Resource group | The resource group to use for P4. Multiple resources will be created and placed in one resource group. You can easily see which items are related to the deployment. It is best practice to create a new resource group specific to the P4 deployment, but you can use an existing group. To create a new resource group, click Create new. Use the following naming convention: perforce-${environment}-${team/department} |
|
| Instance details | Region | Select the region closest to your end users or a region that meets your compliance and security needs. |
| Environment | Used for resource naming and the tag on all resources. Default is prod. Do not change the name unless your organization requires a different name. |
|
| Linux account details |
SSH public key source |
To set up SSH, upload an existing key or create a new one. To learn more, see the Azure documentation. Some administrative actions require SSH access, such as operating system updates, product updates, reviewing logs, or expanding volume size. Daily use does not require SSH. |
Virtual Network Configuration tab
-
Set values for the Virtual network, Public subnet, and Private subnet fields.
It is best practice to create a new Azure virtual network, but you can use an existing one. Use your organization’s network naming convention. If you will be using an existing VNet, map the Public Subnet and Private Subnet fields to your existing public and private subnets.
-
In the IP range to allow access from field, replace 1.1.1.1 with your IPv4 address. Find your IP address
Unless there is a continuous block of IP addresses that need to be whitelisted, use
/32. You can always add and delete IP addresses after deployment
P4 Configuration tab
Define how to set up P4. To get started, you can use all the default fields on this tab. Depending on how you are using P4 and your specific use cases, you may need to increase or decrease values based on file size and number of files in your environment.
If you know how much data you are using today, you may consider adjusting your Disk size for Depot to 1.5 times your current usage.
Optional: P4 Plan (formerly Hansoft) Configuration tab
To use the P4 Plan project management tool, select true in the Deploy Hansoft field.
P4 Plan will be deployed to your Azure environment on its own server. Do not adjust resource defaults for initial setup.
Optional: P4 Code Review Configuration tab
To use P4 Code Review, the code review tool for P4, select true in the Deploy P4 Code Review field.
P4 Code Review will be deployed to your Azure environment on its own server. Do not adjust resource defaults for initial setup.
Review + create tab
After you define your environment, you are ready to review the settings and deploy.
-
On the Review + create tab, review the settings. If validation fails, go back and fix any missing or incorrect information.
-
To start deployment, click Create. Keep the deployment status page open to help with post-deployment configuration.
Step 3: Find and note your deployment outputs
When deployment is complete, find the deployment outputs you need to connect to P4. This information is on the main page for your deployment, which is displayed when deployment is complete.
Your deployment name is perforce.perforce-enhanced-studio-pack-#, where # indicates the unique number for your deployment.
-
Click the Outputs tab.
All outputs needed to connect to P4, other Perforce applications, and the Windows workstation instances are displayed.
If you navigated away from the deployment page, to get to the deployment outputs, search for Resource groups in the search field. Click the name of the resource group for your P4 deployment. Expand Settings and click Deployments. Find and click your deployment. Click Outputs to view your deployment outputs.
-
Note the following values. You will need these values later.
Value Description helixCoreInstanceIDInstance ID for the new P4 instance p4CommitPublicIPPublic IP address for P4 Server hansoftPublicIP Public IP address for P4 Plan Server swarmPublicIP Public IP address for P4 Code Review
Step 4: Optional - Update firewall rules
If you have users who will be connecting to P4 from a different IP address than the one used to deploy, you need to update your firewall rules to grant them access.
-
Follow the Azure instructions for creating a security rule in your network security group.
-
Add a rule for each user/IP address. Each user will need to provide you with their IP address in IPv4 format. Following are the port numbers for each product the user may need access to.
Product Service type Port P4 TCP 1666 P4 Code Review HTTP 80 P4 Plan TCP 52560
P4 credentials
P4 clients
Use the following details to connect to P4 Server from P4 clients. You need the deployment outputs you previously noted.
| Value | Format | Example |
|---|---|---|
| Server | ssl:P4CommitPublicIP:1666
Replace P4CommitPublicIP with the value you noted |
ssl:52.186.76.48:1666
|
| User | perforce
|
perforce
|
| Password | HelixCoreInstanceID you noted |
i-0d25def7ae812ce0a
|
P4 operating system
To connect to the P4 operating system, use the following credentials:
-
Username: rocky
-
Server: P4CommitPublicIP
Log in to the P4 operating system
To log in to the P4 operating system, use the following command:
ssh -I /path-to-ssh-private-key rocky@P4CommitPublicIP
- Replace path-to-ssh-private-key with the path to your private key.
- Replace P4CommitPublicIP with the value you noted in your deployment outputs.
Example: ssh -I /path rocky@52.186.76.48:1666
To perform operating system administration, you can become the root user using the following command:
sudo -s
Perform P4 administration tasks
To perform administrative tasks on P4, switch to the perforce user and log in to P4 Server using the following commands:
sudo su - perforce p4login -v 1
You now have the P4 CLI binaries in your $PATH and can run any p4 commands, such as p4 info.
What's next
Next, download and install P4 Visual Client (P4V), which allows you to work with versioned files. Installing P4V also installs the P4 Admin by default. You will use these tools to configure security and add users in later steps. You will also install other tools that you might use when working with P4.
Go to Step 3: Download and install P4V and other client applications.