« first day (1692 days earlier)      last day (1563 days later) » 

11:57
@HuyVo ... so on rails if you're spending more than a day on it - you're likely fighting the system (or you have an off by one error you haven't found) ... in your case the issue is you should not be using a decorator with an api ... especially a json one where the industry standard is serialization & there have hundreds of gems for json specification to do thousands of tasks ... maybe I'm just not grasping terminology - but it really sounds like you're working against how rails is made
ah! you're not talking about generating layout but formating field - good stuff Huy!
@LucianTarna you're like the 5th person we've had with these issues behind ngix ... i first for the assets not serving up correctly though, the issue one guy had was directory permissions were right, but everytime he precompiled - he had to change the file permissions before the other server could see it ... i can't recall but the https is a firewall thing ... do you have another machine in there or did you just not setup the ngix routing right?
Also ... Lucian, is your VM coworker's VM a self contained network or just a server on the VM reaching out across the network via the same NGIX server you're using?
(should note the guy who was having permission issues with precompiling just upgraded to rails 5 eventually & issue went away)
12:20
i did setup de nginx routing right, on my mac it works, it doesn't on ubuntu same config
the colleague has a NAT connection
and has his own nginx
locally
so it always works no matter what on mac?
(without precompiling or with?)
always works on mac
with or without precompiling
in ubuntu only without
good
however, rake:assets:precompile works
i expected it not to
yea - permissions issue, as expect - directory permissions versus the assets generation script themselves are files with their own permissions
12:32
i tried to change the user
i even added the users in the same group that already owned the file
chown to ubuntu, my user, root, nginx user
chmod 777
all together...
NOTHING worked :(
are you running these servers against the mac server or is each server independent? aka the ubuntu & windows machine call for the assets on the mac?
no link between them
it's just a local setup of the app
on each of the laptops
they do share the same wi fi
:))) but other than that.. no
hrm, is ngix on same machine or standalone?
also is this dev or production env? cause there's a ton of production related tickets out there due to special handling for pipeline in rails
8 containers on each machine
mac runs a VM with Ubuntu 16
windows same a VM with ubuntu 16
and Ubuntu 16 with no vm
12:40
these 8 containers have 1 nginx each + 1 nginx in each ubuntu instance(be it VM or native)
mac works, the other 2 don't
dev env as far as i know
I'm not sure why it works, but did you try cache clearing on these broken boxes?
precompiling of the assets during production for rail is actually a thing btw - so you might want to actively decide if it's worth chasing this issue - if as you said precompiling solves all problems for all servers
no, i said precompiling works as in the process has no errors
the request ends up with that retarded error either way
i did try to cache clear everything
:D
ah yes i know the digital ocean thingy
did
you use the word "it" too much for me to tell what you are talking about :)
(can't tell which 'it')
so back to the vm setup ... you're saying you have 8 containers ... I asked if the ngix is in the same VM setup on the same server as the ubuntu rails server ... yes/no?
from my last paragraph ?
in everything - no more using 'it', use a pronoun like "ubuntu rails server"
12:53
Yes nginx is in the same VM setup
next ... inside the vm setup is nginx on the same virtual server as the ubuntu rails server? yes/no (i just need to be sure we're not chasing firewall/routing issues - cause they can look the same - and with different OS they totally handle security differently)
Yes, it is(the nginxin on the same virtual server).
alright ... just out of curiosity then, what happens if you toggle config.assets.compile = true ...in... config/environments/development.rb?
maybe check to see if debug assets is true/false too ... config.assets.debug = false
# Debug mode disables concatenation and preprocessing of assets.
# This option may cause significant delays in view rendering with a large
# number of complex assets.
config.assets.debug = true
error doesn't change when i do what you said
Can you paste error message, not whole trace
because when i looked back all i saw was link to someone else's error - but their fixes dno't work for you
13:03
i can;t copy
the text is from css or soemthing like that
error is this
this is the whole error
imgur blocked :(
are you in rails console or logfile?
browser
console doesn't get an error
oh jesus
console says the response is 200
logfile the same
Error compiling CSS asset
Errno::EACCESS: Permission denied @ dir_s_mkdir - /vagrant/tmp/cache
you're not using webpack? what rails?
13:06
5
yea - that sounds familiar - the vagrant/tmp/cache ... so glad docker came along
nope, this container doesn't use wwebpack
I KNOW > <
but this new company is pretty old
so they have vagrant
ibm VM does benefit from it...just when got into rails chef/puppet/vagrant/vm & the naturally occuring transmission corruptions made it all suck
@LucianTarna ...in regards to this ... that's from the fix off here right? stackoverflow.com/questions/7524262/permission-denied-in-tmp
also silly - but i've been there - cleared cache after fix & restart server?
o yeah, what is written here stackoverflow.com/questions/7524262/permission-denied-in-tmp is the first thing i tried
on docker i had to do the same thing as some point
yes, i did clear cache and restarted server
i even remade the container :D
just to be sure - would remaking the container undo the fix? :)
13:19
the changed rigths ?
yes, remaking the container does change it back to how it previously was
before i changed the permissions
so you see the implications there for regressive issue?
yes, but i do not know how to solve it :D i tried to look at the config files of ansible and vagrant both
so much clutter...
docker is way better with this or at least the programmer that did it
can't understand much from the vagrant thing at first glance
and at the moment i do not need the container
me either to be honest - but it looks like the fix should be file permissions, so just make sure you remember to check the path/dir etc exists and you chown it each time you mess with image/vagrant
so at this point you need a vagrant/ubuntu expert to check the permissions are changing and vagrant isn't overriding or silently saying nope
either that or if you have to wait on one, try pulling the nginx out of the equation?
i will try eventually, at the moment i have other tasks that do not require that new container
so maybe i will come up with ideas at a later date
In config/environments/development.rb, place the following line:

config.assets.prefix = "/dev-assets"
only other suggestion
tell rails to put the assets in another directory?
13:32
hmmm
haven't tried this
will try in a bit:D
that particular one is a prefix, so it will probably sit in the same dir ... find a directory you trust & use config.assets.xxxx to move dir
hmmm put it but the folder is not created, the rror persists
will investigate tomorrow on this path
13:47
right ... @LucianTarna the last thing, some of the sprockets type gems work from the local temp directly instead of their own & even if the results are stored else where, they are created in the /vagrant/tmp (type directory) and then moved elsewhere afterwards if the programmers are lazy
oh.. maybe that's the issue
 
1 hour later…
15:11
shrugs, never code dove vagrant or the rails asset pipeline code - I kind of consider them both dead ends (in terms of rails with options out there like api to modern front end)
 
5 hours later…
20:14
Hello Ruby friends. I have terrible news. I've accepted a job as a fullstack dev... at a pure JS company.
I am no longer working in Ruby, in any professional capacity :(
congrats? great knowing you? ;)
(I haven't written any code really in 2 weeks - trying to decide if i care)
20:38
@meagar You'll have a good time in any language you work in. And in my eyes, you're a Rubyist forever.
20:58
@WayneConrad It's been pretty go so far. Modern JavaScript isn't really that bad
I will say, I find the whole async/await very annoying
On the server where we can just block while we wait for something to return, I hate seeing await before basically every method invocation.
A lot of things about JS annoy me. But it's ubiquitous, and that's worth a lot.
 
1 hour later…
22:16
I'm a sysadmin now. Dev asks me for an Postgres app login that has superuser privs. Funny dev.

« first day (1692 days earlier)      last day (1563 days later) »