Skip to content

Commit c558c33

Browse files
authored
Merge pull request #1 from infraspecdev/docs-updates
Update README
2 parents bffb399 + b8e84bc commit c558c33

File tree

1 file changed

+72
-0
lines changed

1 file changed

+72
-0
lines changed

README.md

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,73 @@
11
# gitlab-docker-runner
2+
3+
This Terraform module creates a GitLab Runner on AWS using one or more EC2 instances. The runner is registered with the provided GitLab instance and is capable of running Docker-based builds. Additionally, the module creates an AWS Key Pair that can be used to SSH into the EC2 instances.
4+
5+
## Usage
6+
7+
```hcl
8+
module "gitlab_docker_runner" {
9+
source = "https://github.com/infraspecdev/terraform-aws-gitlab-docker-runner"
10+
11+
ami_id = "ami-0675b5ed3c8c1f754"
12+
instance_type = "t2.micro"
13+
instance_count = 1
14+
vpc_security_group_ids = ["sg-0b0b0b0b0b0b0b0b0"]
15+
subnet_id = "subnet-0b0e1c4b5b1b1b1b1"
16+
gitlab_url = "https://gitlab.example.com"
17+
runner_registration_token = "runner-registration-token-here"
18+
ssh_public_key = "ssh-public-key-here"
19+
}
20+
```
21+
22+
<!-- BEGIN_TF_DOCS -->
23+
## Requirements
24+
25+
| Name | Version |
26+
|------|---------|
27+
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | ~> 1.3.0 |
28+
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | >= 4.49.0 |
29+
30+
## Providers
31+
32+
| Name | Version |
33+
|------|---------|
34+
| <a name="provider_aws"></a> [aws](#provider\_aws) | 4.49.0 |
35+
36+
## Modules
37+
38+
No modules.
39+
40+
## Resources
41+
42+
| Name | Type |
43+
|------|------|
44+
| [aws_instance.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/instance) | resource |
45+
| [aws_key_pair.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/key_pair) | resource |
46+
47+
## Inputs
48+
49+
| Name | Description | Type | Default | Required |
50+
|------|-------------|------|---------|:--------:|
51+
| <a name="input_additional_tags"></a> [additional\_tags](#input\_additional\_tags) | Additional tags to apply to the resources | `map(string)` | `{}` | no |
52+
| <a name="input_ami_id"></a> [ami\_id](#input\_ami\_id) | AMI to use for the instance | `string` | `"ami-0675b5ed3c8c1f754"` | no |
53+
| <a name="input_docker_image"></a> [docker\_image](#input\_docker\_image) | Docker image to use | `string` | `"alpine"` | no |
54+
| <a name="input_gitlab_url"></a> [gitlab\_url](#input\_gitlab\_url) | URL of your Gitlab instance | `string` | n/a | yes |
55+
| <a name="input_instance_count"></a> [instance\_count](#input\_instance\_count) | Number of instances to provision | `number` | n/a | yes |
56+
| <a name="input_instance_type"></a> [instance\_type](#input\_instance\_type) | Type of instance to provision | `string` | n/a | yes |
57+
| <a name="input_run_untagged_jobs"></a> [run\_untagged\_jobs](#input\_run\_untagged\_jobs) | Should run untagged jobs or not | `bool` | `true` | no |
58+
| <a name="input_runner_description"></a> [runner\_description](#input\_runner\_description) | Description for Gitlab Runners | `string` | `"Docker Runner"` | no |
59+
| <a name="input_runner_locked"></a> [runner\_locked](#input\_runner\_locked) | Should Lock the runners or not | `bool` | `false` | no |
60+
| <a name="input_runner_registration_token"></a> [runner\_registration\_token](#input\_runner\_registration\_token) | Registration token for Gitlab Runners | `string` | n/a | yes |
61+
| <a name="input_runner_tags"></a> [runner\_tags](#input\_runner\_tags) | Tags for Gitlab Runners for filtering | `list(string)` | <pre>[<br> "docker",<br> "aws"<br>]</pre> | no |
62+
| <a name="input_ssh_public_key"></a> [ssh\_public\_key](#input\_ssh\_public\_key) | Existing SSH public key to use for the key pair | `string` | `null` | no |
63+
| <a name="input_subnet_id"></a> [subnet\_id](#input\_subnet\_id) | VPC Subnet ID to launch in | `string` | n/a | yes |
64+
| <a name="input_vpc_security_group_ids"></a> [vpc\_security\_group\_ids](#input\_vpc\_security\_group\_ids) | List of security group IDs to associate | `list(string)` | n/a | yes |
65+
66+
## Outputs
67+
68+
No outputs.
69+
<!-- END_TF_DOCS -->
70+
71+
## Authors
72+
73+
Module managed by [Infraspec](https://github.com/infraspecdev).

0 commit comments

Comments
 (0)