Using custome docker images on k6 cloud

Hi,

I would like to use the custom docker image (which is a slightly modified loadimpact/k6 image) in the k6 cloud. Is it possible to do this? Can I only use the latest version?

Hi @jagio,

This is currently not supported, and we had a small discussion around a similar topic when plugin system for k6 was discussed.

I wonder what your use case is though? What exactly is that you want to change in k6 that you can’t make a PR for? Will the plugin system be sufficient?

Thanks for replying.

I want to POST the payload of an http request in DER format after signing it with PKCS#7. Can this process be implemented in K6?

The same process is implemented in ruby. I hope to achieve this with the K6.

req_p7 = OpenSSL::PKCS7.sign(client_cert, client_key, request_data, [], OpenSSL::PKCS7::BINARY)
req = Net::HTTP::Post.new(url)
req.body = req_p7.to_der
req.content_type = 'application/x-pkcs7-crl'
res = http.request(req)

Yeah, that is currently not possible.

We had a PR, but as explained here we want to fix some underlying issues first, to which we haven’t gotten, so … :sob:

I would (and I have expressed this internally at least) argue that doing crypto on a load generator is probably not a “great” idea :smiley: . If you can I would recommend doing the signing and der formatting outside of k6 and provide k6 with just the final data to send. This of course won’t be possible if the data or the keys are varied depending on the execution of the script.

You are free (and I advise you :wink: ) to comment on any discussion about this :smiley:

I understand your recommendation and will consider doing the signing and DER formatting outside of K6.

Thank you for your advice!