Skip to content
This repository was archived by the owner on Jul 25, 2022. It is now read-only.

Save your UpCloud API credentials on your disk and insert them into your environment whenever needed.

Notifications You must be signed in to change notification settings

juusowtf/upcloud-credentials

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

UpCloud Credential Setup

Save your UpCloud API credentials on your disk and insert them into your environment whenever needed.

Why?

Because I'm lazy, but I don't want to keep the credentials in my environment all the time, but only when I need them. This is just a stupid script that exports the credentials to my environment when I need them.

Setup

Clone the repository

git clone git@github.com:jzmch/upcloud-credentials.git ~/.upcloud

Insert your credentials to ~/.upcloud/credentials

You can copy the sample file to give yourself a starting point.

cp ~/.upcloud/credentials_sample ~/.upcloud/credentials
# ~/.upcloud/credentials
UPCLOUD_USERNAME="your username that has API Access"
UPCLOUD_PASSWORD="your password"

Insert the sourcing function to your shell profile or rc file

upcloud() {
  if [[ -f ~/.upcloud/credentials ]] && [[ -f ~/.upcloud/upcloud_credentials.sh ]]; then
      . ~/.upcloud/upcloud_credentials.sh
  fi
}

Usage

Just open a new shell and type:

$ upcloud

and you're done! :D

About

Save your UpCloud API credentials on your disk and insert them into your environment whenever needed.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages