rails 4.1 can't deploy via capistrano 3

后端 未结 4 1532
有刺的猬
有刺的猬 2020-12-28 18:05

i have very strange error when deploy my rails app with capistrano. sometimes it\'s deploy and sometimes not. for example i add something to css (just one string) e.g.

相关标签:
4条回答
  • 2020-12-28 18:49

    You appear to have an outdated version of libyaml

    Update libyaml.

    0 讨论(0)
  • 2020-12-28 18:57

    As was written above, probably, you have not enough RAM.

    I solved problem by adding SWAP file on my Ubuntu 14.04 server:

    Under the root:

    dd if=/dev/zero of=/swapfile bs=1024 count=512k
    mkswap /swapfile
    swapon /swapfile
    

    Add next line to /etc/fstab:

     /swapfile       none    swap    sw      0       0 
    

    and:

    echo 0 > /proc/sys/vm/swappiness
    sudo chown root:root /swapfile 
    sudo chmod 0600 /swapfile
    

    check SWAP(maybe need reloading):

    swapon -s 
    

    — How To Add Swap on Ubuntu 14.04 @ Digital Ocean Community

    0 讨论(0)
  • 2020-12-28 18:58

    if someone have same error - problem was on hosting. server have not enough ram(512mb), and process of compilation css/js was killed every time. than we change rate plan, which has 1gb ram, all deployed successfully. SO if you assets precompile failed - just try to add some resources to server. P.S. similar problem i found here Capistrano deploy - assets precompile error

    0 讨论(0)
  • 2020-12-28 19:02

    Try rebooting the server.Worked for me.

    0 讨论(0)
提交回复
热议问题