From 239e5b928c695a7a665d77a0d59cc384ad9cae13 Mon Sep 17 00:00:00 2001 From: Andre Medeiros Date: Mon, 5 Jul 2021 21:30:42 -0400 Subject: [PATCH] read from bytes --- cmd/apollo-worker/main.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cmd/apollo-worker/main.go b/cmd/apollo-worker/main.go index 5678913..d6b5490 100644 --- a/cmd/apollo-worker/main.go +++ b/cmd/apollo-worker/main.go @@ -30,11 +30,11 @@ type application struct { var workers int = runtime.NumCPU() * 8 func accountWorker(id int, rc *reddit.Client, db *sql.DB, logger *log.Logger, quit chan bool) { - authKey, err := token.AuthKeyFromFile(os.Getenv("APPLE_AUTHKEY_PATH")) + authKey, err := token.AuthKeyFromBytes([]byte(os.Getenv("APPLE_KEY_PKEY"))) token := &token.Token{ AuthKey: authKey, - KeyID: "T88A7G9LZ8", - TeamID: "XG3L8T56DK", + KeyID: os.Getenv("APPLE_KEY_ID"), + TeamID: os.Getenv("APPLE_TEAM_ID"), } if err != nil {