i deployed the application in aws linux machine.we have installed rstudio,rbase,shiny server in the machine.
the app is running fine from the rstudio.
the application should be available to end users when they hit the link :3838/myapps.but it is showing the below error.

Warning: Error in if: argument is of length zero
  69: ui
   3: <Anonymous>
   1: rmarkdown::run
Warning: Error in if: argument is of length zero
  69: ui
   3: <Anonymous>
   1: rmarkdown::run

what is the solution for this?

Can you show your app's code?

I cant share the code as it is confidential.we cant find where the problem is if it is from application code or infra side.it is running fine from the rstudio.
But we cant run it from the shiny-server

Rstudio and shiny-server run under different underlying environments, viewing the code could have gave us some clues to find the mismatch. This doesn't seem like an infrastructure issue strictly speaking because shiny-server itself doesn't rely on rmarkdown. I think this is more likely an R setup issue.

R setup means r installation

I mean the R ecosystem installation and how it is configured

This is the error from web link

I suspect you haven't installed the required R packages system-wide, by default shiny-server runs as the "shiny" user so it doesn't have access to packages installed by other users on their user-level package library.

If that is the case, then try installing packages from the system terminal with sudo, for example

sudo su - -c "R -e \"install.packages('some_package', repos='http://cran.rstudio.com/', lib = '/usr/local/lib/R/site-library')\""

now i am able to see the page from the :3838/myapps.
it is loading slow.
i am get the below eror in logs

Warning: Error in filter: object 'actr_floods' not found

That is a warning message not an error and whether it is importan or not depends on your actual code and the validity of the results you are getting.

Sadly, I can't help you with that without seen your code or at least an analogous REPRoducible EXample (reprex) illustrating your issue.

We divided the code into server.R and ui.R.
We are anle to see the page from :3838/myapps.

But while trying to download html file from the code it is showing server problem.
We checked the logs and the warning showing as object x not found.
The app is running fine from the rstudio and we are able to download html file.
But we are not able to do it from shiny-server

It is impossible for us to know what your problem is without any information. If you can't share the actual code, I recommend you to put together an analogous reprex that ilustres your issue.

Here is how to do it for a shiny app