Coder Social home page Coder Social logo

"amoni start" fails. about amoni HOT 17 CLOSED

anvilistas avatar anvilistas commented on August 25, 2024
"amoni start" fails.

from amoni.

Comments (17)

meatballs avatar meatballs commented on August 25, 2024

I'm away at the moment. I'll have a look at this once I'm back home in a couple of weeks.

from amoni.

meatballs avatar meatballs commented on August 25, 2024

Is it possible that creative Procrastination comes to the rescue here?

https://anvil.works/forum/t/no-module-named-functools-when-using-anvil-app-server/18591/7

from amoni.

telemix avatar telemix commented on August 25, 2024

from amoni.

meatballs avatar meatballs commented on August 25, 2024

sorry I can't look into this properly right now. Life is getting in the way.

Try amoni start --update which should update the docker image for you.

from amoni.

vidz1979 avatar vidz1979 commented on August 25, 2024

Same error here! Ubuntu 22.04 also.

from amoni.

telemix avatar telemix commented on August 25, 2024

It fails on Debian 12, Ubuntu 22.04 and Centos 9. The centos output is here :

[+] Running 4/4l app and database servers
 ✔ Network demo_default      Created                                                                                                                                                                                                           0.1s 
 ✔ Volume "demo_postgresql"  Created                                                                                                                                                                                                           0.0s 
 ✔ Container demo-db-1       Healthy                                                                                                                                                                                                           0.0s 
 ✔ Container demo-app-1      Created                                                                                                                                                                                                           0.0s 
Error response from daemon: failed to create task for container: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: exec: "anvil-app-server": executable file not found in $PATH: unknown
╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮
│ /root/.local/pipx/venvs/amoni/lib64/python3.9/site-packages/amoni/cli/amoni.py:54 in start       │
│                                                                                                  │
│   51 │   │   api.build_image("app")                                                              │
│   52 │   │   api.pull_image("db")                                                                │
│   53 │   with echo.working("Starting anvil app and database servers"):                           │
│ ❱ 54 │   │   api.start_service("app", detach=True)                                               │
│   55 │   echo.progress("Your app is available at http://localhost:3030")                         │
│   56 │   if launch:                                                                              │
│   57 │   │   typer.launch("http://localhost:3030")                                               │
│                                                                                                  │
│ ╭──── locals ────╮                                                                               │
│ │ launch = True  │                                                                               │
│ │ update = False │                                                                               │
│ ╰────────────────╯                                                                               │
│                                                                                                  │
│ /root/.local/pipx/venvs/amoni/lib64/python3.9/site-packages/amoni/api.py:110 in start_service    │
│                                                                                                  │
│   107 │   detach                                                                                 │
│   108 │   │   Whether to detach from the service console                                         │
│   109 │   """                                                                                    │
│ ❱ 110 │   docker.compose.up([name], detach=detach)                                               │
│   111                                                                                            │
│   112                                                                                            │
│   113 def stop_services() -> None:                                                               │
│                                                                                                  │
│ ╭──── locals ────╮                                                                               │
│ │ detach = True  │                                                                               │
│ │   name = 'app' │                                                                               │
│ ╰────────────────╯                                                                               │
│                                                                                                  │
│ /root/.local/pipx/venvs/amoni/lib64/python3.9/site-packages/python_on_whales/components/compose/ │
│ cli_wrapper.py:749 in up                                                                         │
│                                                                                                  │
│   746 │   │   │   services = to_list(services)                                                   │
│   747 │   │   │   full_cmd += services                                                           │
│   748 │   │   # important information is written to both stdout AND stderr.                      │
│ ❱ 749 │   │   run(full_cmd, capture_stdout=quiet, capture_stderr=quiet)                          │
│   750 │                                                                                          │
│   751 │   def version(self) -> str:                                                              │
│   752 │   │   """Returns the version of docker compose as a `str`."""                            │
│                                                                                                  │
│ ╭─────────────────────────────────────────── locals ───────────────────────────────────────────╮ │
│ │ abort_on_container_exit = False                                                              │ │
│ │     attach_dependencies = False                                                              │ │
│ │                   build = False                                                              │ │
│ │                   color = True                                                               │ │
│ │                  detach = True                                                               │ │
│ │          force_recreate = False                                                              │ │
│ │                full_cmd = [PosixPath('/usr/bin/docker'), 'compose', 'up', '--detach', 'app'] │ │
│ │              log_prefix = True                                                               │ │
│ │      no_attach_services = None                                                               │ │
│ │                no_build = False                                                              │ │
│ │                    pull = None                                                               │ │
│ │                   quiet = False                                                              │ │
│ │                recreate = True                                                               │ │
│ │          remove_orphans = False                                                              │ │
│ │                  scales = {}                                                                 │ │
│ │                    self = <python_on_whales.components.compose.cli_wrapper.ComposeCLI object │ │
│ │                           at 0x7f8b4e8f03a0>                                                 │ │
│ │                services = ['app']                                                            │ │
│ │                   start = True                                                               │ │
│ │                    wait = False                                                              │ │
│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │
│                                                                                                  │
│ /root/.local/pipx/venvs/amoni/lib64/python3.9/site-packages/python_on_whales/utils.py:194 in run │
│                                                                                                  │
│   191 │   │   │   │   │   completed_process.stderr,                                              │
│   192 │   │   │   │   )                                                                          │
│   193 │   │                                                                                      │
│ ❱ 194 │   │   raise DockerException(                                                             │
│   195 │   │   │   args,                                                                          │
│   196 │   │   │   completed_process.returncode,                                                  │
│   197 │   │   │   completed_process.stdout,                                                      │
│                                                                                                  │
│ ╭─────────────────────────────────────────── locals ───────────────────────────────────────────╮ │
│ │              args = ['/usr/bin/docker', 'compose', 'up', '--detach', 'app']                  │ │
│ │    capture_stderr = False                                                                    │ │
│ │    capture_stdout = False                                                                    │ │
│ │ completed_process = CompletedProcess(args=['/usr/bin/docker', 'compose', 'up', '--detach',   │ │
│ │                     'app'], returncode=1)                                                    │ │
│ │               env = {}                                                                       │ │
│ │             input = None                                                                     │ │
│ │     return_stderr = False                                                                    │ │
│ │       stderr_dest = None                                                                     │ │
│ │       stdout_dest = None                                                                     │ │
│ │    subprocess_env = {                                                                        │ │
│ │                     │   'SHELL': '/bin/bash',                                                │ │
│ │                     │   'HISTCONTROL': 'ignoredups',                                         │ │
│ │                     │   'HOSTNAME': 'centos-s-1vcpu-2gb-sfo3-01',                            │ │
│ │                     │   'HISTSIZE': '1000',                                                  │ │
│ │                     │   'PWD': '/root/demo',                                                 │ │
│ │                     │   'LOGNAME': 'root',                                                   │ │
│ │                     │   'XDG_SESSION_TYPE': 'tty',                                           │ │
│ │                     │   'MOTD_SHOWN': 'pam',                                                 │ │
│ │                     │   'HOME': '/root',                                                     │ │
│ │                     │   'LANG': 'en_US.UTF-8',                                               │ │
│ │                     │   ... +22                                                              │ │
│ │                     }                                                                        │ │
│ │               tty = False                                                                    │ │
│ ╰──────────────────────────────────────────────────────────────────────────────────────────────╯ │
╰──────────────────────────────────────────────────────────────────────────────────────────────────╯
DockerException: The docker command executed was `/usr/bin/docker compose up --detach app`.
It returned with code 1
The content of stdout can be found above the stacktrace (it wasn't captured).
The content of stderr can be found above the stacktrace (it wasn't captured).

from amoni.

jonp92 avatar jonp92 commented on August 25, 2024

Is Amoni dead? This issue is STILL persisting.

from amoni.

meatballs avatar meatballs commented on August 25, 2024

It's open source. Anyone is welcome to contribute.

from amoni.

meatballs avatar meatballs commented on August 25, 2024

It looks like the image build failed silently:

https://github.com/anvilistas/amoni/actions/runs/6169626033/job/16744258595#step:6:8961

from amoni.

telemix avatar telemix commented on August 25, 2024

It looks like the image build failed silently:

https://github.com/anvilistas/amoni/actions/runs/6169626033/job/16744258595#step:6:8961

Is that something I'm doing wrong?

from amoni.

meatballs avatar meatballs commented on August 25, 2024

It looks like the image build failed silently:
https://github.com/anvilistas/amoni/actions/runs/6169626033/job/16744258595#step:6:8961

Is that something I'm doing wrong?

Definitely not!

There's a docker image that gets automatically built and deployed whenever the anvil app server itself is updated. The last time that happened, the build failed silently. I don't yet understand why!

from amoni.

telemix avatar telemix commented on August 25, 2024

It looks like the image build failed silently:
https://github.com/anvilistas/amoni/actions/runs/6169626033/job/16744258595#step:6:8961

Is that something I'm doing wrong?

Definitely not!

There's a docker image that gets automatically built and deployed whenever the anvil app server itself is updated. The last time that happened, the build failed silently. I don't yet understand why!

Ah ok. Cheers.

from amoni.

meatballs avatar meatballs commented on August 25, 2024

Related: https://anvil.works/forum/t/docker-build-fails-for-anvil-server/19412

from amoni.

nickantonaccio avatar nickantonaccio commented on August 25, 2024

I've had some issues running recent versions of anvil-app-server on Ubuntu (no Docker involved). Have you tried using version 1.7.3?

from amoni.

meatballs avatar meatballs commented on August 25, 2024

No, I need to try it with various different versions but just haven't had the time.

from amoni.

meatballs avatar meatballs commented on August 25, 2024

This should now be fixed. There are new images for both the app server and the db which you can use with:

amoni start --upgrade

Watch out if you have an existing db. The new image uses postgresql 16 and it will fail to start if you have a db from the older image because that used postgresql 15.

If you only want to upgrade the app server and leave the db untouched, use:

docker compose pull app
amoni start

from amoni.

telemix avatar telemix commented on August 25, 2024

Just to say it seems to be working fine for me now as well. Thanks!

from amoni.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.