This GitHub Action will store a new user level SSH key on packet.com. SSH keys grant you access to resources such as deployed servers within a project.
With this action you can automate your workflow by adding user level SSH keys using the packet.com api.
To use this action you will first need an authentication token which can be generated through the Packet Portal.
You will also need a public/private key pair. Learn how to generate keys.
NEVER share your private key with anyone!
Packet.com is NOT a free service, so you will be asked to provide billing information. This action will NOT have access to that information.
# File: .github/workflows/workflow.yml
on: [push]
name: Packet Project Sample
jobs:
store-new-public-key:
runs-on: ubuntu-latest
name: Store new user level SSH key
steps:
- uses: mattdavis0351/packet-create-user-ssh-key@v1
id: key
with:
API_key: ${{ secrets.PACKET_API_KEY }}
key_label: our-admin
public_key: ${{ secrets.PACKET_PUBLIC_KEY }}
Input | Description | Default | Required |
---|---|---|---|
API_key |
Packet.com API authorization token | No key supplied | ✅ |
key_label |
Desired label for users SSH key | Generated by GitHub Actions | ✅ |
public_key |
Public key for user stored in as repository secret | No key supplied | ✅ |
This action supplies the following outputs which can be consumed by subsequent actions in the current job.
Output | Description |
---|---|
key_id |
ID of the newly stored SSH key returned as a string |
key_owner |
Owner of the newly stored SSH key returned as a string |