<John_Ivan>
Is it correct in saying that, basically, the only routes every available for anyone to access your webserver and application servers are **NONE**, other than the defined ones, and the **static** ones.
<John_Ivan>
**everything else** has to go through a controller to be retrieved.
<John_Ivan>
ever*
<John_Ivan>
static/public
<John_Ivan>
*
<adam12>
John_Ivan: I'm not sure I follow exactly, but if you just forgot about the webserver for a moment (because it's not necessary), the routes connect requests to controllers. If there's no route, then the request would fail with a 404.
<John_Ivan>
adam12, sure. let's put the webserver aside. what I'm trying to say is that, by default, everything is 404.
<adam12>
John_Ivan: Yes, tho I think in Rails it will serve public/ for you...
<John_Ivan>
correct. except for static/public
<John_Ivan>
adam12, now, with that in mind. everything else HAS to go through a controller
<adam12>
Yes.
<John_Ivan>
adam12, then it finally clicked for me.
<adam12>
A route has to match to a controller/action that has to exist.
<John_Ivan>
yeah. I got it. that was what confused the hell out of me for years
<John_Ivan>
everything now makes sense.
<John_Ivan>
adam12, and with that, I know exactly what to do with user files
<John_Ivan>
in short - it's no other than treating this as any other application, such as a desktop one
<John_Ivan>
no different*
<John_Ivan>
adam12, is this correct?
<adam12>
Not sure I follow.
<John_Ivan>
adam12, the webapplication, if you strip apart the gateaway (e.g the web framework and HTTP) to itself
<John_Ivan>
adam12, is no different than any other application.
<John_Ivan>
but anyway, no need to answer that. I figured it out. thanks mate.
<John_Ivan>
the principles of architecture still apply
<John_Ivan>
*rubs head in agitation*
<adam12>
heh
hololeap has quit [Ping timeout: 240 seconds]
ur5us has joined #ruby
hololeap has joined #ruby
TrufflePump has quit [Ping timeout: 258 seconds]
TrufflePump has joined #ruby
bobdobbs` has joined #ruby
bobdobbs has quit [Ping timeout: 240 seconds]
cocalero has joined #ruby
hololeap has quit [Remote host closed the connection]
TrufflePump has quit [Ping timeout: 246 seconds]
hololeap has joined #ruby
Rounin has quit [Ping timeout: 248 seconds]
TrufflePump has joined #ruby
roshanavand has quit [Ping timeout: 240 seconds]
cocalero has quit [Quit: Going offline, see ya! (www.adiirc.com)]
TrufflePump has quit [Ping timeout: 258 seconds]
TrufflePump has joined #ruby
RickHull has quit [Ping timeout: 240 seconds]
TrufflePump has quit [Ping timeout: 246 seconds]
<havenwood>
John_Ivan: It's pretty typical to use a reverse proxy like NGINX or Apache in front of Rails, and you can configure them to serve your public directory without a Rails router because it never touches the Rack webserver.
<havenwood>
John_Ivan: If Rails is serving it up, it should be in the routes. But yeah, it's indeed fairly common to configure static files to be served directly from a higher layer. There are various ways to do it, and you don't necessarily need a reverse proxy setup at all.
<havenwood>
John_Ivan: You can also use middleware like Rack::Static to serve up the static directory without Rails routes.
<havenwood>
John_Ivan: Basically your options for serving static files are 1) directly from reverse proxy, bypassing Rack, 2) in Rack middleware, bypassing Rails, or 3) Rails routes.
hololeap has quit [Remote host closed the connection]
<newton>
+1 wwr I recommend it to people looking for jobs often
<newton>
depending on the size of your company, even listing on linkedin or angel might be worthwhile
<newton>
I worked at a small startup up until a year ago and it would take weeks to months to hire rails developers
<newton>
to be fair the pay wasn't all that competitive tho :')
Guest4321 has joined #ruby
dangerousdave has joined #ruby
<adam12>
Definitely an employee market currently.
<adam12>
Nobody seems to want to hire juniors tho. If they were able to optimize for training, perhaps they'd have a great selection pool :)
<Rounin>
Yeah, hm... "We hired 0 employees! How come noone's working for us?"
<Rounin>
Somewhere along the line, companies forgot the bit where you have to tell people to come to work and give them money in order for work to happen
<Rounin>
Back when I got started, I got a job with a tiny company that had shit pay, but didn't make too many weird demands, actually hired people, and gave everyone important jobs, and although their retention was 0, they made tons, because they didn't spend all their time not hiring people
TrufflePump has joined #ruby
crundar has quit [Quit: Client closed]
<newton>
I guess that works great if you've got the revenue to always be hiring, a lot of startups with vc cash are not profitable for a while
hololeap has quit [Ping timeout: 240 seconds]
xuochi has joined #ruby
TrufflePump has quit [Ping timeout: 240 seconds]
xuochi has quit [Client Quit]
hololeap has joined #ruby
pgib has quit [Ping timeout: 255 seconds]
<Rounin>
Ah yes... Making money is also a good idea, heheh
<newton>
and some do! eventually :')
xuochi_ has joined #ruby
xuochi_ has quit [Client Quit]
xuochi_ has joined #ruby
xuochi_ is now known as xuochi
ur5us has joined #ruby
xuochi has quit [Quit: Konversation terminated!]
pgib has joined #ruby
tumdum has quit [Ping timeout: 240 seconds]
vacancies4 has joined #ruby
vacancies4 has quit [Ping timeout: 240 seconds]
stylo has quit [Quit: Connection closed for inactivity]
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Sheilong has quit []
ssh0732 has joined #ruby
<ox1eef>
i try to avoid start ups, it never really ends well. either they go bankrupt, or sell out and the new mgmt sucks, always something. its better to work for established companies, who arent just focused on a sell out.
<newton>
i did small companies/startups for most of my career until going to a larger company last year
<newton>
i like both, but i imagine myself going back to a startup after getting soaking up more of the big co sauce for a while longer, i like the challenges and ownership of working at a startup
<ox1eef>
well, i imagine it's not as black and white as i paint it. look at github, what an amazing experience that would have been, but now that MS bought them, i can't think of even one person who stayed.
<newton>
idk if i'd say they had any kind of mass exit either?
<ox1eef>
i dont think so, it happened slowly over time.
<newton>
like you're right: acquisitions suck. i've been through one, and left before another. i learned that i just won't stick around post-acq
<ox1eef>
yeah, seems that way indeed.
<newton>
a big company being acquired is vastly different than small startups tho
<newton>
when ms bought github, github was already very large, nobody would describe it as a startup
<ox1eef>
that's fair, but if you count the years alone, it wasn't so long.
<newton>
and how likely it is for the person buying you to kill your brand and eat you
<ox1eef>
i think they started in 2008, and solid in 2015? not sure
<ox1eef>
sold*
hololeap has quit [Ping timeout: 240 seconds]
<ox1eef>
i heard in japan that it's much more common to stay with one company for life, and i think that's an interesting idea.
hololeap has joined #ruby
<newton>
I hear it's getting better, but the work culture certainly hasn't been good there
dionysus69 has joined #ruby
<newton>
more power to people who want to work at one place for life; i think i'd get bored with the problems and want to move on to another
infinityfye has quit [Quit: Leaving]
xuochi_ has joined #ruby
xuochi_ is now known as xuochi
floss-jas has joined #ruby
xuochi has quit [Quit: Konversation terminated!]
xuochi has joined #ruby
howdoi has quit [Quit: Connection closed for inactivity]
Guest4321 has quit [Remote host closed the connection]