This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-12-05
Channels
- # adventofcode (246)
- # aleph (5)
- # aws (7)
- # beginners (161)
- # boot (3)
- # calva (42)
- # cider (40)
- # clara (10)
- # cljdoc (7)
- # cljs-dev (40)
- # cljsrn (6)
- # clojure (170)
- # clojure-dev (8)
- # clojure-greece (2)
- # clojure-italy (15)
- # clojure-kc (2)
- # clojure-new-zealand (13)
- # clojure-nl (13)
- # clojure-russia (3)
- # clojure-spec (5)
- # clojure-uk (160)
- # clojurescript (72)
- # clojurex (1)
- # cursive (7)
- # data-science (9)
- # datascript (1)
- # datomic (120)
- # devcards (4)
- # emacs (18)
- # figwheel-main (10)
- # fulcro (34)
- # kaocha (3)
- # luminus (1)
- # lumo (6)
- # music (1)
- # nrepl (23)
- # off-topic (2)
- # pedestal (4)
- # re-frame (42)
- # reagent (36)
- # reitit (10)
- # ring-swagger (21)
- # shadow-cljs (124)
- # spacemacs (6)
- # tools-deps (14)
- # unrepl (3)
- # vim (2)
chrisulloa05:12:21
Question about the cognitect-labs/aws-api, if I want to pass in a set of credentials (rather than setting env variables), doing something like this works:
(require '[cognitect.aws.credentials :refer [CredentialsProvider]]
'[cognitect.aws.api :as aws])
(defn credentials-provider
[access-key secret-key]
(reify CredentialsProvider
(fetch [_]
{:aws/access-key-id access-key
:aws/secret-access-key secret-key})))
(def s3-client (aws/client {:api :s3 :region "us-east-1"
:credentials (credentials-provider access-key secret-key)}))
But is there any reason why it doesn’t allow us to just pass in a map with the credentials?dottedmag07:12:32
@christian.gonzalez Probably because nobody got around to implement CredentialsProvider
via map. But you can do it yourself if you need, can't you?
alexmiller13:12:26
Might be reasonable to have this in the api though - I’ve already written this code too
chrisulloa13:12:26
Yeah I’ll file an issue thanks guys! I wasn’t sure if there was reasoning behind it.