473,396 Members | 2,029 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Publishing web site wipes out my web services

JT
Hi,

I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.

As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.

How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?

OR

How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?

Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.

Thanks!

JT

Nov 19 '06 #1
5 1753
I'm going to list the contents of a few files.
If the line has the prefix "+++", then this line is NOT in the file.

BuildDefault.bat
+++ Start BuildDefault.bat contents
:The below file contains a summary of each build
del BuildDefaultResultsRelease.txt

:The recompile of your soluction.
:You will need to rename MyDotNetSolution.sln to your .sln name
:Notice that this file will be in the same directory AS THE SOLUTION (.sln)
file
"C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE\devenv.exe"
MyDotNetSolution.sln /rebuild Release /out BuildDefaultResultsRelease.txt

:Xcopy the germane items
:The directory c:\wutemp\MySolution_Deploy\ should already exist (you can
name it anything)
:and it should be empty (or you get a bunch of "Overwrite file?" messages
:Also notice it uses the file XCopyExcludes.txt (which should also be in the
same directory as the .sln file)
xcopy *.* c:\wutemp\MySolution_Deploy\*.* /E /R /EXCLUDE:.\XCopyExcludes.txt

+++ End BuildDefault.bat

XCopyExcludes.txt
BuildDefaultResultsRelease.txt
XCopyExcludes.txt
+++++ Start XCopyExcludes.txt contents
..vbproj
..csproj
..scc
..resx
..vb
..cs
..snk
..pdb
..xsx
..xsd
..sln
..vssscc
..bat
++++ End XCopyExcludes.txt contents
Put both of these files in the directory with your .sln file.

Edit the bat file for your situation.
MyDotNetSolution.sln will need to be changed.
c:\wutemp\MySolution_Deploy\ should be changed and its easier if this
directory exists ~before running the .bat file.
C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE\devenv.exe
needs to reflect your location.

...

After you get your results, you can copy them over to a hosting company.
This is alot less drama in my book .... then the "publish" wizards.

If your in 2.0, then you can't "exclude"
..vb
..cs

You may have to alter the
xcopy *.*
to match up to what you're deploying. Sometimes you just get the /bin
folder (winforms),
xcopy *.* is for web sites.

"JT" <jt@onemain.comwrote in message
news:11**********************@j44g2000cwa.googlegr oups.com...
Hi,

I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.

As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.

How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?

OR

How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?

Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.

Thanks!

JT

Nov 19 '06 #2
Suggestion:
Get away from this whole thing of the "Web Site" project model. Download and
install the Web Application Project add-in, and you will find that the
semantics of updating a web site are as simple as copying (or ftp-ing) over
the /bin folder and all the .aspx / etc. files above it.

IMHO, the Web Application Project option, which was provided primarily
because of developer feedback to Scott Guthrie and his ASP.NET 2.0 team, is
far superior.
Cheers,
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"JT" wrote:
Hi,

I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.

As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.

How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?

OR

How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?

Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.

Thanks!

JT

Nov 19 '06 #3
JT
I have used the Web Application Project for converting a .NET 1.1 web
site to 2.0 and while it made that process much simpler, it seemed to
make it lose functionality in the IDE, namely no Publish option and no
copy option. Maybe I just haven't found them yet. I'm also
considering trying to "publish" locally to get the compiled files I
need and then FTPing them to the web host so that it doesn't delete
everything in sight. How about that?

JT

Peter wrote:
Suggestion:
Get away from this whole thing of the "Web Site" project model. Download and
install the Web Application Project add-in, and you will find that the
semantics of updating a web site are as simple as copying (or ftp-ing) over
the /bin folder and all the .aspx / etc. files above it.

IMHO, the Web Application Project option, which was provided primarily
because of developer feedback to Scott Guthrie and his ASP.NET 2.0 team, is
far superior.
Cheers,
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"JT" wrote:
Hi,

I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.

As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.

How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?

OR

How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?

Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.

Thanks!

JT
Nov 20 '06 #4
// I'm also
considering trying to "publish" locally to get the compiled files I
need and then FTPing them to the web host so that it doesn't delete
everything in sight. How about that?////////

That's what my stuff below is all about.

It builds in "release" mode, copies only the needed files to a seperate
directory. Then you can ftp from the seperate directory.

...
"sloan" <sl***@ipass.netwrote in message
news:uq*************@TK2MSFTNGP03.phx.gbl...
I'm going to list the contents of a few files.
If the line has the prefix "+++", then this line is NOT in the file.

BuildDefault.bat
+++ Start BuildDefault.bat contents
:The below file contains a summary of each build
del BuildDefaultResultsRelease.txt

:The recompile of your soluction.
:You will need to rename MyDotNetSolution.sln to your .sln name
:Notice that this file will be in the same directory AS THE SOLUTION
(.sln)
file
"C:\Program Files\Microsoft Visual Studio .NET
2003\Common7\IDE\devenv.exe"
MyDotNetSolution.sln /rebuild Release /out BuildDefaultResultsRelease.txt

:Xcopy the germane items
:The directory c:\wutemp\MySolution_Deploy\ should already exist (you can
name it anything)
:and it should be empty (or you get a bunch of "Overwrite file?" messages
:Also notice it uses the file XCopyExcludes.txt (which should also be in
the
same directory as the .sln file)
xcopy *.* c:\wutemp\MySolution_Deploy\*.* /E /R
/EXCLUDE:.\XCopyExcludes.txt
>
+++ End BuildDefault.bat

XCopyExcludes.txt
BuildDefaultResultsRelease.txt
XCopyExcludes.txt
+++++ Start XCopyExcludes.txt contents
.vbproj
.csproj
.scc
.resx
.vb
.cs
.snk
.pdb
.xsx
.xsd
.sln
.vssscc
.bat
++++ End XCopyExcludes.txt contents
Put both of these files in the directory with your .sln file.

Edit the bat file for your situation.
MyDotNetSolution.sln will need to be changed.
c:\wutemp\MySolution_Deploy\ should be changed and its easier if this
directory exists ~before running the .bat file.
C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE\devenv.exe
needs to reflect your location.

..

After you get your results, you can copy them over to a hosting company.
This is alot less drama in my book .... then the "publish" wizards.

If your in 2.0, then you can't "exclude"
.vb
.cs

You may have to alter the
xcopy *.*
to match up to what you're deploying. Sometimes you just get the /bin
folder (winforms),
xcopy *.* is for web sites.

"JT" <jt@onemain.comwrote in message
news:11**********************@j44g2000cwa.googlegr oups.com...
Hi,

I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.

As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.

How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?

OR

How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?

Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.

Thanks!

JT


Nov 20 '06 #5
JT
Sorry. It's been decades since I've used anything like XCopy. To me
it looked like a lot more work than just

1) compiling
2) opening an FTP connection with IE
3) dragging the files.

I didn't mean to dismiss it. I don't think I need to set up exclude
files, etc. I'll try my steps above first. If that doesn't work, then
that's only 2 minutes wasted.

Thanks for your suggestion. Right now just getting my web host to give
me useful information and not ignore me is a more urgent matter.

JT

sloan wrote:
// I'm also
considering trying to "publish" locally to get the compiled files I
need and then FTPing them to the web host so that it doesn't delete
everything in sight. How about that?////////

That's what my stuff below is all about.

It builds in "release" mode, copies only the needed files to a seperate
directory. Then you can ftp from the seperate directory.

..
"sloan" <sl***@ipass.netwrote in message
news:uq*************@TK2MSFTNGP03.phx.gbl...
I'm going to list the contents of a few files.
If the line has the prefix "+++", then this line is NOT in the file.

BuildDefault.bat
+++ Start BuildDefault.bat contents
:The below file contains a summary of each build
del BuildDefaultResultsRelease.txt

:The recompile of your soluction.
:You will need to rename MyDotNetSolution.sln to your .sln name
:Notice that this file will be in the same directory AS THE SOLUTION
(.sln)
file
"C:\Program Files\Microsoft Visual Studio .NET
2003\Common7\IDE\devenv.exe"
MyDotNetSolution.sln /rebuild Release /out BuildDefaultResultsRelease.txt

:Xcopy the germane items
:The directory c:\wutemp\MySolution_Deploy\ should already exist (you can
name it anything)
:and it should be empty (or you get a bunch of "Overwrite file?" messages
:Also notice it uses the file XCopyExcludes.txt (which should also be in
the
same directory as the .sln file)
xcopy *.* c:\wutemp\MySolution_Deploy\*.* /E /R
/EXCLUDE:.\XCopyExcludes.txt

+++ End BuildDefault.bat

XCopyExcludes.txt
BuildDefaultResultsRelease.txt
XCopyExcludes.txt
+++++ Start XCopyExcludes.txt contents
.vbproj
.csproj
.scc
.resx
.vb
.cs
.snk
.pdb
.xsx
.xsd
.sln
.vssscc
.bat
++++ End XCopyExcludes.txt contents
Put both of these files in the directory with your .sln file.

Edit the bat file for your situation.
MyDotNetSolution.sln will need to be changed.
c:\wutemp\MySolution_Deploy\ should be changed and its easier if this
directory exists ~before running the .bat file.
C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE\devenv.exe
needs to reflect your location.

..

After you get your results, you can copy them over to a hosting company.
This is alot less drama in my book .... then the "publish" wizards.

If your in 2.0, then you can't "exclude"
.vb
.cs

You may have to alter the
xcopy *.*
to match up to what you're deploying. Sometimes you just get the /bin
folder (winforms),
xcopy *.* is for web sites.

"JT" <jt@onemain.comwrote in message
news:11**********************@j44g2000cwa.googlegr oups.com...
Hi,
>
I think I need a "best practices" lesson on web sites and web services.
In order to conform to the restraints of my web host, my web services
seem to need to be in a subfolder of my web site. So if I have a
wwwroot folder containing my site, which maps to www.MySite.com, then
to reference my web service, MyService, I place it in a folder that
maps to wwwroot/MyService/MyService.asmx. This is dandy. I reference
it by using the URL, ftp://www.MySite.com/MyService/MyService.asmx, in
my WinForms application. The problem is that if I decide to make a
change to my web site and "publish" it, it tells me it is going to
delete the existing files, and it does; every file including my web
services.
>
As a big band-aid, we moved the services to a folder up at the same
level as the wwwroot and the web host tech support guy did some behind
the scenes magic so that I could refer to it with a subdomain,
MyService.MySite.com/MyService.asmx. He says that as soon as I do
anything with the control panel, it will break things. Also, this
seems like a bad way to deal with this.
>
How do I publish without deleting web services that are in subfolders
of my web site? Essentially, what is the best practice for having a
web site coexist with a completely separate web service?
>
OR
>
How do I position them so that no magic has to be performed by the web
host and nothing willl get broken when I change something in my control
panel?
>
Naturally, this needs to be locked down because if the web service is
moved, applications compiled against the web service will break.
>
Thanks!
>
JT
>
Nov 21 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: AVG | last post by:
Hi all, I am not sure where to post this, so please redirect me if not correct. Win 2003 Server IIS 6.0 dedicated internet server with only a single website. The basic IIS tree is as...
4
by: Will Chamberlain | last post by:
I have been creating a C# app in VS2005 for the past 2 weeks and am having the hardest time trying to run it from a remote IIS server. The application works great on localhost but when I move it I...
1
by: anon2005 | last post by:
Just wondering ... according to http://msdn2.microsoft.com/en-us/library/e22s60h9.aspx, static files (images, .html, etc) during deployment are supposed to be copied "as is" to the target...
0
by: UJ | last post by:
I currently have a web site that some SQL stored procs directly. I'm thinking of make those same calls available through web services and having my web site call those web services instead of...
1
by: Allan Ebdrup | last post by:
I have a asp.net v2 website that runs fine on our development server. I have published the website to a stage server and it runs fine, but when I publish it to production I get the following error:...
9
by: AG | last post by:
Using VS2005 Pro. I just deployed a ASP.NET 2.0 website (not web application) with the option to make it updatable. VS deployed all aspx, ascx files, but not all image or html files. It also...
1
by: tspell | last post by:
When I try to view my login page, I get the error below. Does anyone have any tips on how to publish the membership database? I copied the schema and data - and moved it to my sql database. Was...
0
by: Paulo Roberto | last post by:
When Im publishing the site, can the VS 2005 just send to FTP only the files wich have been changed? Because it always deletes all files and re-send them! Thanks in advance!
2
by: golub.gene | last post by:
Hi folks I need to choose Vista version, hopefully the lowest one like home edition, to have IIS services for some sql server feature to be active. Do you know which of those version have it. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.