You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(sorry for deleting and reposting this comment - I thought I had gotten things mixed up, misinterpreting the results. But looks like it really is working)
@dschilling No problem; though, I'm perplexed on why this doesn't work. I'll have to dig into that a bit at some point.
I bumped into this issue, but I noticed that the problem for me was with project names containing underscores: in that case the droplet would be created in the default project.
Here's a small reproducible code, that also creates the project defined in the variable.
---
- hosts: localhost
connection: local
gather_facts: false
vars:
# project_name: test-project
project_name: test_project
tasks:
- name: Create a new separate project from the default
community.digitalocean.digital_ocean_project:
name: "{{ project_name }}"
state: present
oauth_token: "{{ lookup('ansible.builtin.env', 'DO_API_TOKEN') }}"
description: "This project is a test"
purpose: "Operational/Developer tooling"
environment: "Production"
- name: 'Create a DigitalOcean Droplet'
community.digitalocean.digital_ocean_droplet:
oauth_token: "{{ lookup('ansible.builtin.env', 'DO_API_TOKEN') }}"
name: nodename
project_name: "{{ project_name }}"
state: present
size: s-1vcpu-1gb
image: ubuntu-22-04-x64
region: sfo3
@dschilling No problem; though, I'm perplexed on why this doesn't work. I'll have to dig into that a bit at some point.
Originally posted by @mamercad in #201 (comment)
The text was updated successfully, but these errors were encountered: