ansible-collections / ansible-collections/google.cloud

Cannot create instance group with size bigger than one

Open
#596 1 comment 0 reactions 0 assignees View on GitHub
stale
Dominant language
Python
Stars
105
Forks
144
Avg merge
5d 10h
Merged PRs (30d)
4

Description

##### SUMMARY
The example described in the [docs](https://docs.ansible.com/ansible/latest/collections/google/cloud/gcp_compute_instance_group_manager_module.html#examples) is not working because when the instance group is created cannot scale to 3 because there's been only one IP address created.

##### ISSUE TYPE
- Bug Report

##### COMPONENT NAME
gcp_compute_instance_template and gcp_compute_instance_group_manager

##### ANSIBLE VERSION
```paste below
ansible [core 2.14.4]
config file = /Users/ausias/Documents/github/hopr-devops/ansible/ansible.cfg
configured module search path = ['/Users/ausias/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules', '/Users/ausias/Documents/github/hopr-devops/ansible', '/Users/ausias/Documents/github/hopr-devops/ansible/playbooks/k8s/kubespray/library']
ansible python module location = /opt/homebrew/Cellar/ansible/7.4.0/libexec/lib/python3.11/site-packages/ansible
ansible collection location = /Users/ausias/.ansible/collections:/usr/share/ansible/collections
executable location = /opt/homebrew/bin/ansible
python version = 3.11.2 (main, Mar 24 2023, 00:13:59) [Clang 14.0.0 (clang-1400.0.29.202)] (/opt/homebrew/Cellar/ansible/7.4.0/libexec/bin/python3.11)
jinja version = 3.1.2
libyaml = True
```

##### COLLECTION VERSION

```paste below

# /opt/homebrew/Cellar/ansible/7.4.0/libexec/lib/python3.11/site-packages/ansible_collections
Collection Version
----------------- -------
community.general 6.5.0

# /Users/ausias/.ansible/collections/ansible_collections
Collection Version
----------------- -------
community.general 5.7.0
```

##### CONFIGURATION

```paste below
CONFIG_FILE() = /Users/ausias/Documents/github/hopr-devops/ansible/ansible.cfg
DEFAULT_MODULE_PATH(/Users/ausias/Documents/github/hopr-devops/ansible/ansible.cfg) = ['/Users/ausias/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules', '/Users/ausias/Documents/github/hopr-devops/ansible', '/Users/ausias/Documents/github/hopr-devops/ansible/playbooks/k8s/kubespray/library']
DEFAULT_ROLES_PATH(/Users/ausias/Documents/github/hopr-devops/ansible/ansible.cfg) = ['/Users/ausias/.ansible/roles', '/Users/ausias/Documents/github/ansible-roles', '/Users/ausias/Documents/github/hopr-devops/ansible/playbooks/k8s/kubespray/roles']
HOST_KEY_CHECKING(/Users/ausias/Documents/github/hopr-devops/ansible/ansible.cfg) = False
```

##### OS / ENVIRONMENT

##### STEPS TO REPRODUCE
- Create a playbook like the one described in the docs
- While scaling the instance group this message error appears `Instance 'ig-europe-x6s1' creation failed: External IP address: 34.34.9.219 is already in-use.`

```yaml

```

Contributor guide

Open the contributing guide

Research direction

Start with the linked gcp_compute_instance_group_manager documentation example and reproduce the scaling step using the reported Ansible and collection versions. Then inspect the gcp_compute_instance_template and gcp_compute_instance_group_manager entry points for external IP handling; done means the group can scale to three instances without reusing an IP address.

Written by the indexing model from the issue text.

Assessment

Tech stack
google-cloud, python
Domain
cloud, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.