Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resource: slack_conversation_member #26

Open
rdsubhas opened this issue May 11, 2020 · 1 comment
Open

Resource: slack_conversation_member #26

rdsubhas opened this issue May 11, 2020 · 1 comment

Comments

@rdsubhas
Copy link
Contributor

Current situation / problem

  • We can add members to slack_usergroup_members, and then we can set Default channels for a usergroup
  • But this is unfortunately a problem, because it's a one-time operation. First time, when a user is added to a usergroup, they get added to the "default" channels of the usergroup.
    • Later, when we want to move teams to different conversations, we can't - if we update channels for a usergroup later – it does not change existing memberships
    • If we remove users from a usergroup, it does not remove them from existing channels

Fix / Proposal

  • New resource: slack_conversation_member – Manage a user being present or not in a conversation/channel
  • Create: conversations.invite
  • Delete: conversations.kick
  • Update: Do nothing, let terraform delete & create
  • Read: conversations.members (tier4 API call, no need to cache right now but we can do it later if needed)

By managing each membership, we can individually add/remove users from conversations live.

@jmatsu
Copy link
Owner

jmatsu commented May 12, 2020

But this is unfortunately a problem, because it's a one-time operation.

That's why I haven't supported this resource yet. ignore_changes must be used properly to manage such resources, I guess.

Update: Do nothing, let terraform delete & create

I think doing NOTHING is better. delete and create may generate many messages like someone left. bot invite someone..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants