silverdr

silverdr

Function :public_key.cacerts_get/0 is undefined or private

I have a mix release application running in a container but it seems to have problems with cacerts. If I run:

docker exec -it 1773f1bd7685 bin/myapp eval ':public_key.cacerts_get()'

I get:

** (UndefinedFunctionError) function :public_key.cacerts_get/0 is undefined or private
    (public_key 1.12.0.2) :public_key.cacerts_get()
    (stdlib 3.17.2.4) erl_eval.erl:685: :erl_eval.do_apply/6
    (elixir 1.16.2) lib/code.ex:572: Code.validated_eval_string/3

What do I need to do in order to have the said function available?

Marked As Solved

D4no0

D4no0

OTP-24 doesn’t have the cacerts_get/0 in public_key: Erlang -- public_key

Also Liked

LostKobrakai

LostKobrakai

That version of OTP and elixir are you using?

D4no0

D4no0

I’m not sure what are you looking for, wouldn’t it be easier to upgrade to OTP-26.2.5+ where this issue was patched?

D4no0

D4no0

While I understand this, I am also not very positive that you change versions everyday. I just now noticed that docker builds from hex do not come with specific OTP versions, which is not the greatest thing now that I think about it.

Personally I would take a look at the scripts for building these images and customize one of them for specific elixir and OTP version. I would even be inclined to help you make this into an official feature, as I use docker for almost all of my deploys.

LostKobrakai

LostKobrakai

Those are not the docker builds. However there were some issues resolved today: Missing latest images on docker hubs · Issue #187 · hexpm/bob · GitHub

silverdr

silverdr

I don’t. This time I had to though.

They do. You have to look here:

https://hub.docker.com/r/hexpm/elixir/tags

And that’s the easiest way and smallest image sizes. I did custom images before but those are leaner and faster to build “runner” images.

Probably yes so that’s an option to wait a (probably only) a little longer, but…

I do agree. That’s why I had everything running on 26 already for some time. But I got bitten by this very nastily so even if 26.2.5 pops up soon (which I think it will) I shall still be having a very close eye on how it behaves and whether the fix really fixed things and not introduced other problems, etc.

But right, maybe I am a bit too impatient and just wanted to fix all things around this area right away so that I don’t have to return to it later

Where Next?

Popular in Questions Top

sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
lessless
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
gshaw
What is the idiomatic way of matching for not nil in Elixir? E.g., First way: defp halt_if_not_signed_in(conn, signed_in_account) when...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
sacepums
Hey guys. I'm new to elixir and im really stocked about it. But I ran into a bit of problem - I need to convert a date sting, for examp...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
Mooodi
Given a string, how can I get access to its character by index? Enum.at("my_string", 2) doesn't work. Or rather, not char, but a substr...
New
Qqwy
Original source of discussion: This topic on the Pragmatic Programmers' Functional Web Development with Elixir, OTP, and Phoenix forum. ...
New
siddhant3030
Hi, I have to write a raw query for one of my project. But till now I have used ecto queries and don’t have much experience writing raw ...
New

Other popular topics Top

sorentwo
Hello! tl;dr Announcing Oban, an Ecto based job processing library with a focus on reliability and historical observability. After spen...
977 41022 311
New
sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
aalberti333
As the title describes, I’m trying to run Enum.map() over a list of key/value pairs, where the value is a map. My data looks like this: ...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
quazar
How to set Jason to encode all fields in ecto schema, I don’t care about security and implementing only is taking long list of attributes...
New
hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
chrismccord
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? https://hexdocs.pm/ecto/Ecto.Repo.h...
New
TunkShif
This post is an instruction guide to help you setup your Neovim for Elixir development from scratch. It includes general information on h...
273 38985 115
New
AstonJ
We’ve put together this wiki for Phoenix LiveView - please feel free to add any info you feel is worth including. What is Phoenix LiveV...
New

We're in Beta

About us Mission Statement