How to Create Security Groups for Public Cloud [New]

How to Create Security Groups for Public Cloud [New]

3 min read

This article explains how to create and configure a security group for your Public Cloud Instances.

idea e1761126179182 A security group acts as a virtual firewall for your Public Cloud instances, allowing you to control inbound and outbound traffic.

Prerequisites

  • Access to the Customer Portal account
  • Enabled Leaseweb Public Cloud account.

Steps to Follow

  1. Log in to the Customer Portal
  • Open your browser and go to the Customer Portal.
  • Sign in with your Leaseweb account credentials.
  1. Navigate to Security Groups
  • From the left-hand menu, go to Public Cloud.
  • Under the submenu, click Security Groups.
    • You will see a list of all available security groups within the current region
  1. Create a New Security Group
  • Click the Create Security Group button.
  • Fill in the details:
    • Name: Provide a descriptive name (e.g., web-frontend-sg).
    • Description: Briefly explain the purpose (e.g., “Allows HTTP/HTTPS traffic for web servers”).
    • Stateful: The system remembers the traffic that has been allowed and automatically authorizes the return flow without needing to configure an explicit rule in the opposite direction.

Back to the top ↑

  1. Add Firewall Rules
  • Click on the security group, to access the security group details.
  • Click + New Firewall Rule.
    • A pop-up window will appear
  • Select the Protocol from the dropdown (TCP, UDP, ICMP, or ALL)
  • Enter:
    1. Direction: Select ingress or egress traffic direction.
    2. Source Network: Define the IP/CIDR that can access. 
  • Click Save to add the rule.
  1. Save the Security Group
  • Once you’ve added the necessary rules, click Create Group.
    • Your new security group will now appear in the list

How to Attach a Security Group While Launching an Instance

  1. Navigate to Public Cloud -> Instances
  2. Launch a New Instance:
    1. Click Launch an Instance.
    2. Enter a name for your instance.
    3. Select an OS image.
    4. Choose an instance type.
  3. Attach a Security Group:
    1. In the Security Groups section, click Attach Groups.
    2. Select a security group that has already been created.
    3. Click Confirm.
      • Your selected security group will now be attached to the instance.
  4. Continue with the remaining steps to launch your instance.

How to Attach a Security Group to an Existing Instance

  1. Go to your Instance Details page.
  2. Navigate to the Security tab.
  3. Stop the instance if it is currently running
    • warning e1759326998735 Security group changes can only be applied when the instance is stopped.
  4. Click on Attach Security Groups:
    1. A list of available security groups will appear.
    2. You can select one or multiple groups to attach.
    3. Already attached groups will be marked as selected or greyed out.
  5. After choosing the desired security groups, click Confirm to apply the changes.

Back to the top ↑

How to Remove Security Groups from an Instance

  1. Go to your Instance Details page.
  2. Navigate to the Security tab.
  3. Select the security groups you want to remove.
  4. Click Detach Selected Security Group(s).
    • A confirmation message will appear: “Are you sure you want to detach the selected Security Groups?”
  5. Confirm by clicking Detach again.
  6. The selected security groups will be removed from your instance.