leiningen

danm 2021-08-13T13:26:42.030200Z

Is there a way to tell lein which region an S3 bucket as a Maven repo is in? I'm hitting a problem where I need to use credentials from account X to access a Maven repo bucket in account Y, and it's failing. Digging into that, it seems to be because Maven is trying to do a bucket location lookup, and permissions for that cannot be granted cross-account. deps.edn allows you to manually specify ?region=xxxxx as part of the repo URL, but the same doesn't seem to be working for project.clj (See https://clojurians.slack.com/archives/C03S1KBA2/p1628859798359100)

Slackbot 2021-08-13T14:24:53.032100Z

This message was deleted.

danm 2021-08-13T18:46:38.039900Z

My understanding from the docs is that path style addressing is only valid for http:// bucket paths. Is that wrong? Cool if so

danm 2021-08-13T18:53:19.040200Z

Hmm. Doesn't seem to work for the CLI for me 😞

Slackbot 2021-08-13T14:33:52.033700Z

This message was deleted.

danm 2021-08-13T18:54:26.040400Z

Everything I can find about s3-wagon-private is about publishing. I just need to consume what has been published elsewhere. But it's not a public bucket and I don't have a user in the bucket account

danm 2021-08-13T18:55:41.040600Z

The issue seems to be that the permissions for GetBucketLocation can only be granted to users/roles in the same account, not cross account like every other API call... So I can ListObjects and GetObject, but if my calls need to look up the location, it fails

danm 2021-08-13T18:56:11.040800Z

That's why I can get clj to work, because it provides a param to override the location so the lookup isn't needed

danm 2021-08-13T18:56:50.041Z

Sadly it doesn't look like lein offers the same functionality

ghadi 2021-08-13T16:29:44.035200Z

@carr0t clj and lein use different maven libraries

ghadi 2021-08-13T16:30:56.035900Z

https://clojure.org/reference/deps_and_cli Have you read the docs about bucket regions?

danm 2021-08-13T18:45:36.039700Z

This works fine for clj/`deps.edn`, but not for lein. We still need lein for bits of our build and deployment pipeline

danm 2021-08-13T18:57:46.041200Z

I fixed the clj issue later down the linked thread, but lein is still causing issues

danm 2021-08-13T18:58:27.041400Z

I guess I could hack something together where I invoke clj to populate my local Maven cache and then launch lein, which finds the relevant files locally, but... eww

ghadi 2021-08-13T16:31:30.036300Z

you can set region directly

bajrachar 2021-08-13T18:07:58.037500Z

hello everyone - need a bit of help with deploying to clojars.

bajrachar 2021-08-13T18:09:48.038900Z

when I run lein deploy clojars it goes through steps of copying over the jar and pom.xml files but chokes on the metdata.xml file -- complaining about missing checksum

bajrachar 2021-08-13T18:09:52.039Z

ReasonPhrase: Forbidden - no checksums provided for <repo.jar.asc>

bajrachar 2021-08-13T18:10:41.039500Z

Any idea how I could fix this or debug further