Deployment Datasnap based HTML5 Builder webpage on shared hosting - deployment

I created webpage(webapp) in HTML5 Builder, which is running with Datasnap server. On localhost everything is OK, I can say I'm very satisfied. When I try to deploy it on low budget hosting it shows errors like:
Warning: require_once(rpcl/datasnap/ServerFunctionExecutor.inc.php): failed to open stream: No such file or directory in /home/maniu/domains/site.com/public_html/rpcl/rpcl.inc.php on line 163
Fatal error: require_once(): Failed opening required 'rpcl/datasnap/ServerFunctionExecutor.inc.php' (include_path='.:/usr/local/php55/lib/php') in /home/maniu/domains/site.com/public_html/rpcl/rpcl.inc.php on line 163
So I started searching and the conclusion is that this kind on webapp can't run on shared hosting. My question is: I must buy dedicated server for it? Is theres an option to deploy it on for example Amazon Elastic Compute Cloud (EC2)? Or other cloud? Other ideas?

Related

Issue connecting composer to Blockchain on Bluemix - identity or token does not match

I have fabric composer 0.72 installed on my mac, and I was able to follow this thread to get it connected to my Blockchain (v.61 of Fabric) on Bluemix.
fabric-composer-integration-with-bluemix-blockchain-service
Now I am trying to build an ubuntu (16.04) docker container and run composer-rest-server there. When I try to connect to my blockchain service from my docker container (using the same id, WebAppAdmin, that I used on my mac) I get an error:
Discovering types from business network definition ...
Connection fails: Error: Identity or token does not match.
It will be retried for the next request.
{ Error: Identity or token does not match.
at /home/composer/.nvm/versions/node/v6.10.3/lib/node_modules /composer-rest-server/node_modules/grpc/src/node/src/client.js:417:17 code: 2, metadata: Metadata { _internal_repr: {} } }
I tried copying the cert from my mac to my docker container:
/home/composer/.composer-credentials/member.WebAppAdmin
but when I did that I got a different error that says "signature does not verify". I did some additional testing, and I discovered that if I used an id that I had not previously used with composer (i.e. user_type1_0) then I could connect, and I could see a new cert in my .composer-credentials directory.
I tried deleting that container and building a new one (I dorked something else up) I could not use that same userid again.
Does anybody know how security and these certs are supposed to work? It would seem as though something to do with certificate generation/validation is tied to the client (i.e. hardware address), such that if I try to re-use an id on a different machine, the certs or keys or something don't match. I have a way to make things work, but it doesn't seem like it's the right way if I can't use the same id from different machines.
Thanks!
Hi i tried to recreate this by having blockchain running on a unix machine and then i copied my connection profile and certificate to my mac and then edited my connection profile to update the ip address and key store. I then did a composer network ping and it worked fine.
I am using composer v0.7.4 so you could try that?
I have also faced this issue, and concluded that
There is inconsistent behavior while deploying network using composer on Cloud environment includeing Bluemix. Problem is not with composer, but with fabric 0.6.
I am assuming that this issue is also indirectly related to following known bugs into fabric 0.6, which will not be fixed in fabric 0.6.
ERROR:
"
throw er; // Unhandled 'error' event
^
Error
at ClientDuplexStream._emitStatusIfDone (/home/ubuntu/.nvm/versions/node/v6.9.5/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:189:19)
at ClientDuplexStream._readsDone (/home/ubuntu/.nvm/versions/node/v6.9.5/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:158:8)
at readCallback (/home/ubuntu/.nvm/versions/node/v6.9.5/lib/node_modules/composer-cli/node_modules/grpc/src/node/src/client.js:217:12)
"
So far, We have understood that following three JIRA are root cause , where essentially the cloud networking layer ends up killing the idle event hub connection after a period of inactivity and the fabric SDK cannot handle this.
https://jira.hyperledger.org/browse/FAB-4002 FAB-3310
https://jira.hyperledger.org/browse/FAB-3310
or FAB-2787
Conclusion:
There is no alternative way of fixing this issue with Bluemix or any cloud environment with fabric 0.6
You may not experience this issue with Fabric 1.0, but there is still possibilities as all above mentioned defects are not fixed yet.

Error pushing changes to cloud foundry

from my local host, I connected to blue mix with
cf api https://api.ng.bluemix.net
I logged in and then I pushed the changes with
cf push
However, in the console,
Uploading MY_PROJECT...
Uploading app files from: /Users/MyName/Documents/MY_PROJECT
Uploading 437.7K, 386 files
Done uploading
FAILED
Error processing app files: Error uploading application.
The resource file mode is invalid: File mode '0444' is invalid.
(venv) My-iMac:MY_PROJECT MyName$
How do I trouble shoot this?
According to this link: https://github.com/cloudfoundry/cli/issues/685 the file mode must be at least 600 so I guess you should "raise" the permissions for your resources folder, even if 444 would be technically ok.
Concerning troubleshooting: the error message is right there in your output. If you need more log output, you can use the command
cf logs APP-NAME
See https://docs.cloudfoundry.org/devguide/deploy-apps/streaming-logs.html for further details.

Google cloud datalab deployment unsuccessful - sort of

This is a different scenario from other question on this topic. My deployment almost succeeded and I can see the following lines at the end of my log
[datalab].../#015Updating module [datalab]...done.
Jul 25 16:22:36 datalab-deploy-main-20160725-16-19-55 startupscript: Deployed module [datalab] to [https://main-dot-datalab-dot-.appspot.com]
Jul 25 16:22:36 datalab-deploy-main-20160725-16-19-55 startupscript: Step deploy datalab module succeeded.
Jul 25 16:22:36 datalab-deploy-main-20160725-16-19-55 startupscript: Deleting VM instance...
The landing page keeps showing a wait bar indicating the deployment is still in progress. I have tried deploying several times in last couple of days.
About additions described on the landing page -
An App Engine "datalab" module is added. - when I click on the pop-out url "https://datalab-dot-.appspot.com/" it throws an error page with "404 page not found"
A "datalab" Compute Engine network is added. - Under "Compute Engine > Operations" I can see a create instance for datalab deployment with my id and a delete instance operation with *******-ompute#developer.gserviceaccount.com id. not sure what it means.
Datalab branch is added to the git repo- Yes and with all the components.
I think the deployment is partially successful. When I visit the landing page again, the only option I see is to deploy the datalab again and not to start it. Can someone spot the problem ? Appreciate the help.
I read the other posts on this topic and tried to verify my deployment using - "https://console.developers.google.com/apis/api/source/overview?project=" I get the following message-
The API doesn't exist or you don't have permission to access it
You can try looking at the App Engine dashboard here, to verify that there is a "datalab" service deployed.
If that is missing, then you need to redeploy again (or switch to the new locally-run version).
If that is present, then you should also be able to see a "datalab" network here, and a VM instance named something like "gae-datalab-main-..." here. If either of those are missing, then try going back to the App Engine console, deleting the "datalab" service, and redeploying.

What's the cause of "Failed to preload gadget..." for Sharebox gadgets in IBM Connections

I've followed the procedure documented at "Adding new ways to share content"
...but keep getting an error:
Failed to preload gadget http://....
Detailed error: 400 Gadget is not trusted to render in this container. cre.iruntime:cre.iwidget.event:cre.wire:cre.iwidget:cre.iwidget.itemset:cre….ibm.connections.ee:ibm.connections.ee:container.nongadget:open-views.js:4
sharebox error http://i7.minus.com/ibiLz4SSWA5EL8.png
This looks like some sort of trust problem with external servers, but my other gadgets (embedded experience & home page gadgets) on the same external host are all working fine.
What have I missed out in the configuration?
OK, shamefully, it looks like I missed out swapping the security attribute whitelistEnabled="true" to whitelistEnabled="false" in:
/opt/IBM/WebSphere/AppServer/profiles/Dmgr01/config/cells/connectionswwCell01/LotusConnections-config/opensocial-config.xml
Here:
<security whitelistEnabled="false" featureAdminEnabled="true">
More details in this slide: How to add your own OpenSocial Gadgets to IBM Connections.
Of course, in a production system, you'll have to checkout the opensocial config using wsadmin.sh, edit, checkin & restart.

Shared hosting error on my Zend based Application

I have just sucessfully tested my Zend based application on the localhost.When I deployed it on a shared hosting site I got the error below.It happens whenever I try navigate to protected pages of my application.
Warning: include(/home/davidkag/public_html/prototype/application/models/DbTable//Users.php) [function.include]: failed to open stream: No such file or directory in /home/davidkag/public_html/prototype/library/Zend/Loader/Autoloader/Resource.php on line 176
I have a feeling that the double slashes
models/DbTable//Users.php)
are causing this problem.
The error is caused at this particular line in my code:
Fatal error: Class 'Model_DbTable_Users' not found in /home/davidkag/public_html/prototype/application/controllers/AuthController.php on line 24
How do I trouble shoot this problem.Keep in mind that on my localhost machine its working fine.
I would start by creating a new test script, with one line, and see what you get:
include '/home/davidkag/public_html/prototype/application/models/DbTable//Users.php';
Then, remove the double slashes:
include '/home/davidkag/public_html/prototype/application/models/DbTable/Users.php';
If it's still giving you that warning, then either your path is wrong or your file permissions need to be eased.
P.S. You said 'protected pages' -- are those perhaps not in public_html?
I finally found my problem.It was a case issue.Talk of developing on windows and deploying on linux