CSS not showing as same as local on Heroku - css

Here's what I did already before thinking this is a duplicate.
I let heroku do the rake assets:precompile
I did it locally, added it to git and pushed
None of these worked? I am thinking maybe Heroku somehow cached the assets which doesn't make sense to me but I have no other ideas at this point. Is this cache idea really possible on Heroku?

As far as I know Heroku doesn't cache any assets.
Try to run the following:
rm -rf public/cache
git commit -am "Removing cache files"
git push heroku master
If it doesn't work try this:
rm -rf public/cache
RAILS_ENV=production bundle exec rake assets:precompile
git add public/cache
git commit -am "Updated Compiled assets"
git push heroku master
You've probably already read Rails Asset Pipeline on Heroku Cedar, if not check it out.
Hope it helps.

Related

Magento 2 Deploy CSS Updates

I am trying to figure out a way to move in css updates in production mode without any downtime or maintenance mode enabled.
For example, if I update something in theme's style.css, I will need to run the commands below to get the css updates included in the merged css file.
rm -rf var/view_preprocessed/*
rm -rf pub/static/frontend/*
php bin/magento setup:static-content:deploy
php bin/magento cache:flush
But this will create downtime. Running deploy command along will not update the css.
Any suggestions?

WordPress plugin isn't deployed to OpenShift

After setting up WordPress site on OpenShift, I tried to upload new plugin from my local repo, according this manual, but nothing was uploaded to OpenShift.
Step I've done:
# cloning WordPress app from OpenShift
rhc git-clone -a wpdev
# Going to plugins folder on local machine
cd ~/openshift/wpdev/.openshift/plugins
# cloning my plugin from GitHub to openshift plugins folder
git clone https://github.com/samuelsh/youtube-channel-player.git
# standart add/commit/push
git add plugins
git commit -m "youtube-channel-player deploy to openshift"
git push
After checking my wpdev app on openshift, looks like my plugin isn't uploaded.
What could go wrong here?
Thanks
Well, appeared it was git submodule issues.
Trying explicitly add new files to repo resulted following error:
git add .openshift/plugins/youtube-channel-player/*
fatal: Pathspec '.openshift/plugins/youtube-channel-player/admin' is in submodule '.openshift/plugins/youtube-channel-player'
Removing the directory from git and adding it again worked for me:
git rm --cached directory
git add directory

Setup VPS with a Symfony2 project from git repository

I have a:
- VPS with LAMP stack
- local symfony2 project (git)
- bitbucket repository
What do I need to do to properly setup my project in the production evironment?
Folder structure/permissions?
Can I simply clone the repository in the public folder? (I don't think so)
P.s. I've already read the deployment guide on the symfony2 website, but I didn't find it very useful
Here are my deployment steps:
git clone project
go to project directory
php composer.phar install (and if composer is not in the project
directory curl -sS https://getcomposer.org/installer | php)
app/console doctrine:database:create
app/console schema:update --force
app/console assets:install web --symlink
chmod 777 -R app/cache app/logs web/media/cache (I often use liip
imagine, it resizes photo in web/media/cache)
point the virtual host of apache to the web directory of my project.
And you are done.
you might want to enable mode rewrite in apach (a2enmod rewrite) I think this covers everything.

Removed Stylesheet from application but it still appears on Heroku

I remove a stylesheet that contained media queries for specific devices. The changes appear on my local version. When I view it in production on heroku the media queries are still there. I asset removed it from the assets initializer # Rails.application.config.assets.precompile += %w( apps.css ). I ran heroku run assets:clean and restarted the server but it still remains. git status shows that there are not uncommitted changes.
You will have to do a couple of more steps:
$ rake assets:precompile
$ git add .
$ git commit
... deploy to heroku
rake assets:clean just removes the compiled assets locally; without running the precompile step to generate new assets, the assets on heroku does not get refreshed.

How to deploy html5 boilerplate publish folder ( probably using git-ftp )

I am still searching for a good development -> deployment workflow (mostly for smaller websites) using html5 boilerplate + build script, gitHub, and probably git-ftp.
The problem is I can’t figure out a cool way of how to deploy the publish folder of html5 boilerplate to my webserver (where I normally have no ssh access)
How do you do it?
What if the website uses a CMS like redaxo?
Just use git-ftp in the "publish" folder:
Make a git repository out of the "publish" folder
cd publish
git init
git add .
git commit -m "This is now a git repo"
Configure git-ftp in publish/.git/config, then use:
git ftp init
use the syncroot option of git-ftp to specify the directory to sync from as if it were the git project root path. In .git/config under [git-ftp] add
syncroot = publish/

Resources