Features of publishing 1c on the iis server. Configuring web servers to work with 1C:Enterprise. Publishing Settings in Internet Information Services Manager

They say that in 1C programming there are pure elves.

Refined developers who, according to exhaustive technical specifications, create imperishable creations in bright rooms with quiet music and dim lights :)

With weekly meetups and discussion of scrum “chickens” over coffee and cupcake :)

We've read about them, but haven't seen them yet.

Work of a 1C programmer/implementer
(and in general most 1C specialists)
- This not only programming

There are still a bunch of tasks that have nothing to do with the actual development, but are a mandatory part of the job any implementer or 1C programmer.

It is clear that everyone more or less copes with adding new users or placing checkboxes when setting up rights :)

But there are also topics that clearly have not become “mass knowledge.”

Therefore, we consider it useful to release additional materials.

Launching 1C:Enterprise under the web client

Today's topic comes from a summer survey (yes, we read the answers :)

The topic “1C and the web” continues to remain relatively new, for many it is terra incognita, which still needs to be dealt with.

Therefore, take away:

Introductory information on launching 1C under the web client

The very first introductory video lesson.

Web client features

The web client is one of the client applications in the 1C:Enterprise platform, and it differs significantly from the thick or thin client.
Let's look at the features and distinctive aspects of the web client

General scheme of working with 1C:Enterprise information databases via a web browser

This video discusses how to work with 1C:Enterprise information bases when using a web browser.
Which web servers can be used and which configurations can be run under the web client.

Publishing a database on a web server

This video discusses what actions need to be performed with the infobase so that it is available to the user through a browser.
It explains what publishing a database on a web server is.

Installing an IIS web server on Windows Server 2008. Publishing the 1C:Enterprise infobase

One of the web servers that 1C:Enterprise can work with is IIS from Microsoft. It is included with Windows Server.
This video explains how to install IIS and publish an infobase on it under Windows Server 2008.
We connect to the published database using Internet Explorer.

Publishing Settings in Internet Information Services Manager

In this video, using the IIS Services Manager, we look at what happens on the web server when publishing a database - what settings are installed, and what is located in the publishing directory.

Features of publishing file information databases

In this video we look at what errors with access rights can occur when publishing file infobases.

Connecting to a database published on a web server using a thin client

In this video we look at how to connect to an information base published on a web server, not only using a browser, but also under a thin client.
Such a database can be added to the list of databases in the launch window.

Installing IIS web server on Windows Server 2012 R2. Setting up work with a 32-bit extension

This video walks you through the process of installing an IIS web server on Windows Server 2012 R2.
It describes what settings need to be made to ensure that the 32-bit extension works under a 64-bit OS.

Publishing an infobase on a web server under Windows Server 2012 R2

This video explains how to publish an infobase under Windows Server 2012 R2; publishing must be done in the configurator as an administrator.

Configuring the 64-bit Web Server Extension Plug-in for IIS

This video explains how to install a 64-bit 1C:Enterprise server and how to configure a web server to work with this platform.

The task is to raise the IIS web server built into Windows and publish a 1C database on it on the 8.3 platform. There is nothing complicated about this.

We have a 2008 r2 enterprise server spinning on a virtual machine. Local administrator rights to it. Platform 1C 8.3.6.2041. We will create an empty information base. And so let's get started. Join our group on VK! Get it repaired! Smart workshop!

Installing the webserver role (IIS)

First you need to install the webserver role. Opening Server Manager, select the branch on the left Roles, click on the right Add a role.

We get to the step of selecting Server Roles and check the box next to Web Server (IIS). Click next. Now you need to correctly select the services of the installed role. Check the boxes exactly as in the screenshot below.

We complete the installation. The Add Role Wizard should tell us after a certain time that the role and all role services have been successfully installed:

Now we need to check if everything worked out well. Open any browser and go to the address http://localhost. We should see a happy picture like this:


installation of the 1c platform and components

This means that our web server has started up correctly and everything is working fine. So let's move on to 1s now. It is necessary to install a platform. The only caveat when installing the platform is to choose:

  • 1C:Enterprise
  • Web server extension modules
setting access rights

First of all, we need to configure the rights of the folder where our web server root directory is located. If you haven't changed anything, then by default it is C:\inetpub\wwwroot. Go to the folder C:\inetpub\ select a folder wwwroot, Right-click on it and go to properties. Go to the tab Safety. By clicking on the change button, we go directly to setting permissions. We find it in the list Groups and users, group Users, and by clicking on it put it in the column below Group Permissions, missing checkmarks in the column Allow.

Now you need to give rights to the folders with 1c installed. Let's move on to them, by default for the 32-bit version 1c is in the folder C:\Program Files (x86)\1cv8 for 64-bit in the folder C:\Program Files\1cv8. Also select the folder 1cv8 go to its properties, go to the tab Security -> Edit. But instead of selecting a group from the list, we need to add it there first. To do this, press the button Add, in the window that appears, press the button Additionally.


Next, click on the button Search and look in the result list IIS_IUSRS, adding it by double clicking returns us to the window Selecting Users or Groups but with the group already included in the list. Click OK and return to the window Group Permissions We put all the checkboxes in the allow field for the newly added group.

Having set permissions for folders with 1c files, we are left with the last thing. Give permissions to the group IIS_IUSRS folder where we have the 1C database itself.

The necessary preparations have been made. Now let's move on to publishing.

Publishing 1c on a web server

You need to launch 1c in configurator mode, selecting the database you need to publish. In my case, this is an empty database and there is only one.

In 1c configurator mode, go to the menu Administration -> Publishing to a web server.


After looking at the parameters and making sure that, in essence, everything suits us, we click Publish. If your publication went through without errors, let's move on to the last step.

setting up IIS to work with a 32-bit 1C web server extension module

Let me remind you that we used a 32-bit platform and a web server extension module from 1c, respectively. Therefore, in this case, we still need to allow the default application pool to run - DefaultAppPool run 32-bit applications. It's not difficult to do. Let's go Server Manager -> Roles -> Web server(IIS) -> Service Manager (IIS) -> Application Pools -> DefaultAppPool. Right click on DefaultAppPool call the context menu and select from it Additional options.


We are looking for a line 32-bit applications allowed and on the contrary we put TRUE

CONFIGURING IIS TO WORK WITH A 64-BIT 1C WEB SERVER EXTENSION MODULE

If we used a 64-bit platform and a web extension module, respectively, then we need to do the following manipulations:

Let's go Server Manager -> Roles -> Web server(IIS) -> Service Manager (IIS)-> And select the application converted from the virtual directory with the name that we specified when publishing the database. In the right field go to the section Handler Mappings. Publication of 1c 8.3 on the iis web server Publication of 1c 8.3 on the iis web server

Join our group on VK!

Publishing 1C:Enterprise 8.3 databases on the IIS web server in Microsoft Windows Server 2008/2012

In this article I will describe in detail the process of organizing web access to 1C:Enterprise databases 8.3 on the IIS (Internet Information Server) web server included with Microsoft Windows Server. For older versions of 1C:Enterprise ( 8.1 And 8.2 ) the algorithm for publishing databases is generally similar. The algorithm for setting up IIS for 1C:Enterprise will be discussed, and the process of publishing databases on a web server will also be described for both 32-bit, and for 64-bit web server extension module.

1. What you will need

  1. A computer that meets the minimum system requirements for running a web server running one of the operating systems:
    • Microsoft Windows Server 2012 (R2)
    • Microsoft Windows Server 2008 (R2)
  2. Local administrator rights on this computer.
  3. Distribution kit for installing 1C:Enterprise components. To configure a 64-bit web server extension module, a distribution kit for installing a 64-bit 1C:Enterprise server. This example uses the version 8.3.4.389 . For older versions of 1C:Enterprise ( 8.1 And 8.2 ) the algorithm for publishing databases is generally similar.

2. Installing the IIS web server

We install the Internet Information Server web server, which is included by default with Microsoft Windows Server. When installing, be sure to select the components:

  • Common HTTP Features
    • Static Content
    • Default Document
    • Directory Browsing
    • HTTP Errors
  • Application Development
    • ASP.NET 3.5
    • .NET Extensibility 3.5
    • ISAPI Extensions
    • ISAPI Filters
  • Health and Diagnostics
    • HTTP Logging
    • Request Monitor
  • Management Tools
    • IIS Management Console

I wrote in detail about the process of deploying an IIS web server:

  • In Microsoft Windows Server 2012 (R2) - . IIS version 8, after installation you should see a Default Web Site page like:

3. Installation of 1C:Enterprise components

On the same server where the IIS web server is deployed, we install 1C:Enterprise (32-bit components), making sure to select the following components during installation:

  • 1C:Enterprise
  • Web server extension modules

If you plan to configure a 64-bit web server extension module, you must additionally run the 64-bit server installation program from the corresponding 1C:Enterprise package and install the component:

  • Web server extension module

4. Setting up the operating system

Now you need to set the necessary rights to the key folders used when using web access to 1C:Enterprise databases. For the storage directory for website files published on the web server (default C:\inetpub\wwwroot\) you need to give full rights to the group " Users"(Users). In principle, you can skip this step, but then to publish or change the publication of the database you will need to run 1C:Enterprise as an administrator. To configure the security of this directory, right-click on it and select “ Properties"(Properties).

In the properties window that opens, go to the “ Safety" (Security) and press the button " Change» (Edit...), to change existing permissions. A permissions window for this directory will appear. In the list of Groups or user names, select the group “ Users" (Users) and in the list of permissions for the selected group set the flag " Full access"(Full control). Then click " Apply" (Apply) to record changes and close all windows using the button " OK».

Next, you need to give full rights to the directory with installed 1C:Enterprise files (by default C:\Program Files (x86)\1cv8\ for 32-bit expansion module and C:\Program Files\1cv8\ for 64-bit) group IIS_IUSRS. To do this, we perform actions similar to those described above, with the only difference that in order for the required group to appear in the list “ Groups or users" (Groups or user names) you must click the button located under the list " Add"(Add..), and in the window for selecting groups or users, click " Additionally"(Advanced...).

Then click the button on the right “ Search"(Find Now), then select the required group IIS_IUSRS in the search results table and click “ OK».

Group IIS_IUSRS appears in the list of groups or users. We give it full rights to the selected directory and click “ Apply» (Apply) to save changes.

And finally, if publishing is performed for a file database, you must also give the group IIS_IUSRS full rights to the directory containing the files of this infobase.

5. Publishing the database on a web server

Let's move on to directly publishing the database on the web server. To do this, launch 1C:Enterprise in Configurator mode for the database that you want to publish. Then select “ Administration» — « Publishing to a web server...»

The window for setting up publishing properties on the web server will open. The main fields required for publication are already filled in by default:

  • Virtual directory name - the name by which the database on the web server will be accessed. Can only consist of characters of the Latin alphabet.
  • Web server - selected from the list of web servers found on the current computer. In our case, this is Internet Information Services.
  • Directory - The physical location of the directory in which the virtual application files will be located.
  • Using the corresponding flags, you can specify the types of clients to publish, as well as indicate the possibility of publishing Web services. In the table below you can edit the list of Web services that will be published, as well as in the column “ Address» change the synonym by which this Web service will be accessed.
  • It is also possible for the IIS web server to indicate the need to perform authentication on the web server using OS means by setting the appropriate flag.

Having selected the necessary publishing settings, click “ Publish».

If the publication went through without errors, we will see a corresponding message.

Publishing to the IIS web server is always done for the default website and the default application pool. It is worth keeping in mind that when publishing from the configurator, the 32-bit web server extension module will be registered, and the default application pool will be DefaultAppPool- Without configuration, it only works with 64-bit applications. Accordingly, further actions depend on the bitness of the web server extension module that you plan to use. For a 32-bit web server extension, you must enable the application pool to use 32-bit applications, or register a 64-bit web server extension. This will be discussed below

6. Configure IIS to use the 32-bit Web Server Extension Plug-in

Means"(Tools) - " Internet Information Services Manager

Default Web Site— a virtual directory transformed into an application appeared with the name that we specified when publishing the database. The only thing left to complete publishing is to enable 32-bit applications for the default application pool. To do this, go to the “ tab in the connection tree Application Pools"(Application Pools).

In the list of application pools we find a pool with the name DefaultAppPool. Right-click on it and select “ Additional options"(Advanced Settings).

In the application pool settings window that opens, in the group “ General"(General) find the item " 32-bit applications allowed» (Enable 32-Bit Applications) and set the parameter value to True. Then save the changes by clicking " OK».

7. Configure IIS to use the 64-bit Web Server Extension Plug-in

You can register the 64-bit web server extension module using the utility webinst.exe the corresponding version located in the directory bin, directory with the 1C:Enterprise program installed, or use the method below.

Let's launch Internet Information Services (IIS) Manager. This can be done from the Server Manager by selecting the “ Means"(Tools) - " Internet Information Services Manager» (Internet Information Services (IIS) Manager).

Here, expanding the tree in the connections window, we will see that for the default website - Default Web Site— a virtual directory transformed into an application appeared with the name we specified when publishing the database. To complete publishing, all that remains is to tell the application to use a 64-bit request processor. To do this, open the handler mapping settings page for this virtual directory by selecting “ Handler Mapping» (Handler Mappings) on the application home page.

In the table of handler comparisons we find the handler "1C Web-service Extension". Let's open this handler by double-clicking on the corresponding row in the table.

Let's edit the handler by replacing the path to the executable dll of the 32-bit web server extension module that is currently selected with the path to the 64-bit version of the library. In this example, we change the path from " C:\Program Files (x86)\1cv8\8.3.4.389\bin\wsisapi.dll" to " C:\Program Files\1cv8\8.3.4.389\bin\wsisapi.dll» using the selection button. After changing the path, click " OK» to save changes.

8. Connect to a published infobase via a web browser

Well, that seems to be all. To connect to a newly published database, launch Internet Explorer and enter a path like this in the address bar http://localhost/<Имя публикации информационной базы> . In this example it is http://localhost/DemoAccounting/.

You can also connect to this information base from any computer on the network by accessing the web server via its internal one (or if the port is forwarded 80 , by external) IP address.

In this case, for 1C:Enterprise to work correctly, the domain name being accessed (or IP address) must be added to trusted Internet Explorer sites, and pop-up windows must be allowed for it. Read more about setting up Internet Explorer for the 1C:Enterprise web client.

9. Connecting to a published information base through the 1C:Enterprise client

You can also connect to an information base published on a web server using the 1C:Enterprise thin client. To connect, open the “1C:Enterprise” launch window and click the “ Add» to add an information base.

In the window for adding an infobase/group, set the switch to “ Adding an existing infobase to the list" and click " Next».

Enter the name of the database as it will be displayed in the list of infobases (must be unique for this list), select the location type " On the web server" and click " Next».

Specify the launch parameters for the infobase and click “ Ready» to complete the wizard.

After which this information base will appear in the list of databases in the 1C:Enterprise launch window. Please note that the Configurator launch mode is not available for this type of connection. Click " 1C:Enterprise» to connect to the information base.

Step-by-step instructions on how to set up web access to 1C databases. I wrote it for myself as an instruction so as not to forget in the future. Maybe it will be useful to someone else.

Setting up client-server access to 1C via WEB interface

This article provides instructions on how to organize work with the 1C configuration via an Internet browser.

For the article, we used the 1C setup for working with the MS SQL Server database and Internet Information Services, included in the operating system, was used as a web server.

Before starting the installation, 1C with the application server, SQL Server 2005 and higher must be installed, and Internet Information Services must be running.

The following software versions were used as an example to describe this article:

All the steps described can work both on older releases of programs and on younger ones. The minimum requirements are indicated on the 1C website - http://v8.1c.ru/requirements/

Before starting the settings, the products listed above in the table must be installed on your computer. In this case, the 1C server and SQL server can be located on different physical or virtual computers. It is desirable that Server 1C and Internet Information Services be located on the same physical and logical server (this will reduce problems with settings).

The entire setup process is divided into 5 steps:

1 - Registration of configuration and database on 1C and SQL servers

2 - Setting up IIS on the server to publish the configuration

3 - Publishing a WEB application from 1C

4 - Configuring libraries to work in a 64-bit OS

5 - Setting folder access rights and Windows Firewall

In addition, the article contains information on how to access the published site.

As well as information about the resources used

7. Resources used

1. Registering the database on 1C and SQL servers

1.1. Launch Server 1C

After installing 1C, you need to make sure that the 1C server is running. The author usually starts the server manually. But if you are sure that the 1C server is running, then you do not need to do this step.

1.2. Register a 1C cluster

Launch the 1C server administration utility:

In the window that opens, register a new central 1C server of the enterprise:

In the window that appears, enter the network name of the computer on which 1C Server is running (or its IP address):

1.3. Register 1C database on SQL server

To start registering the database, you need to launch the 1C application. In the “Launch 1C:Enterprise” window that appears, register a new database by clicking on the “add” button:

Select "Create a new infobase":

In the window that appears, you have the opportunity to create a database from a template, or create a new empty database (later you can load the database, load the configuration, or create your own configuration):

It should be noted that the field " Database name" are the names of the database on the SQL server. And the field " Infobase name" - name of the database on the 1C server.

Then select the authentication option in 1C (Select automatically) and click the “Finish” button:

1.4. Download or create 1C configuration

Launch the configurator with the database:

Load the previously downloaded information base:

2. Setting up IIS on the server

For this point, information was taken from the article: http://infostart.ru/public/71480/

2.1. Checking installed IIS components

To operate the 1C:Enterprise web client, IIS services are required, which were not installed by default when installing Windows 8.1 x64.

To install them, go to "Start - Control Panel - Programs and Features - Turn Windows features on or off." In the tree that appears, in the branch “IIS Services - Internet Services - Application Development Components”, select all components, as shown in the figure. Then click the "Ok" button:

2.2. Allow 32-bit applications in the application pool

Web client 1C:Enterprise 8.3 is a 32-bit application. Therefore, for a 64-bit OS, you must allow them to run in the application pool of the IIS server. To do this, go to "Start - Control Panel - Administrative Tools - Internet Information Services Manager". In the Service Manager, select "Application Pools - DefaultAppPool - Advanced Settings". In the list of additional parameters of the variable "Allowed 32-bit applications" set the value to "True":

Set "Allow 32-bit applications" to True:

2.3. Setting the application pool identity as an anonymous user identity

By default, the anonymous user is set to the IUSR user, who is not in the system. To avoid creating one, you can simply enable the application pool identity as an anonymous user identity. To do this, go to "Start - Control Panel - Administrative Tools - Internet Information Services Manager". In Service Manager, go to "Authentication:

At the "Anonymous authentication" item, call the "edit" context menu:

In the dialog that opens, select “Application pool identity.” Close the dialog by clicking the "OK" button.

3. Publishing a WEB application from 1C

To publish an application, you must have full access to the IIS projects folder. There are 2 ways to publish an application from 1C. 1 - first create the necessary folder in the directory "C:inetpubwwwroot" in our case it is a folder called "Base1C" and give the current user rights to full access to this folder. 2nd way to log into 1C as an administrator and then give the necessary rights to the folder of the already published application. This article describes the second way.

3.1. To publish the configuration on the IIS server, you need to run 1C as an administrator:

Call the context menu on the 1C shortcut and select "Run as administrator"

Select the database and launch 1C in configurator mode:

3.2. Start publishing on a web server

To start publishing, go to the menu "Administration - Publishing on a web server":

In the window that appears, specify the name of the publication, specify the web server and specify the path on the web server.

1C allows you to publish to any available web server on the network using the webinst utility. The article used an example of publishing to a local computer:

More detailed information on the items in the publication window can be obtained from the 1C configurator by pressing the F1 button.

4. Configuring libraries to work in a 64-bit OS

After publishing on a web server from the configurator, if you are using a 64-bit operating system on a computer that is used as an IIS server, you need to configure work with 1C libraries. This is done every time it is published to the web server.

To configure libraries, you must complete the following steps.

Open via Control Panel - Administrative Tools Internet Information Services Manager.

In the window that opens, expand the “Sites” group and our site (in the example, Base1C).

Click on "" in the group IIS:

In the window that opens, look for the line named "ISAPI-dll" and click the menu item in the actions "Add script mapping..."

In the open "Add Script Mapping" window, in the "Request Path" field, enter the symbol * (asterisk, i.e. all). In the "Executable file" field, select the wsisapi.dll library from the directory of the installed 32-bit version of 1C. In the "Name" field you can specify any name (in the example Name = 1C):

Some experts in other articles indicate that you need to disable the query matching restriction. The author did not find any dependence on the operation of this mark for the 1C program. This information is provided for informational purposes; someone may need it.

You can configure query limits by clicking the Query Limit button in the Add Script Mapping window. In the window that opens, uncheck “Call the handler only when matching a request with:”:

Click the Ok button.

Answer “Yes” to the question that appears:

Then you need to restart the IIS service. To do this, go to the root of the "Connections" panel (to the name of the server) and select "Restart" in the action menu on the right:

Then we can check whether the connected library works. To do this, go to “ISAPI and CGI Restrictions”:

Once again, it should be noted that this procedure for setting up libraries should be done every time after publishing an application from 1C.

5. Setting folder access rights and Windows Firewall

5.1. Configuring folder access

For all users, not just administrators, to work correctly with published web applications, you need to configure some folder permissions.

To configure rights to pakpi, you need to call the context menu for the required folder in Windows Explorer and select " Properties" and go to the bookmark " Safety"

In this case we are talking about rights to 3 folders:

1. "C:Program Files (x86)1cv88.3.5.1088bin"(the wsisapi.dll library is located in this folder) (the release number "8.3.5.1088" may be different)

2. C:inetpubwwwrootBase1C(this is the folder we created that will be used for access from the Internet)

3. CatalogBases(this is a 1C database if a file type of database is used), in our example the database is stored on a SQL server, so there is no database directory and there is no need to give access to it.

For all folders (Items: 1,2,3) required for the user IIS_IUSRS set access " Full access":

For the folder with our database (Point 3) user data Users, set access " Change".

5.2. Configuring port access in Windows Firewall

If you plan to use web access not only locally, then you need to configure the Windows Firewall for access from external resources, specifying access port 80. The author did not use the firewall settings, but simply disabled it:

6. Access to the published information base

To access the information base, you need to go to an Internet browser (supporting HTML5, for example, “beloved by many” Internet Explorer) and enter in the address bar:

You can reduce system requirements for user machines as much as possible and make full use of the capabilities implemented in you by publishing 1C on a web server. This will allow you to organize work with the database not only using a thin client, but also using any browser, without installing additional components and applications.

Basic Requirements

The minimum system requirements for the server side of the architecture can vary significantly and are highly dependent on:

  1. Problems solved by the program;
  2. Intensity of document flow;
  3. Number of simultaneously connected users;
  4. The size and number of published and registered databases.

However, it is simply impossible to do without two things when publishing 1C on a web server:

  • A web server deployed in the system;
  • An installed and running expansion module supplied by 1C.

Web server

This element of our structure can be either the Internet Information Server (IIS), supplied as part of operating systems from Microsoft, or the Apache server. Of course, there are paid analogues of these solutions, but we won’t talk about them.

An additional advantage of Apache products is the ability to run them from Linux-like operating systems.

We will consider the option with IIS, because... it does not require searching for and installing third party products.

Web server extension modules

Installation of these modules can be done by running the platform delivery file. Having reached the window, the appearance of which is shown in Fig. 1, you need to activate the installation of the corresponding component.

Naturally, in addition to the extensions, the 1C Enterprise platform itself must be installed on the computer, otherwise we will not have access to the Configurator, through which the main part of the publication is performed.

Having decided on the tools, let's move on to configuration.

Installing and starting a Web server

In order to launch IIS on a computer with Windows installed, you need to perform the following sequence of actions (using Windows 7 as an example):


Fig.3

You can make sure that the web server is working by entering a line like “http://localhost” in the address bar of any browser and receiving a picture as in Fig. 4.

Fig.4


Fig.6.

In some cases (in particular, if the program operates in a 64-bit operating system), after publishing the database on the server, you may have to further configure the work with the libraries used by the 1C platform. This can be done from the “Sites” submenu.

Having selected a specific, just published database in the list, you need to activate the “Handler Mapping” utility (Fig. 7).
Fig.7

In our case, we will need to establish a correspondence between ISAPI-dll and the wsisapi.dll executable file located in the BIN folder of the installed version of the platform.

In principle, at this point the main part of the work with the server can be considered completed, let’s move on directly to publishing the database.

Publishing the database to the server

Setting up user rights

Having received the above window, we proceed to setting up access rules for users.

We need to allow full access to the IIS_USERS user:

  • To the folder “C:\inetpub\wwwroot\Publication name”, where the resource is stored;
  • To the folder with the version of the program in use, where the wsisapi.dll library is stored;
  • To the place where the database is stored.

Having completed the above steps, we can check the functionality of our publication by entering a line like “localhoct/Publication name” in the browser window and finding a user identification form there.