I am new to Heroku. Recently I created a NodeJS application with the Heroku git and deployed it on Heroku. I used the following command to clone the repository to my local computer from the Heroku git.
heroku git:clone -a {app_name}
How would I be able to browse the repository on the Heroku git rather than locally, like GitHub?
In your heroku account, go to your app -> Settings.
Under App Information, you'll find the heroku git url.
How would I be able to browse the repository on the Heroku git rather than locally, like GitHub?
You don't.
Heroku is a platform as a service hosting provider, not a repository host. You can clone from it, but that's not what it's designed to do:
Heroku provides the git service primarily for deployment, and the ability to clone from it is offered as a convenience. We strongly recommend you store your code in another git repository such as GitHub and treat that as canonical.
It doesn't provide a web interface to its Git repositories.
Related
So I a deployed a Node.js website to Heroku earlier (through Github) and today I made a few changes. I did the same git add . git commit -m 'changes' git push commands but the website on Heroku hasn't changed. Automatic deploys are ON. The code on my Github changed and is correct.
I also used git push heroku master and heroku config:set NODE_MODULES_CACHE=false , it doesn't update the code. Website still the same, like at first deploy.
Also did purge cache.
heroku releases checks out. And I checked the file with heroku bash on the Heroku servers, the file is also updated there. Still, I can't see the changes on the website. Tried different browsers, phones, incognito... And I only use master branch.
FIXED IT:
npm run build in the client folder. Even though I did it already before my first deploy, have to do it again after the changes. Then you can push, commit, deploy, whatever...
I have made changes to some css and js file in my Node-React apllication which is deployed on Heroku. But the changes are not showing up when I git add . the project on heroku. ALthough the changes are not coming up when I run the project locally.
Any help would be appreciated on what could be the possible cause on the changes not getting deployed?
You need a few more commands in your deployment workflow.
The git add . command is putting your local changes into staging.
You also need to run git commit -m 'your commit message' in order to commit those local changes to your local git repository.
Next, you need to run git push to push your local repository to the remote repository it is linked with.
Effective use of git is one of the most useful things you can teach yourself as a developer. It will enable you to contribute effectively to a team when the time comes. Here's a good starter article: Basic Git With Examples.
I first used the following link to create a new Keystone app from Heroku:
https://dashboard.heroku.com/new?button-url=https%3A%2F%2Ft.co%2FjbNu7UtZpn&template=https%3A%2F%2Fgithub.com%2FJedWatson%2Fkeystone-starter
Then I wanted to clone it to my local repo:
➜ Nodejs heroku git:clone -a yellowkorner
Cloning from app 'yellowkorner'...
Cloning into 'yellowkorner'...
warning: You appear to have cloned an empty repository.
Checking connectivity... done
But when I cd into the folder it's an empty repo, however the app is live online and working fine. Confused! Please help. Thanks
Check the remote repo url of your local clone:
cd /path/to/local/cloned/repo
git remote -v
I suspect it references a fork of https://github.com/JedWatson/keystone-starter, meaning a repo in your GitHub account.
In that case, any fork done by heroku seems to be empty by default.
See this answer to populate its content.
I'm trying to use cute-files on my openshift account
https://www.npmjs.com/package/cute-files
I know node.js works as I did in localhost:3000 but not as expert,
I'm ended up with http://cutefiles-powerupware.rhcloud.com/ that's not I'm looking it. It should be Cute-files app as start.
I did PuTTY to access terminal to do npm-install but no luck due to permission.
The problem is... I cannot understand how openshift works, I need to know how to access console to do npm-install then, execute "$ cute-files", alternativley I've used Git to commit and push, the files are updated...I got no results... I've spent like 6 or 7 hours, Openshift has been very complicated me to use, can anyone explain how to install and execute simple node.js app in openshift?
It's not like you can access Openshift and run any command. Openshift isn't a simple hosting or vps service, it's a PaaS. That means they offer you an environment to run certain services in particular as you demand.
When you create an app it's bound to a git repository which when pushed will be deployed to openshift.
About your application being deployed and runned, it's NOT about node.js running in port 3000. Openshift has some default application file names and port to expect.
So, working in a local clone of such repository you might perform the npm install command, that will download the node_modules folder to be there.
How to do all this?
First you should install rhc in your system.
Manage to clone any of you applications via rhc.
Make changes, and do git.
Those changes may include doing npm install getting your dependencies.
When doing git push, expect the changes to be deployed.
You really should read this guide.
I installed GithubHQ in one server and GitlabCI in another server. But now I need do integration between GitlabHQ and GitlabCI. When I go to add a new project in GitlabCI he requests a path .git project, but the project is on another server where the GitlabHQ.
I tried use the path remote, like: http://[domain-name]/[user]/[project].git but he not accept.
I researched about how GitlabCI search the path and found that it does not support remote paths. He use "Rugged::Repository.new(path)" just to get the project on the server.
Does anyone know a way to use paths .git remotes in GitlabCI?
As illustrated by Issue 36:
Actually the purpose of gitlab-ci implies that you install it on deployment point. You install it where you deploy your project
So you are supposed to use a local non-bare repo.
You could, in your case, clone your remote repo on the gitlab-ci server, and use that local path.
In order to build an integration between gitlab and gitlab-ci:
add gitlab_ci user to git group for read access
clone your project via git clone /home/git/repositories to somewhere like /home/gitlab_ci/projects/...
add this project to ci.
setup gitlabhq to use ci service
Thats all.
On gitlab push it will trigger gitlab ci to make git fetch origin, so testing repo will be always up to date.