生产部署后如何阻止用户访问暂存区

发布于 2024-11-27 17:23:17 字数 399 浏览 1 评论 0原文

我们有一些具有不同角色的服务器。例如,我们有生产服务器和测试/登台服务器。我们有一些最终用户在测试、批准或使用产品后忘记切换到生产路径;他们使用新路径一段时间,然后在某个时候恢复使用测试/登台,原因是我们除了愚蠢之外无法理解。在将构建推入生产环境后,我们仍然希望能够了解我们的暂存环境,但我们希望阻止它们仍然能够访问这些服务器/服务。

我们现在正在考虑解决这个问题的一些办法。一是永远不要给他们直接的登台网址。一个想法是创建一个虚拟目录或拥有一组域别名,我们可以给它们然后关闭,同时仍然允许我们访问这些端点。我们可以将我们的主要临时域限制在办公室 IP 范围内,这样他们就永远无法直接访问并称其为良好。

这听起来是一个很好的解决方案吗?是不是我们的流程有问题,还有更好的路线吗?

我对无法有效使用视觉效果的网站和网络服务解决方案感兴趣。

We have a few servers that have different roles. For instance, we have production servers, and testing/staging servers. We have a few end users who forget to switch paths to production once things are tested and approved or use; They use the new paths for a bit, then revert back to using the testing/staging at some point for some reason that we can't understand other than stupidity. We still want to be able to get a glimpse into our staging environment after pushing a build into production, but we want to stop them from being able to still hit those servers/services.

We are now pondering some solutions to this problem. One being never give them the direct staging url. An idea would be to create a virtual directory or have a set of domain aliases that we could give them and then shut down while still allowing us access to these endpoints. We could restrict our main staging domain to the office ip range so they never have direct access and call it good.

Does this sound like a good solution? Is our process wrong, are there better routes?

I am interested in solutions for websites as well as web services where visuals can't be used effectively.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

深居我梦 2024-12-04 17:23:17

我们在工作中也遇到过这个问题……事实上是最近。除了虚拟目录之外,我想到的一件事是设置特定端口供它们进行测试,然后关闭这些端口或更改它们仅供我们内部使用。

We've run into this at my work as well… quite recently in fact. One thing that I thought about other than the virtual directory was setting up specific ports for them to test on then either take the ports down or change them for our internal uses only.

乖乖公主 2024-12-04 17:23:17

如果没有如何部署应用程序的详细信息,给出具体示例可能会很麻烦。一个美妙的解决方案是获得更好的用户:P 然而,也许更可能的解决方案是让您的生产设备将一组特定用户(根据您的代码决定)移动到您的测试/登台系统。 IE 用户总是连接到生产,但生产机器在连接/验证时,可能会认为这些人太酷了,不适合生产,让他们运行测试/登台代码。

当然,这不是一种完全可靠的方法,但它适用于许多网站,让一组特定用户进入其代码库的不同部分。

我不知道这对你来说有多可行,但这也许是一种可能性。

Well without details in how your application is deployed it could be troublesome to give concrete examples. One wonderful solution is to get better users :P Perhaps a more possible solution however is to let your production boxes move a certain set of users(as decided in your code) to your test/staging systems. I.E. the User always connects to Production, but the production machines at connect/auth time, may decide these people are too cool for production let them run the test/staging code instead.

It's not a fullproof method of course, but it works for many many websites to let a certain set of users into different parts of their codebase.

I don't know how feasible this would be for you, but it's a possibility perhaps.

完美的未来在梦里 2024-12-04 17:23:17

我发现用户有时对 URL 感到困难,并且不喜欢地址中的端口号等细微变化。

我发现的最好方法是让应用程序告诉用户他们所处的环境。

例如,我的团队使用了绝对定位的页眉或页脚,为开发/暂存环境进行颜色编码,用 alpha 显示应用程序版本号/beta 标签,以及一条消息,显示“在此站点上完成的工作将丢失,请使用 Production(链接)来保留您的工作。”通常我们将开发区域设置为红色,将暂存区域设置为黄色。我们还想在这个区域放置一个错误跟踪系统的链接。

在生产中通常没有这样的区域。但是,我们有时会通过放置一个绿色区域(其中包含应用程序版本和生产标签)来提供积极的强化,然后在几秒钟后使绿色区域消失。这有助于使应用程序保持在前端和中心位置,同时让用户知道他们位于正确的位置。

I find that users sometimes have difficulties with URLs, and don't like to have subtle changes like port number in the address.

The best approach I've found is to have the application tell the user what environment they are in.

For example, my teams have used absolutely positioned headers or footers, color coded for Dev/Staging environments that show the application version number with an alpha/beta tag, along with a message that says "Work done on this site will be lost, use Production (link) to keep your work." Typically we make the Dev area red, and the staging area yellow. We also like to put a link to the bug tracking system right in this area.

On production there is not usually a region like this. However, we do sometimes provide positive reinforcement by placing a green region, with the app version and a Production tag in it, and then fade the green region away after a few seconds. This helps keep the app front and center, but let's the user know they are in the right place.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文