1. Narayana Bhat P
  2. PowerServer
  3. Tuesday, 9 January 2024 06:37 AM UTC

Hi Team,

We have succesfully buuild our application in powerserver and able to convert and access through browser in localhost.

 Now we are trying to deploy application in ubuntun 22.04 

We are using below version of powerbuilder and powerserver

PowerBuilder Version 2022 R2 Build 2828

Powerserver Version 2022 R2 Build 2819

We have copied  below folder under path of /var/www/mytest

CloudAppPublisher

mytest

mytest_api

Post that we have executed below commnad under folder /var/www/mytest

dotnet ServerAPIS.dll

post that when we access http://powerserveruat.stohrm.com {ps_image_1} attached [internally hosted]

if we try to use  http://powerserveruat.stohrm.com/mytest then we get http error 404

Need step by step guide for deploying powerserver application on Lunix mechine, Document available in Appeon is more on IIS than linux

We are strungling this from past two weeks and not able to resolve

quick help will be highly appricable

If you need more info we are happy to provide same

Note: Actually same question my collegue asked on different thread and it is marked as resolved but actually it is not solved the issue and still we are struggling

https://community.appeon.com/index.php/qna/q-a/powerserver-5

THanks

Narayana Bhat P

 

 

 

 

Attachments (1)
Accepted Answer
Narayana Bhat P Accepted Answer Pending Moderation
  1. Friday, 8 March 2024 04:26 AM UTC
  2. PowerServer
  3. # Permalink
Hi team,
 
Able to make working copy of powerserver application in linux environment , below is the steps
 
Ubuntu 22.0 installation step
1. Install below software
a. .net 6.0 pre installed with ubuntu 22.00, if not install it
b. nginx
c. sqlanywhere 17 client or if your are setting database on same server then Sqlanywhere 17 server version
d. unixodbc
 
 
2. Configuration
a. vi /etc/odbcinst.ini
[SQL Anywhere 17]
Description=SAP SQL Anywhere 17 ODBC Driver
Driver=/opt/sqlanywhere17/lib64/libdbodbc17_r.so
Setup=/opt/sqlanywhere17/lib64/libdbodbc17_r.so
 
 
b. source /opt/sqlanywhere17/bin64/sa_config.sh
 
 
3.  Nginx Setup
vi /etc/nginx/sites-available/<site_name>
server {
   listen 80;
   listen [::]:80;
 
   server_name www.example.com;
 
   root /var/www/pstest;
   index index.html;
 
   location / {
   try_files $uri $uri/ =404;
   }
}
 
4. Create the odbc.ini file under /etc folder for dsn entry
a. vi /etc/odbc.ini
 
b. Make dns entry as per sample below
[dsn1]
Driver=SQL Anywhere 17
DatabaseName=demo1
ServerName=server1
CommLinks=tcpip(host=server.demo.com;port=2638)
 
[dsn2]
Driver=SQL Anywhere 17
DatabaseName=demo2
ServerName=server1
CommLinks=tcpip(host=server.demo.com;port=2638)
 
c. export ODBCINI=/etc/odbc.ini
 
 
3. Copy The Powerserver Application 
 
a. Copy powerserver build  below folder to /var/www/<site_name_folder>
1. CloudAppPublisher
2. <application name>
3. <application_name_API>
 
b. Change the API url in /var/www/<site_name_folder>/<application>folder/apprun.json
{
  "deployment_urls": {
"launcher": "CloudAppPublisher/CloudAppInstall 22.0",
"runtime": "CloudAppPublisher/runtime/22.1.0.2828",
"web_api": "http://www.example.com:81"
  }
}
 
 
4. Make the API service up
dotnet ./<application_name>_API/ServerAPIs.dll --urls http://www.example.com:81
 
5. Check Linux server firewall ports enable, enable required ports like below
a. 22 port for ssh 
b. 80 & 443 for application access
c. 81 or any other port for API url access 
Comment
  1. Arnd Schmidt
  2. Friday, 8 March 2024 14:53 PM UTC
Excellent!
  1. Helpful
  1. Armeen Mazda @Appeon
  2. Friday, 8 March 2024 18:04 PM UTC
Thank you for sharing the detailed steps!
  1. Helpful
There are no comments made yet.
Narayana Bhat P Accepted Answer Pending Moderation
  1. Tuesday, 23 January 2024 12:22 PM UTC
  2. PowerServer
  3. # 1

Hi team,

Attached is the error i am getting. SQL anywhere 17 linux version installed

unixODBC 2.3.9
DRIVERS............: /etc/odbcinst.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /root/.odbc.ini

Let me know what is the wrong here? why still i am getting "dependency unixodbc minimum 2.3 version required"

 

Narayana

Attachments (1)
Comment
  1. Armeen Mazda @Appeon
  2. Tuesday, 23 January 2024 15:39 PM UTC
I'm not sure this is not SQL Anywhere forum. Lots of PowerBuilder users also use SQL Anywhere so somebody else might be able to help with SQL Anywhere issues, but most people don't run SQL Anywhere on Linux.
  1. Helpful
  1. Narayana Bhat P
  2. Wednesday, 24 January 2024 04:25 AM UTC
Our Database server setup and run on Windows server only but for odbc driver purpose we have installed sql anywhere in linux
  1. Helpful
There are no comments made yet.
Narayana Bhat P Accepted Answer Pending Moderation
  1. Monday, 22 January 2024 11:32 AM UTC
  2. PowerServer
  3. # 2

Hi Team,

 

I am able to up the server and reached till database connection

In linux we need to configure virtual host either in apache or nginx like IIS, also we need to up the API service in seperate port which is actually not required in IIS

API service url to be refered in <application> folder /apprun.json file

i will share detailed steps once odbc connection issue resolved, currently i struck in unix odbc error

 

Narayana Bhat P

Comment
  1. Armeen Mazda @Appeon
  2. Monday, 22 January 2024 17:26 PM UTC
What database are you using?
  1. Helpful
  1. Narayana Bhat P
  2. Tuesday, 23 January 2024 05:18 AM UTC
SQL anywhere 16
  1. Helpful
There are no comments made yet.
Logan Liu @Appeon Accepted Answer Pending Moderation
  1. Wednesday, 10 January 2024 07:06 AM UTC
  2. PowerServer
  3. # 3

Hi Narayana,

I guess you haven't deployed the web server yet. Please notice that when you use the command "dotnet ServerAPIS.dll" to start the Web API application (mytest_api), other static file folders (CloudAppPublisher and mytest) will not be exposed by the Web API. So you can't access the default page of this Cloud App.

Normally, you should deploy these static files separately on your Web Server. E.g.:Nginx on Linux - - PowerServer 2022 R3 Help (appeon.com)

Alternatively, if you decide to use the Kestrel to serve as your File Server (within the same process of the Web API), you can refer to ASP.NET Core's doc to adjust the code to make it serve the static files. E.g.: Static files in ASP.NET Core | Microsoft Learn

Regards, Logan

Comment
  1. Narayana Bhat
  2. Wednesday, 10 January 2024 07:29 AM UTC
Dear Logan,



Thanks for the reply let me check and get back to you
  1. Helpful
There are no comments made yet.
Narayana Bhat Accepted Answer Pending Moderation
  1. Wednesday, 10 January 2024 04:30 AM UTC
  2. PowerServer
  3. # 4

Dear Armeen,

 

Thanks, Is that possible to share one sample application deployment to linux [any version] steps with default configuration . From there we can pickup, if still we couldn't resolve definetly we will connect partners

Can you do this help

 

Narayana

Comment
There are no comments made yet.
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Tuesday, 9 January 2024 18:38 PM UTC
  2. PowerServer
  3. # 5

It's not realistic that Appeon provide step-by-step guides for every possible scenario.  You really need somebody on your team that has a decent grasp on configuring and deploying cloud apps.  I would recommend you get some consulting help to set this up for you and also teach you how to deploy to linux because it's going to be hard to catch your various configuration mistakes without spending significant amount of time and inspecting your whole environment. https://www.appeon.com/consultants/consulting-partners

Comment
There are no comments made yet.
Narayana Bhat Accepted Answer Pending Moderation
  1. Tuesday, 9 January 2024 10:13 AM UTC
  2. PowerServer
  3. # 6

Additional information with screenshot attached

 

Attachments (1)
Comment
There are no comments made yet.
Narayana Bhat P Accepted Answer Pending Moderation
  1. Tuesday, 9 January 2024 06:40 AM UTC
  2. PowerServer
  3. # 7
Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.