by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Jay Brodie
@jbrodie
I have specific revisions loaded since this is Rails 5.2 and there isn't a tag or release for it.
# Refinery CMS
# View the repo at this point:  https://github.com/refinery/refinerycms/tree/81ed9917c0ed528bdcb0d91bbecf408d3c89706a
gem "refinerycms", git: "https://github.com/refinery/refinerycms", ref: "81ed991"

# Optionally, specify additional Refinery CMS Extensions here:
gem 'refinerycms-acts-as-indexed', '~> 3.0'
gem 'refinerycms-wymeditor', '~> 2.2'
gem 'refinerycms-authentication-devise', git: "https://github.com/refinery/refinerycms-authentication-devise.git", ref: "4fbe542"
gem 'refinerycms-videos', path: 'vendor/extensions'
Jay Brodie
@jbrodie
@jussihirvi ok so I pulled my head out of my ass on that login thing and actually logged in. It has already been a long week. I can see the images under localhost:3000/refinery/images as you can see below, so could it be some helper or the way they were referenced in the page content that is actually the issue?
image.png
Jay Brodie
@jbrodie
hmm

HA! So, production links images as /system/images/W1siZiIsIjIwM... where as the new local is using /system/refinery/images/W1siZiIsIjIwMT...

So somewhere it is injecting the refinery in the path locally, I guess I need to find a spot to override it?

Jay Brodie
@jbrodie
There is a different key on them. The ones on the pages seem to be linked into the pages with the key after images/ which is different than the ones if I view them from the refinery admin.
Anita Graham
@anitagraham
@jbrodie The part of the image url beginning with W1siZ is a base-64 encoded string telling dragonfly which image to get, and what processing (if any) to do on it. For instance I just decoded a string (using base64decode.org) from W1siZiIsIjIwMTkvMTEv... to [["f","2019/11/11/18/46/24/9941b2ff-e356-4d0a-8a6e-cf26bdb75d36/Plain.png"],["p","thumb","50%"]]. (I don't think using a geometry string of 50% is working. :frowning: )
Dalleau Théo
@Shirikumo
Hi, thank you @bricesanchez
Brice Sanchez
@bricesanchez
Thanks @jussihirvi, i will take the time to review your PR (refinery/refinerycms#3467) :)
jussihirvi
@jussihirvi

@jbrodie My image paths in the page source (= src parameters in image tags) are /system/refinery/images in both development and production. Images (from S3) are visible in both environments.

Just one wild thought: if you want to use S3 in development and production, do you also have the dragonfly-s3_data_store gem loaded for both environments?

Jay Brodie
@jbrodie

@jussihirvi Yes, I have the gem exposed for all environments.
@anitagraham I am working on an instance I inherited from an older Rails 5.1 version, I am using the production DB restored locally with the buckets for S3 copied to a new dev version of the bucket. I was unaware of the encoding aspect of that so that is a little more insight. Thanks.

The only difference I can see is the pathing on them at this point. The new install, updated to Rails 5.2 is injecting an additional folder layer of refinery between the system and the images folder. I can only assume this would be some configuration somewhere that I can't seem to see.

Jay Brodie
@jbrodie
So, turns out, that the old default route to images in dragonfly isn't the same as the new one. Adding this line back into the images.rb initializer seems to have corrected the routing to the images on the old path config.dragonfly_url_format = "/system/images/:job/:basename.:ext"

@jussihirvi Thanks for all the time you have spent assisting me with this port. It seems that the previous developers did some strange things to make this work including using some videos plugin, which complicates things much more.

The amount man bastardization I was having to do to upgrade this to Rails 5.2 just isn't worth it. There are problems after problems for very little gain. We are going to leave it for now and do a fresh spin up on the current version of Refinery (which natively supports video now) and port in all our data to a new instance in the future. Atleast we have an answer now on this.

Thanks again to you and everyone that commented and helped out. I learned somethings on Refinery, and something about the crappy job the initial implementors did on our end.

jussihirvi
@jussihirvi
@jbrodie Congrats for finally finding the answers you were looking for.
jussihirvi
@jussihirvi
Is there some widget available somewhere to switch the locale of the refinery backend? I can do it by adjusting config.current_locale in the i18n initializer. But that's not convenient for the site administrators who have no access to the source code.
Brice Sanchez
@bricesanchez
This feature was in the refinery dashboard which was removed years ago. You could reintroduced a locale switcher for user in their profile : refinery/refinerycms-authentication-devise#19
Chris Moody
@DesignPlayBox_twitter
Hi all, I'm wanting to check out Refinery. If I need it to run as domainx.com and not domainy.com how do I do this? I've installed Phusion for Apache and ran "gem install refinerycms" already
Chris Moody
@DesignPlayBox_twitter
I think I figured out that question, but turns out having issues with the gem actionmailer not compiling correctly :(
javoor1
@javoor1

Hello everyone! I, as some others, am having problems with images in Heroku.

I've been trying a few things but nothing seems to work. Does anyone knows how to fix the problem?

2020-02-14T03:56:29.526941+00:00 app[web.1]: I, [2020-02-14T03:56:29.526814 #4] INFO -- : [6b9b7602-3396-4ff2-83e5-972de0e45e2e] Started GET "/system/refinery/images/W1siZiIsIjIwMjAvMDIvMTQvNXkzNnhkOWsweV81OTk1NjI4OF82MTEyNTM4NzI3MDc1MTVfNTg2MjMwODg5NTQzODE1NzgwOF9uLmpwZyJdLFsicCIsInRodW1iIiwiMTQ5eDE0OSNjIl1d/59956288_611253872707515_5862308895438157808_n.jpg" for 201.160.193.28 at 2020-02-14 03:56:29 +0000
2020-02-14T03:56:29.527489+00:00 app[web.1]: W, [2020-02-14T03:56:29.527401 #4] WARN -- : [6b9b7602-3396-4ff2-83e5-972de0e45e2e] DRAGONFLY: uid 2020/02/14/5y36xd9k0y_59956288_611253872707515_5862308895438157808_n.jpg not found
2020-02-14T03:56:29.527604+00:00 app[web.1]: I, [2020-02-14T03:56:29.527517 #4] INFO -- : [6b9b7602-3396-4ff2-83e5-972de0e45e2e] DRAGONFLY: GET /system/refinery/images/W1siZiIsIjIwMjAvMDIvMTQvNXkzNnhkOWsweV81OTk1NjI4OF82MTEyNTM4NzI3MDc1MTVfNTg2MjMwODg5NTQzODE1NzgwOF9uLmpwZyJdLFsicCIsInRodW1iIiwiMTQ5eDE0OSNjIl1d/59956288_611253872707515_5862308895438157808_n.jpg 404

javoor1
@javoor1
image.png
image.png
Tom Connolly
@ThomasConnolly
Heroku will not store images. You must store them at AWS3 or some other location.
javoor1
@javoor1
image.png
@ThomasConnolly Thanks! I discovered that the first problem was that the buildpacks in heroku were not in order. ruby needs to be the last one.
jussihirvi
@jussihirvi
@bricesanchez Thanks again. Using set_localeGET parameter works fine for me. I added a language-change link in the _site_bar.html.erb file.
Brice Sanchez
@bricesanchez
@jussihirvi You're welcome!
robacarp
@robacarp
Hey folks, I have an existing Rails 6 application, and need a CMS. I need to be able to embed admin-editable sections into pages all over the site, including the login page. As well, I'd like to be able to declare a template and allow pages to be created based off of that template. Are these things Refinery can do?
robacarp
@robacarp
Additionally, there are a bunch of gems in the refinery repository... given that I already have user management and a bunch of other features in place, what gem should I even be installing?
robacarp @robacarp kicks rock
Forrest Chang
@fkchang
Is there a way to require login for resources? I'm able to do it with the cms pages, but anyone can view the resources
Forrest Chang
@fkchang
Ok, it seems that dragonfly middleware is the reason why
it ignores my authenticate_user! filter in ApplicationController
Forrest Chang
@fkchang
So looks like I'll need a bump to refinerycms-dragonfly to 1.0.2 to include this PR refinery/refinerycms#3452
so that I can actually override the before_serve for dragonfly
I see this one was accepted https://github.com/refinery/refinerycms/pull/3451/files but it's not on rubygems yet. Can we get that pushed?
Forrest Chang
@fkchang
Using the sha for now
Forrest Chang
@fkchang
jussihirvi
@jussihirvi
This place is so silent. Is there a better place to discuss refinerycms?
jussihirvi
@jussihirvi

In my refinerycms 4.0.3 app, a logged-in refinery user can always access his own user page. This is necessary for example if they want to change their password.

However, on the user page, any user can also control their own plugin access. This rrenders the whole plugin access selection meaningless. Has this been fixed in newer versions?

I made a temporary hack where only a superuser can see and select plugin access permissions.

Brice Sanchez
@bricesanchez

This place is so silent. Is there a better place to discuss refinerycms?

@jussihirvi Sadly, it's the place where there is the more discussions

However, on the user page, any user can also control their own plugin access. This rrenders the whole plugin access selection meaningless. Has this been fixed in newer versions?

Are you sure you're not a superuser?

Brice Sanchez
@bricesanchez

I made a temporary hack where only a superuser can see and select plugin access permissions.

Nice! Do you think you could provide a Pull Request?

Anita Graham
@anitagraham
Sorry, I lost my pinned gitter page.
Anita Graham
@anitagraham
Hi. I have a troubled relationship with Git. ( Downfall/Git rant. )
I have made changes to some refinerycms gems, and I want to upload them to my own forks, but not have those changes appear as a PR on the original gems.
I have had this happen unexpectedly in the past. My question is: how do I isolate my uploads to my fork of the gem?
Many thanks for all help.
Daniel
@Znow
Hi guys;
Upgrading an older application to newest refinerycms version 4.0.3. When accessing the "Files" tab in Refinery backend, I get the following error generated by refinerycms-resources: "ActionView::Template::Error at /refinery/resources
undefined method `new' for BigDecimal:Class". I can provide the full stacktrace. Have also searched and searched for anything that relates to this, but havent found anything. Would be so glad for another pair of eyes on this issue, thanks.
Daniel
@Znow
Finally found the isssue. Refinery-resources table and translation table, is not updated from using bigint to int, have to do migration manually to change this
Anita Graham
@anitagraham
@Znow I have done that, but not tested and scrutinized enough to do a PR. Will be coming one day.
Dalleau Théo
@Shirikumo
Hello, I followed the guide to create an extension and I don't have an entry point in admin. I use refinery 4 with rails 5.1.7. I checked the routes, they do exist but I can't find the page by typing the url directly. any idea to solve the problem ?
Anita Graham
@anitagraham
look at the output of rake routes > routes.txt (routes.txt)
Dalleau Théo
@Shirikumo
Thanks, routes were correct, finally got the answer. It was a permission missing to the user, got confused because the devise superuser role makes my refinery redirect by looping but worked well with refinery role and access on the user settings for the extension.