Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue installing bitwarden passwordless app from marketplace #812

Open
2 tasks
keithhubner opened this issue Jul 19, 2024 · 5 comments
Open
2 tasks

Issue installing bitwarden passwordless app from marketplace #812

keithhubner opened this issue Jul 19, 2024 · 5 comments
Assignees

Comments

@keithhubner
Copy link
Contributor

This issue is a:

  • [X ] Bug Report
  • Enhancement suggestion
  • Feature request

I am unable to deploy the bitwarden passwordless-dev app from the marketplace. Following brief investigation on private slack channel, possibly linked to architecture issue.

  • Expected behaviour
    Application to install

  • Encountered behaviour
    Error:
    │ {"time":"2024-07-19T09:58:22.539245688Z","level":"INFO","msg":"Creating temp dir to clone git repo"} │
    │ {"time":"2024-07-19T09:58:22.542337456Z","level":"INFO","msg":"Created temp dir: /tmp/prefix3014177634"} │
    │ {"time":"2024-07-19T09:58:24.130829389Z","level":"INFO","msg":"Validating that app exists: bitwarden-passwordless-dev\n"} │
    │ {"time":"2024-07-19T09:58:24.131031638Z","level":"INFO","msg":"Running App PreInstall"} │
    │ {"time":"2024-07-19T09:58:24.131094657Z","level":"INFO","msg":"Cheking the pre_install.sh is preset or not"} │
    │ {"time":"2024-07-19T09:58:24.131150776Z","level":"INFO","msg":"Running the pre_install.sh"} │
    │ {"time":"2024-07-19T09:58:24.131190755Z","level":"INFO","msg":"Making the shell file executable"} │
    │ {"time":"2024-07-19T09:58:24.132234112Z","level":"INFO","msg":"Command output","stdout":""} │
    │ {"time":"2024-07-19T09:58:24.132344351Z","level":"ERROR","msg":"Command output","stderr":""} │
    │ {"time":"2024-07-19T09:58:24.132387653Z","level":"INFO","msg":"Running the shell file"} │
    │ {"time":"2024-07-19T09:58:24.132444195Z","level":"INFO","msg":"Shell file contents","shellFile":"I1dhaXQgZm9yIHRoZSBDZXJ0IE1hbmFnZXIgZGVwbG95bWVudCB0byBiZSBkb25lLgprdWJlY3RsIHdhaXQgLS1mb3I9Y29uZGl0aW9uPWF2YWlsYWJsZSAtLXRpbWVvdXQ9MzAwcyBkZXBsb3ltZW50L2Nl │
    │ {"time":"2024-07-19T09:58:24.132759849Z","level":"INFO","msg":"Command output","stdout":""} │
    │ {"time":"2024-07-19T09:58:24.132812943Z","level":"ERROR","msg":"Command output","stderr":""} │
    │ Error: fork/exec ./pre_install.sh: exec format error │
    │ Usage: │
    │ marketplace-installer install [flags] │
    │ │
    │ Examples: │
    │ install │
    │ │
    │ Flags: │
    │ -h, --help help for install │
    │ │
    │ Global Flags: │
    │ -d, --git-url string The git repo to clone from (default "https://git.civo.com/civo/marketplace.git") │
    │ │
    │ Stream closed EOF for default/install-bitwarden-passwordle-jtkk7 (install-bitwarden-passwordle)

  • The steps to recreate the behaviour that you are reporting
    Deploy the Bitwarden passwordless-dev app.

If you have logs or screenshots, please include them below.

@NerdyShawn
Copy link
Contributor

I was also able to reproduce the error with the install. It seems that there are two jobs for this app at install time. The first pre_install.sh job for cert-manager finishes fine but the second job is the one throwing the error exec format error.

k get jobs
NAME                           COMPLETIONS   DURATION   AGE
install-bitwarden-passwordle   0/1           21h        21h
install-cert-manager-test03    1/1           9s         21h

inspecting the image used to perform the marketplace install is currently amd64 architecture, with the amd64 kubectl binary inside

docker inspect gcr.io/consummate-yew-302509/marketplace-installer:latest --format "{{.ID}} {{.RepoTags}} {{.Architecture}}"
sha256:bbc507d6dde94035f50ce54473bfbd06c3661f2d830540b3bc87df6d491acac1 [gcr.io/consummate-yew-302509/marketplace-installer:latest] amd64

It seems like at install time its trying to run on a different cpu architecture thats causing the exec format error.

@chadmcrowell
Copy link
Contributor

Logs from the pod:

$ k logs install-bitwarden-passwordle-tds6d                                                                                                                                                                                 [9:03:43]
{"time":"2024-07-24T14:00:23.649173072Z","level":"INFO","msg":"Cloneing git repo https://github.com/civo/kubernetes-marketplace\n"}
{"time":"2024-07-24T14:00:23.649267646Z","level":"INFO","msg":"Creating temp dir to clone git repo"}
{"time":"2024-07-24T14:00:23.649387114Z","level":"INFO","msg":"Created temp dir: /tmp/prefix1819640062"}
{"time":"2024-07-24T14:00:24.677120139Z","level":"INFO","msg":"Validating that app exists: bitwarden-passwordless-dev\n"}
{"time":"2024-07-24T14:00:24.677154368Z","level":"INFO","msg":"Running App PreInstall"}
{"time":"2024-07-24T14:00:24.677158562Z","level":"INFO","msg":"Cheking the pre_install.sh is preset or not"}
{"time":"2024-07-24T14:00:24.677164639Z","level":"INFO","msg":"Running the pre_install.sh"}
{"time":"2024-07-24T14:00:24.67716943Z","level":"INFO","msg":"Making the shell file executable"}
{"time":"2024-07-24T14:00:24.678078797Z","level":"INFO","msg":"Command output","stdout":""}
{"time":"2024-07-24T14:00:24.678089201Z","level":"ERROR","msg":"Command output","stderr":""}
{"time":"2024-07-24T14:00:24.6780928Z","level":"INFO","msg":"Running the shell file"}
{"time":"2024-07-24T14:00:24.678118657Z","level":"INFO","msg":"Shell file contents","shellFile":"I1dhaXQgZm9yIHRoZSBDZXJ0IE1hbmFnZXIgZGVwbG95bWVudCB0byBiZSBkb25lLgprdWJlY3RsIHdhaXQgLS1mb3I9Y29uZGl0aW9uPWF2YWlsYWJsZSAtLXRpbWVvdXQ9MzAwcyBkZXBsb3ltZW50L2NlcnQtbWFuYWdlci13ZWJob29rICAtbiBjZXJ0LW1hbmFnZXIK"}
{"time":"2024-07-24T14:00:24.678329237Z","level":"INFO","msg":"Command output","stdout":""}
{"time":"2024-07-24T14:00:24.678334477Z","level":"ERROR","msg":"Command output","stderr":""}
Error: fork/exec ./pre_install.sh: exec format error
Usage:
  marketplace-installer install [flags]

Examples:
install <app name>

Flags:
  -h, --help   help for install

Global Flags:
  -d, --git-url string   The git repo to clone from (default "https://git.civo.com/civo/marketplace.git")

@chadmcrowell
Copy link
Contributor

pull request #816

@chadmcrowell chadmcrowell self-assigned this Jul 24, 2024
@NerdyShawn
Copy link
Contributor

I've done some more troubleshooting, and comparing and at this point I'm speculating that the binary marketplace-installer is tripping up on apps with a pre_install.sh have so far all been throwing the same fork exec error for me.

the 3 apps attempted that also use the pre_install.sh vs. install.sh

@NerdyShawn
Copy link
Contributor

I've got a PR started to convert this app specifically to just use install.sh in the interim with a pattern of applying the crd's first then the app.yaml explicitly. This should get it at cluster install time I believe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants