Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Add --user flag to "secrets" and "envs" #92

Merged
merged 1 commit into from
Aug 12, 2020
Merged

Add --user flag to "secrets" and "envs" #92

merged 1 commit into from
Aug 12, 2020

Conversation

cmoog
Copy link
Contributor

@cmoog cmoog commented Aug 4, 2020

Samples

Setting a secret value for all users. Of course, were the admin to want a different value for each user, they would need to have some additional way of correlating the email to a secret prior to creating the Coder secret.

#!/bin/bash

# get all user emails
emails=$(coder users ls --output json | jq -c -r '.[] | .email')

for user in $emails
do
	# create a secret for that user
	coder secrets --user $user create mysql-password --from-literal password123 
done

Closes #76

Base automatically changed from urfave to master August 10, 2020 21:42
@cmoog cmoog marked this pull request as ready for review August 10, 2020 23:04
@cmoog cmoog requested a review from deansheather August 11, 2020 00:28
@cmoog cmoog requested a review from deansheather August 12, 2020 15:27
@cmoog cmoog merged commit e3efdad into master Aug 12, 2020
@cmoog cmoog deleted the user-flag branch August 12, 2020 17:42
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create foundation for performing bulk actions
2 participants