Skip to content

config.yaml to github secrets #60

@chboudry

Description

@chboudry

It would be nice to add a script to avoid manually create the GH secrets.

here is what I am using :

gh auth login
repo="name/AzureTRE-Deployment"
env="CICD"
ghvar=$(cat ./config.yaml | grep ":" | grep -v -e '#' | grep -v -e ':$' | sed 's/ //g')
for fn in $ghvar; 
do 
	parameter=$(echo $fn |cut -d ":" -f 1)
	value=$(echo $fn |cut -d ":" -f 2)
	gh secret set $parameter -b $value --repo $repo  --env $env
done

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions