passenger 5.3.4 → 6.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (283) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG +69 -0
  3. data/CONTRIBUTORS +1 -0
  4. data/README.md +2 -1
  5. data/Rakefile +0 -5
  6. data/build/agent.rb +6 -3
  7. data/build/cxx_tests.rb +28 -19
  8. data/build/integration_tests.rb +6 -2
  9. data/build/misc.rb +2 -1
  10. data/build/packaging.rb +2 -0
  11. data/build/support/cplusplus.rb +2 -2
  12. data/build/support/cxx_dependency_map.rb +2651 -2189
  13. data/dev/colorize-logs +272 -0
  14. data/dev/show-latest-crashlog-dir +27 -0
  15. data/resources/templates/standalone/http.erb +2 -0
  16. data/resources/templates/standalone/server.erb +1 -0
  17. data/src/agent/AgentMain.cpp +4 -0
  18. data/src/agent/Core/AdminPanelConnector.h +6 -6
  19. data/src/agent/Core/ApiServer.h +4 -4
  20. data/src/agent/Core/ApplicationPool/BasicProcessInfo.h +2 -2
  21. data/src/agent/Core/ApplicationPool/Context.h +5 -1
  22. data/src/agent/Core/ApplicationPool/Group/InternalUtils.cpp +2 -2
  23. data/src/agent/Core/ApplicationPool/Group/LifetimeAndBasics.cpp +5 -0
  24. data/src/agent/Core/ApplicationPool/Group/Miscellaneous.cpp +2 -1
  25. data/src/agent/Core/ApplicationPool/Group/OutOfBandWork.cpp +3 -3
  26. data/src/agent/Core/ApplicationPool/Group/ProcessListManagement.cpp +1 -1
  27. data/src/agent/Core/ApplicationPool/Group/StateInspection.cpp +13 -20
  28. data/src/agent/Core/ApplicationPool/Group.h +4 -2
  29. data/src/agent/Core/ApplicationPool/Implementation.cpp +5 -5
  30. data/src/agent/Core/ApplicationPool/Options.h +42 -38
  31. data/src/agent/Core/ApplicationPool/Pool/GroupUtils.cpp +2 -1
  32. data/src/agent/Core/ApplicationPool/Pool.h +4 -4
  33. data/src/agent/Core/ApplicationPool/Process.h +13 -15
  34. data/src/agent/Core/ApplicationPool/Socket.h +5 -5
  35. data/src/agent/Core/ApplicationPool/TestSession.h +3 -3
  36. data/src/agent/Core/Config.h +50 -10
  37. data/src/agent/Core/ConfigChange.cpp +13 -1
  38. data/src/agent/Core/Controller/Config.h +41 -17
  39. data/src/agent/Core/Controller/ForwardResponse.cpp +4 -0
  40. data/src/agent/Core/Controller/InitRequest.cpp +14 -8
  41. data/src/agent/Core/Controller/InitializationAndShutdown.cpp +5 -0
  42. data/src/agent/Core/Controller/SendRequest.cpp +9 -9
  43. data/src/agent/Core/Controller/TurboCaching.h +2 -2
  44. data/src/agent/Core/Controller.h +7 -5
  45. data/src/agent/Core/CoreMain.cpp +204 -60
  46. data/src/agent/Core/OptionParser.h +20 -3
  47. data/src/agent/Core/ResponseCache.h +3 -3
  48. data/src/agent/Core/SecurityUpdateChecker.h +4 -2
  49. data/src/agent/Core/SpawningKit/Config/AutoGeneratedCode.h +1 -1
  50. data/src/agent/Core/SpawningKit/Config.h +3 -2
  51. data/src/agent/Core/SpawningKit/Context.h +8 -2
  52. data/src/agent/Core/SpawningKit/DirectSpawner.h +4 -4
  53. data/src/agent/Core/SpawningKit/DummySpawner.h +3 -3
  54. data/src/agent/Core/SpawningKit/ErrorRenderer.h +1 -1
  55. data/src/agent/Core/SpawningKit/Exceptions.h +21 -14
  56. data/src/agent/Core/SpawningKit/Factory.h +1 -1
  57. data/src/agent/Core/SpawningKit/Handshake/BackgroundIOCapturer.h +1 -1
  58. data/src/agent/Core/SpawningKit/Handshake/Perform.h +14 -2
  59. data/src/agent/Core/SpawningKit/Handshake/Prepare.h +3 -3
  60. data/src/agent/Core/SpawningKit/Handshake/WorkDir.h +1 -1
  61. data/src/agent/Core/SpawningKit/Journey.h +4 -5
  62. data/src/agent/Core/SpawningKit/PipeWatcher.h +1 -1
  63. data/src/agent/Core/SpawningKit/README.md +34 -17
  64. data/src/agent/Core/SpawningKit/Result/AutoGeneratedCode.h +1 -1
  65. data/src/agent/Core/SpawningKit/Result.h +20 -8
  66. data/src/agent/Core/SpawningKit/SmartSpawner.h +7 -7
  67. data/src/agent/Core/SpawningKit/Spawner.h +25 -8
  68. data/src/agent/Core/SpawningKit/UserSwitchingRules.h +17 -7
  69. data/src/agent/Core/TelemetryCollector.h +681 -0
  70. data/src/agent/ExecHelper/ExecHelperMain.cpp +1 -1
  71. data/src/agent/FileReadHelper/FileReadHelperMain.cpp +198 -0
  72. data/src/agent/README.md +1 -1
  73. data/src/agent/Shared/ApiAccountUtils.h +1 -1
  74. data/src/agent/Shared/ApiServerUtils.h +3 -3
  75. data/src/agent/Shared/ApplicationPoolApiKey.h +2 -2
  76. data/src/agent/Shared/Fundamentals/AbortHandler.cpp +324 -98
  77. data/src/agent/Shared/Fundamentals/AbortHandler.h +31 -4
  78. data/src/agent/Shared/Fundamentals/Initialization.cpp +4 -5
  79. data/src/agent/Shared/Fundamentals/Initialization.h +9 -1
  80. data/src/agent/SpawnEnvSetupper/SpawnEnvSetupperMain.cpp +1 -1
  81. data/src/agent/SystemMetrics/SystemMetricsMain.cpp +4 -3
  82. data/src/agent/TempDirToucher/TempDirToucherMain.cpp +3 -3
  83. data/src/agent/Watchdog/ApiServer.h +3 -3
  84. data/src/agent/Watchdog/Config.h +24 -5
  85. data/src/agent/Watchdog/CoreWatcher.cpp +2 -2
  86. data/src/agent/Watchdog/WatchdogMain.cpp +97 -28
  87. data/src/apache2_module/Config.cpp +14 -14
  88. data/src/apache2_module/Config.h +8 -16
  89. data/src/apache2_module/ConfigGeneral/AutoGeneratedDefinitions.cpp +510 -481
  90. data/src/apache2_module/ConfigGeneral/AutoGeneratedDefinitions.cpp.cxxcodebuilder +39 -17
  91. data/src/apache2_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.cpp +5 -0
  92. data/src/apache2_module/ConfigGeneral/AutoGeneratedSetterFuncs.cpp +69 -1
  93. data/src/apache2_module/ConfigGeneral/AutoGeneratedSetterFuncs.cpp.cxxcodebuilder +31 -1
  94. data/src/apache2_module/ConfigGeneral/Common.h +45 -0
  95. data/src/apache2_module/DirConfig/AutoGeneratedCreateFunction.cpp +17 -1
  96. data/src/apache2_module/DirConfig/AutoGeneratedCreateFunction.cpp.cxxcodebuilder +16 -1
  97. data/src/apache2_module/DirConfig/AutoGeneratedHeaderSerialization.cpp +19 -5
  98. data/src/apache2_module/DirConfig/AutoGeneratedHeaderSerialization.cpp.cxxcodebuilder +26 -9
  99. data/src/apache2_module/DirConfig/AutoGeneratedManifestGeneration.cpp +19 -1
  100. data/src/apache2_module/DirConfig/AutoGeneratedManifestGeneration.cpp.cxxcodebuilder +10 -1
  101. data/src/apache2_module/DirConfig/AutoGeneratedMergeFunction.cpp +14 -1
  102. data/src/apache2_module/DirConfig/AutoGeneratedMergeFunction.cpp.cxxcodebuilder +11 -1
  103. data/src/apache2_module/DirConfig/AutoGeneratedStruct.h +36 -1
  104. data/src/apache2_module/DirConfig/AutoGeneratedStruct.h.cxxcodebuilder +34 -1
  105. data/src/apache2_module/DirectoryMapper.h +36 -37
  106. data/src/apache2_module/Hooks.cpp +27 -8
  107. data/src/apache2_module/ServerConfig/AutoGeneratedManifestGeneration.cpp +20 -0
  108. data/src/apache2_module/ServerConfig/AutoGeneratedStruct.h +48 -1
  109. data/src/apache2_module/ServerConfig/AutoGeneratedStruct.h.cxxcodebuilder +36 -1
  110. data/src/cxx_supportlib/{Utils → Algorithms}/Hasher.cpp +2 -2
  111. data/src/cxx_supportlib/{Utils → Algorithms}/Hasher.h +4 -4
  112. data/src/cxx_supportlib/AppLocalConfigFileUtils.h +148 -0
  113. data/src/cxx_supportlib/AppTypeDetector/CBindings.cpp +147 -0
  114. data/src/cxx_supportlib/AppTypeDetector/CBindings.h +75 -0
  115. data/src/cxx_supportlib/{AppTypes.h → AppTypeDetector/Detector.h} +92 -131
  116. data/src/cxx_supportlib/ConfigKit/README.md +90 -2
  117. data/src/cxx_supportlib/ConfigKit/Schema.h +60 -15
  118. data/src/cxx_supportlib/ConfigKit/Store.h +129 -5
  119. data/src/cxx_supportlib/Constants.h +1 -1
  120. data/src/cxx_supportlib/{Utils → DataStructures}/HashMap.h +4 -4
  121. data/src/cxx_supportlib/DataStructures/HashedStaticString.h +5 -5
  122. data/src/cxx_supportlib/DataStructures/LString.h +3 -3
  123. data/src/cxx_supportlib/{Utils → DataStructures}/StringMap.h +36 -36
  124. data/src/cxx_supportlib/FileTools/FileManip.cpp +1 -1
  125. data/src/cxx_supportlib/FileTools/PathManip.cpp +2 -2
  126. data/src/cxx_supportlib/FileTools/PathSecurityCheck.cpp +1 -1
  127. data/src/cxx_supportlib/Hooks.h +2 -2
  128. data/src/cxx_supportlib/{Utils → IOTools}/BufferedIO.h +5 -5
  129. data/src/cxx_supportlib/{Utils → IOTools}/IOUtils.cpp +4 -3
  130. data/src/cxx_supportlib/{Utils → IOTools}/IOUtils.h +3 -3
  131. data/src/cxx_supportlib/{Utils → IOTools}/MessageIO.h +7 -7
  132. data/src/cxx_supportlib/{MessageReadersWriters.h → IOTools/MessageSerialization.h} +5 -5
  133. data/src/cxx_supportlib/InstanceDirectory.h +4 -4
  134. data/src/cxx_supportlib/Integrations/LibevJsonUtils.h +3 -3
  135. data/src/cxx_supportlib/{Utils → JsonTools}/JsonUtils.h +5 -5
  136. data/src/cxx_supportlib/LoggingKit/Context.h +2 -2
  137. data/src/cxx_supportlib/LoggingKit/Implementation.cpp +3 -3
  138. data/src/cxx_supportlib/MemoryKit/mbuf.cpp +2 -2
  139. data/src/cxx_supportlib/ProcessManagement/Ruby.cpp +3 -3
  140. data/src/cxx_supportlib/ProcessManagement/Ruby.h +7 -2
  141. data/src/cxx_supportlib/ProcessManagement/Spawn.cpp +19 -12
  142. data/src/cxx_supportlib/ProcessManagement/Spawn.h +21 -2
  143. data/src/cxx_supportlib/ProcessManagement/Utils.h +10 -0
  144. data/src/cxx_supportlib/RandomGenerator.h +2 -2
  145. data/src/cxx_supportlib/ResourceLocator.h +1 -1
  146. data/src/cxx_supportlib/{Crypto.cpp → SecurityKit/Crypto.cpp} +4 -4
  147. data/src/cxx_supportlib/{Crypto.h → SecurityKit/Crypto.h} +4 -4
  148. data/src/cxx_supportlib/{Utils → SecurityKit}/MemZeroGuard.h +0 -0
  149. data/src/cxx_supportlib/ServerKit/AcceptLoadBalancer.h +2 -2
  150. data/src/cxx_supportlib/ServerKit/Channel.h +1 -1
  151. data/src/cxx_supportlib/ServerKit/ClientRef.h +17 -7
  152. data/src/cxx_supportlib/ServerKit/Context.h +2 -2
  153. data/src/cxx_supportlib/ServerKit/FileBufferedChannel.h +1 -1
  154. data/src/cxx_supportlib/ServerKit/HttpHeaderParser.h +3 -3
  155. data/src/cxx_supportlib/ServerKit/HttpHeaderParserState.h +2 -2
  156. data/src/cxx_supportlib/ServerKit/HttpRequestRef.h +17 -7
  157. data/src/cxx_supportlib/ServerKit/HttpServer.h +16 -10
  158. data/src/cxx_supportlib/ServerKit/Server.h +3 -4
  159. data/src/cxx_supportlib/{Utils → StrIntTools}/DateParsing.h +5 -5
  160. data/src/cxx_supportlib/{Utils → StrIntTools}/StrIntUtils.cpp +3 -3
  161. data/src/cxx_supportlib/{Utils → StrIntTools}/StrIntUtils.h +0 -0
  162. data/src/cxx_supportlib/{Utils → StrIntTools}/StrIntUtilsNoStrictAliasing.cpp +12 -12
  163. data/src/cxx_supportlib/{Utils → StrIntTools}/StringScanning.h +5 -5
  164. data/src/cxx_supportlib/{Utils → StrIntTools}/Template.h +30 -5
  165. data/src/cxx_supportlib/SystemTools/ContainerHelpers.h +88 -0
  166. data/src/cxx_supportlib/{Utils → SystemTools}/ProcessMetricsCollector.h +15 -12
  167. data/src/cxx_supportlib/{Utils → SystemTools}/SystemMetricsCollector.h +3 -3
  168. data/src/cxx_supportlib/{Utils → SystemTools}/SystemTime.cpp +1 -1
  169. data/src/cxx_supportlib/{Utils → SystemTools}/SystemTime.h +0 -0
  170. data/src/cxx_supportlib/SystemTools/UserDatabase.h +1 -1
  171. data/src/cxx_supportlib/Utils/CachedFileStat.hpp +3 -3
  172. data/src/cxx_supportlib/Utils/Curl.h +2 -2
  173. data/src/cxx_supportlib/Utils/FileChangeChecker.h +2 -2
  174. data/src/cxx_supportlib/Utils/MessagePassing.h +1 -1
  175. data/src/cxx_supportlib/Utils/SpeedMeter.h +2 -2
  176. data/src/cxx_supportlib/Utils/Timer.h +2 -2
  177. data/src/cxx_supportlib/Utils/VariantMap.h +3 -3
  178. data/src/cxx_supportlib/Utils.cpp +2 -2
  179. data/src/cxx_supportlib/WatchdogLauncher.h +3 -3
  180. data/src/cxx_supportlib/WebSocketCommandReverseServer.h +1 -1
  181. data/src/cxx_supportlib/WrapperRegistry/CBindings.cpp +85 -0
  182. data/src/cxx_supportlib/{Utils/MemoryBarrier.h → WrapperRegistry/CBindings.h} +30 -27
  183. data/src/cxx_supportlib/WrapperRegistry/Entry.h +112 -0
  184. data/src/cxx_supportlib/WrapperRegistry/README.md +37 -0
  185. data/src/cxx_supportlib/WrapperRegistry/Registry.h +309 -0
  186. data/src/cxx_supportlib/vendor-modified/psg_sysqueue.h +3 -0
  187. data/src/helper-scripts/download_binaries/extconf.rb +6 -2
  188. data/src/nginx_module/ConfigGeneral/AutoGeneratedDefinitions.c +32 -0
  189. data/src/nginx_module/ConfigGeneral/AutoGeneratedManifestDefaultsInitialization.c +12 -0
  190. data/src/nginx_module/ConfigGeneral/AutoGeneratedSetterFuncs.c +36 -0
  191. data/src/nginx_module/Configuration.c +23 -3
  192. data/src/nginx_module/ContentHandler.c +331 -32
  193. data/src/nginx_module/ContentHandler.h +8 -3
  194. data/src/nginx_module/LocationConfig/AutoGeneratedCreateFunction.c +10 -0
  195. data/src/nginx_module/LocationConfig/AutoGeneratedManifestGeneration.c +27 -0
  196. data/src/nginx_module/LocationConfig/AutoGeneratedMergeFunction.c +3 -0
  197. data/src/nginx_module/LocationConfig/AutoGeneratedStruct.h +7 -0
  198. data/src/nginx_module/MainConfig/AutoGeneratedCreateFunction.c +11 -0
  199. data/src/nginx_module/MainConfig/AutoGeneratedManifestGeneration.c +23 -0
  200. data/src/nginx_module/MainConfig/AutoGeneratedStruct.h +8 -0
  201. data/src/nginx_module/config +2 -1
  202. data/src/nginx_module/ngx_http_passenger_module.c +9 -3
  203. data/src/nginx_module/ngx_http_passenger_module.h +10 -3
  204. data/src/ruby_supportlib/phusion_passenger/apache2/config_options.rb +19 -0
  205. data/src/ruby_supportlib/phusion_passenger/common_library.rb +19 -16
  206. data/src/ruby_supportlib/phusion_passenger/config/agent_compiler.rb +4 -4
  207. data/src/ruby_supportlib/phusion_passenger/config/download_agent_command.rb +6 -2
  208. data/src/ruby_supportlib/phusion_passenger/config/download_nginx_engine_command.rb +6 -2
  209. data/src/ruby_supportlib/phusion_passenger/config/nginx_engine_compiler.rb +1 -1
  210. data/src/ruby_supportlib/phusion_passenger/message_channel.rb +2 -2
  211. data/src/ruby_supportlib/phusion_passenger/native_support.rb +7 -3
  212. data/src/ruby_supportlib/phusion_passenger/nginx/config_options.rb +29 -0
  213. data/src/ruby_supportlib/phusion_passenger/packaging.rb +20 -19
  214. data/src/ruby_supportlib/phusion_passenger/platform_info/apache.rb +22 -4
  215. data/src/ruby_supportlib/phusion_passenger/platform_info/ruby.rb +33 -13
  216. data/src/ruby_supportlib/phusion_passenger/standalone/app_finder.rb +1 -0
  217. data/src/ruby_supportlib/phusion_passenger/standalone/config_options_list.rb +22 -2
  218. data/src/ruby_supportlib/phusion_passenger/standalone/start_command/builtin_engine.rb +4 -1
  219. data/src/ruby_supportlib/phusion_passenger.rb +7 -5
  220. data/src/schema_printer/SchemaPrinterMain.cpp +2 -0
  221. metadata +40 -89
  222. data/.editorconfig +0 -134
  223. data/CODE_OF_CONDUCT.md +0 -52
  224. data/dev/boost-patches/0001-Patch-boost-thread-so-that-oxt-thread-can-use-it.patch +0 -48
  225. data/dev/boost-patches/0002-Make-boost-thread_interrupted-derive-from-oxt-tracab.patch +0 -33
  226. data/dev/boost-patches/0003-Disable-a-Clang-pragma-to-prevent-warnings-on-OS-X.patch +0 -25
  227. data/dev/ci/README.md +0 -134
  228. data/dev/ci/lib/functions.sh +0 -129
  229. data/dev/ci/lib/set-container-envvars.sh +0 -53
  230. data/dev/ci/lib/setup-container.sh +0 -46
  231. data/dev/ci/run-tests-natively +0 -24
  232. data/dev/ci/run-tests-with-docker +0 -42
  233. data/dev/ci/scripts/debug-console-wrapper.sh +0 -29
  234. data/dev/ci/scripts/docker-entrypoint-stage2.sh +0 -17
  235. data/dev/ci/scripts/docker-entrypoint.sh +0 -17
  236. data/dev/ci/scripts/inituidgid +0 -17
  237. data/dev/ci/scripts/run-tests-natively-stage2.sh +0 -17
  238. data/dev/ci/scripts/setup-host-natively.sh +0 -11
  239. data/dev/ci/setup-host +0 -56
  240. data/dev/ci/tests/apache2/run +0 -6
  241. data/dev/ci/tests/apache2/setup +0 -4
  242. data/dev/ci/tests/binaries/Jenkinsfile +0 -105
  243. data/dev/ci/tests/binaries/build-linux +0 -38
  244. data/dev/ci/tests/binaries/build-macos +0 -40
  245. data/dev/ci/tests/binaries/prepare-macos +0 -38
  246. data/dev/ci/tests/binaries/test-linux +0 -45
  247. data/dev/ci/tests/binaries/test-macos +0 -38
  248. data/dev/ci/tests/cxx/run +0 -9
  249. data/dev/ci/tests/cxx/setup +0 -4
  250. data/dev/ci/tests/debian/Jenkinsfile +0 -89
  251. data/dev/ci/tests/debian/run +0 -60
  252. data/dev/ci/tests/nginx/run +0 -5
  253. data/dev/ci/tests/nginx/setup +0 -4
  254. data/dev/ci/tests/nginx-dynamic/run +0 -20
  255. data/dev/ci/tests/nginx-dynamic/setup +0 -4
  256. data/dev/ci/tests/nodejs/run +0 -4
  257. data/dev/ci/tests/nodejs/setup +0 -4
  258. data/dev/ci/tests/rpm/Jenkinsfile +0 -68
  259. data/dev/ci/tests/rpm/run +0 -63
  260. data/dev/ci/tests/ruby/run +0 -4
  261. data/dev/ci/tests/ruby/setup +0 -4
  262. data/dev/ci/tests/source-packaging/run +0 -4
  263. data/dev/ci/tests/source-packaging/setup +0 -4
  264. data/dev/ci/tests/standalone/run +0 -4
  265. data/dev/ci/tests/standalone/setup +0 -4
  266. data/dev/configkit-schemas/index.json +0 -1748
  267. data/dev/configkit-schemas/update_schema_inline_comments.rb +0 -118
  268. data/dev/rack.test/config.ru +0 -5
  269. data/dev/rack.test/public/asset.txt +0 -1
  270. data/dev/vagrant/apache_default_site.conf +0 -35
  271. data/dev/vagrant/apache_passenger.conf +0 -5
  272. data/dev/vagrant/apache_passenger.load +0 -1
  273. data/dev/vagrant/apache_ports.conf +0 -24
  274. data/dev/vagrant/apache_rack_test.conf +0 -9
  275. data/dev/vagrant/bashrc +0 -23
  276. data/dev/vagrant/nginx.conf +0 -39
  277. data/dev/vagrant/nginx_rakefile +0 -33
  278. data/dev/vagrant/nginx_start +0 -32
  279. data/dev/vagrant/provision.sh +0 -117
  280. data/dev/vagrant/sudoers.conf +0 -5
  281. data/resources/templates/error_renderer/.editorconfig +0 -19
  282. data/src/cxx_supportlib/AppTypes.cpp +0 -109
  283. data/src/cxx_supportlib/vendor-modified/SmallVector.h +0 -653
data/CODE_OF_CONDUCT.md DELETED
@@ -1,52 +0,0 @@
1
- # Contributor Covenant Code of Conduct
2
-
3
- ## Our Pledge
4
-
5
- In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
6
-
7
- ## Our Standards
8
-
9
- Examples of behavior that contributes to creating a positive environment include:
10
-
11
- * Using welcoming and inclusive language
12
- * Being respectful of differing viewpoints and experiences
13
- * Gracefully accepting constructive criticism
14
- * Focusing on what is best for the community
15
- * Showing empathy towards other community members
16
-
17
- Examples of unacceptable behavior by participants include:
18
-
19
- * The use of sexualized language or imagery and unwelcome sexual attention or advances
20
- * Trolling, insulting/derogatory comments, and personal or political attacks
21
- * Public or private harassment
22
- * Publishing others' private information, such as a physical or electronic address, without explicit permission
23
- * Other conduct which could reasonably be considered inappropriate in a professional setting
24
-
25
- ## Our Responsibilities
26
-
27
- Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28
-
29
- Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30
-
31
- ## Scope
32
-
33
- This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34
-
35
- ## Enforcement
36
-
37
- Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at Phusion Passenger:
38
-
39
- [FloorD](https://github.com/floord) (she/her), floor@phusion.nl, English / Dutch / German
40
-
41
- [OnixGH](https://github.com/OnixGH) (he/his), daniel@phusion.nl, English / Dutch
42
-
43
- The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
44
-
45
- Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
46
-
47
- ## Attribution
48
-
49
- This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
50
-
51
- [homepage]: http://contributor-covenant.org
52
- [version]: http://contributor-covenant.org/version/1/4/
@@ -1,48 +0,0 @@
1
- From 6b92660c98818a3f9630492cf8c79b8c610b3cef Mon Sep 17 00:00:00 2001
2
- From: "Hongli Lai (Phusion)" <hongli@phusion.nl>
3
- Date: Mon, 15 Feb 2016 12:21:52 +0100
4
- Subject: [PATCH] Patch boost::thread so that oxt::thread can use it
5
-
6
- ---
7
- src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp | 4 ++--
8
- src/cxx_supportlib/vendor-modified/boost/thread/once.hpp | 2 +-
9
- 2 files changed, 3 insertions(+), 3 deletions(-)
10
-
11
- diff --git a/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp b/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp
12
- index 9e7e8b8f5..fa6edc2b5 100644
13
- --- a/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp
14
- +++ b/src/cxx_supportlib/vendor-modified/boost/thread/detail/thread.hpp
15
- @@ -162,7 +162,7 @@ namespace boost
16
- typedef thread_attributes attributes;
17
-
18
- BOOST_THREAD_MOVABLE_ONLY(thread)
19
- - private:
20
- + protected:
21
-
22
- struct dummy;
23
-
24
- @@ -170,7 +170,7 @@ namespace boost
25
-
26
- detail::thread_data_ptr thread_info;
27
-
28
- - private:
29
- + protected:
30
- bool start_thread_noexcept();
31
- bool start_thread_noexcept(const attributes& attr);
32
- void start_thread()
33
- diff --git a/src/cxx_supportlib/vendor-modified/boost/thread/once.hpp b/src/cxx_supportlib/vendor-modified/boost/thread/once.hpp
34
- index 9fcfb5333..9a3e9e55d 100644
35
- --- a/src/cxx_supportlib/vendor-modified/boost/thread/once.hpp
36
- +++ b/src/cxx_supportlib/vendor-modified/boost/thread/once.hpp
37
- @@ -32,7 +32,7 @@ namespace boost
38
- // template<class Callable, class ...Args> void
39
- // call_once(once_flag& flag, Callable&& func, Args&&... args);
40
- template<typename Function>
41
- -inline void call_once(Function func,once_flag& flag)
42
- +inline void call_once(Function func,boost::once_flag& flag)
43
- //inline void call_once(void (*func)(),once_flag& flag)
44
- {
45
- call_once(flag,func);
46
- --
47
- 2.13.0
48
-
@@ -1,33 +0,0 @@
1
- From 581af47e251b34f0ae410c29758884c1f033610e Mon Sep 17 00:00:00 2001
2
- From: "Hongli Lai (Phusion)" <hongli@phusion.nl>
3
- Date: Mon, 15 Feb 2016 12:22:44 +0100
4
- Subject: [PATCH] Make boost::thread_interrupted derive from
5
- oxt::tracable_exception
6
-
7
- ---
8
- src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp | 2 ++
9
- 1 file changed, 2 insertions(+)
10
-
11
- diff --git a/src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp b/src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp
12
- index d97465b75..3f780bfb1 100644
13
- --- a/src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp
14
- +++ b/src/cxx_supportlib/vendor-modified/boost/thread/exceptions.hpp
15
- @@ -21,6 +21,7 @@
16
- #include <stdexcept>
17
- #include <boost/system/system_error.hpp>
18
- #include <boost/system/error_code.hpp>
19
- +#include <oxt/tracable_exception.hpp>
20
-
21
-
22
- #include <boost/config/abi_prefix.hpp>
23
- @@ -30,6 +31,7 @@ namespace boost
24
-
25
- #if defined BOOST_THREAD_PROVIDES_INTERRUPTIONS
26
- class BOOST_SYMBOL_VISIBLE thread_interrupted
27
- + : public oxt::tracable_exception
28
- {};
29
- #endif
30
-
31
- --
32
- 2.13.0
33
-
@@ -1,25 +0,0 @@
1
- From 4503df46a907a46a37238bbff04f887c65c7f376 Mon Sep 17 00:00:00 2001
2
- From: "Hongli Lai (Phusion)" <hongli@phusion.nl>
3
- Date: Mon, 15 Feb 2016 12:38:22 +0100
4
- Subject: [PATCH] Disable a Clang pragma to prevent warnings on OS X
5
-
6
- ---
7
- src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp | 2 +-
8
- 1 file changed, 1 insertion(+), 1 deletion(-)
9
-
10
- diff --git a/src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp b/src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp
11
- index 05ac71a68..5e63db629 100644
12
- --- a/src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp
13
- +++ b/src/cxx_supportlib/vendor-modified/boost/regex/v4/instances.hpp
14
- @@ -121,7 +121,7 @@ template class BOOST_REGEX_TEMPLATE_DECL ::boost::BOOST_REGEX_DETAIL_NS::perl_ma
15
-
16
- #ifdef __clang__
17
- #pragma clang diagnostic push
18
- -#pragma clang diagnostic ignored "-Wkeyword-macro"
19
- +//#pragma clang diagnostic ignored "-Wkeyword-macro"
20
- #endif
21
-
22
- # ifndef BOOST_REGEX_INSTANTIATE
23
- --
24
- 2.13.0
25
-
data/dev/ci/README.md DELETED
@@ -1,134 +0,0 @@
1
- # Continuous integration test suite
2
-
3
- This directory contains scripts that invoke the Passenger test suite. These scripts are invoked from the Passenger continuous integration environment, based on Jenkins.
4
-
5
- The following diagrams explain how the different files fit together.
6
-
7
- ## Flow on Linux
8
-
9
- ~~~
10
- Invoke: dev/ci/setup-host
11
- | |
12
- | +-- Load: dev/ci/scripts/setup-host
13
- | |
14
- | +-- Relax file permissions (if in Jenkins)
15
- | |
16
- | +-- Create cache directories
17
- | |
18
- | +-- Create buildout directory
19
- |
20
- Invoke: dev/ci/run-tests-with-docker <test name>
21
- |
22
- +-- Exec: Docker container
23
- Entrypoint: dev/ci/scripts/docker-entrypoint.sh
24
- |
25
- +-- Exec: dev/ci/scripts/debug-console-wrapper.sh dev/ci/scripts/docker-entrypoint-stage2.sh
26
- |
27
- +-- Invoke: dev/ci/scripts/docker-entrypoint-stage2.sh
28
- | |
29
- | +-- Load: dev/ci/lib/setup-container.sh <test name>
30
- | | |
31
- | | +-- Create test/config.json
32
- | | |
33
- | | +-- Relax home permission
34
- | | |
35
- | | +-- Remove previous build products
36
- | | |
37
- | | +-- Load: dev/ci/lib/set-container-envvars.sh
38
- | | | |
39
- | | | +-- Set RVM version and various envvars
40
- | | |
41
- | | +-- Load: dev/ci/tests/<test name>/setup
42
- | |
43
- | +-- Load: dev/ci/tests/<test name>/run
44
- |
45
- +-- (if docker-entrypoint-stage2.sh exited with an error)
46
- | Populate buildout/testlogs
47
- |
48
- +-- (if docker-entrypoint-stage2.sh exited with an error,
49
- | and DEBUG_CONSOLE is set to 0)
50
- | Print error message and exit
51
- |
52
- +-- (if docker-entrypoint-stage2.sh exited with an error,
53
- and DEBUG_CONSOLE is set to 1)
54
- |
55
- +-- Load: dev/ci/lib/set-container-envvars.sh
56
- | |
57
- | +-- Set RVM version and various envvars
58
- |
59
- +-- Invoke: bash
60
- ~~~
61
-
62
- ## Flow on macOS
63
-
64
- ~~~
65
- Invoke: dev/ci/setup-host <test name>
66
- | |
67
- | +-- Relax file permissions (if in Jenkins)
68
- | |
69
- | +-- Create cache directories
70
- | |
71
- | +-- Create buildout directory
72
- | |
73
- | +-- Exec: dev/ci/scripts/debug-console-wrapper.sh dev/ci/scripts/setup-host-natively.sh <test name>
74
- | |
75
- | +-- Invoke: dev/ci/scripts/setup-host-natively.sh
76
- | | |
77
- | | +-- Load: dev/ci/lib/setup-container.sh
78
- | | |
79
- | | +-- Create test/config.json
80
- | | |
81
- | | +-- Relax home permission
82
- | | |
83
- | | +-- Remove previous build products
84
- | | |
85
- | | +-- Load: dev/ci/lib/set-container-envvars.sh
86
- | | | |
87
- | | | +-- Set RVM version and various envvars
88
- | | |
89
- | | +-- Load: dev/ci/tests/<test name>/setup
90
- | |
91
- | +-- (if setup-host-natively.sh exited with an error)
92
- | | Populate buildout/testlogs
93
- | |
94
- | +-- (if setup-host-natively.sh exited with an error,
95
- | | and DEBUG_CONSOLE is set to 0)
96
- | | Print error message and exit
97
- | |
98
- | +-- (if setup-host-natively.sh exited with an error,
99
- | and DEBUG_CONSOLE is set to 1)
100
- | |
101
- | +-- Load: dev/ci/lib/set-container-envvars.sh
102
- | | |
103
- | | +-- Set RVM version and various envvars
104
- | |
105
- | +-- Invoke: bash
106
- |
107
- Invoke: dev/ci/run-tests-natively <test name>
108
- |
109
- +-- Exec: dev/ci/scripts/debug-console-wrapper.sh dev/ci/scripts/run-tests-natively-stage2.sh <test name>
110
- |
111
- +-- Invoke: dev/ci/scripts/run-tests-natively-stage2.sh
112
- | |
113
- | +-- Load: dev/lib/set-container-envvars.sh
114
- | | |
115
- | | +-- Set RVM version and various envvars
116
- | |
117
- | +-- Load: dev/ci/tests/<test name>/run
118
- |
119
- +-- (if run-tests-natively-stage2.sh exited with an error)
120
- | Populate buildout/testlogs
121
- |
122
- +-- (if run-tests-natively-stage2.sh exited with an error,
123
- | and DEBUG_CONSOLE is set to 0)
124
- | Print error message and exit
125
- |
126
- +-- (if run-tests-natively-stage2.sh exited with an error,
127
- and DEBUG_CONSOLE is set to 1)
128
- |
129
- +-- Load: dev/ci/lib/set-container-envvars.sh
130
- | |
131
- | +-- Set RVM version and various envvars
132
- |
133
- +-- Invoke: bash
134
- ~~~
@@ -1,129 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -e
3
-
4
- RESET=$(echo -e "\033[0m")
5
- BOLD=$(echo -e "\033[1m")
6
- YELLOW=$(echo -e "\033[33m")
7
- BLUE_BG=$(echo -e "\033[44m")
8
-
9
- function header()
10
- {
11
- local title="$1"
12
- echo "${BLUE_BG}${YELLOW}${BOLD}${title}${RESET}"
13
- echo "------------------------------------------"
14
- }
15
-
16
- function header2()
17
- {
18
- local title="$1"
19
- echo "### ${BOLD}${title}${RESET}"
20
- echo
21
- }
22
-
23
- function run()
24
- {
25
- echo "+ $*"
26
- "$@"
27
- }
28
-
29
- function run_exec()
30
- {
31
- echo "+ exec $*"
32
- exec "$@"
33
- }
34
-
35
- function retry_run()
36
- {
37
- local reset='\x1B[0m'
38
- local red='\x1B[31m'
39
- local yellow='\x1B[33m'
40
-
41
- local max_tries="$1"
42
- local number=2
43
- shift
44
-
45
- echo "+ $*"
46
- while true; do
47
- if "$@"; then
48
- return 0
49
- elif [[ $number -le $max_tries ]]; then
50
- echo -e "${yellow}The command \"$*\" failed. Retrying, $number of $max_tries:${reset}"
51
- (( number++ ))
52
- else
53
- echo -e "${red}The command \"$*\" failed after $max_tries attempts. Giving up.${reset}"
54
- return 1
55
- fi
56
- done
57
- }
58
-
59
- function autodetect_environment()
60
- {
61
- echo "Environment autodetection results:"
62
- if [[ "$JENKINS_HOME" != "" ]]; then
63
- echo "Running in Jenkins: yes"
64
- export IN_JEKINS=true
65
- export CACHE_DIR="$JENKINS_HOME/cache/$JOB_NAME/executor-$EXECUTOR_NUMBER"
66
- else
67
- echo "Running in Jenkins: no"
68
- export IN_JENKINS=false
69
- export CACHE_DIR="$PASSENGER_ROOT/.ci_cache"
70
- fi
71
- if [[ -e /usr/bin/sw_vers ]]; then
72
- echo "Operating system: macOS"
73
- export OS=macos
74
- else
75
- echo "Operating system: Linux"
76
- export OS=linux
77
- fi
78
- echo "Cache directory: $CACHE_DIR"
79
- }
80
-
81
- function sanity_check_environment()
82
- {
83
- if $IN_JENKINS; then
84
- if [[ "$JOB_NAME" = "" ]]; then
85
- echo "ERROR: Jenkins environment detected, but JOB_NAME environment variable not set." >&2
86
- return 1
87
- fi
88
- if [[ "$EXECUTOR_NUMBER" = "" ]]; then
89
- echo "ERROR: Jenkins environment detected, but EXECUTOR_NUMBER environment variable not set." >&2
90
- return 1
91
- fi
92
- fi
93
- }
94
-
95
- # The following is necessary to make the C++ tests work.
96
- # They invoke Ruby scripts which require gems installed
97
- # by Bundler, but these scripts are not invoked with
98
- # Bundler, so they can only find these gems through GEM_PATH.
99
- function add_bundler_path_to_gem_path()
100
- {
101
- local bundle_path
102
-
103
- if bundle_path=$(bundle show rake); then
104
- bundle_path=$(dirname "$bundle_path")
105
- bundle_path=$(dirname "$bundle_path")
106
- echo "Adding $bundle_path to GEM_PATH"
107
- export GEM_PATH="$bundle_path:$GEM_PATH"
108
-
109
- local bundle_bin_path="$bundle_path/bin"
110
- echo "Adding $bundle_bin_path to PATH"
111
- export PATH="$bundle_bin_path:$PATH"
112
- fi
113
- }
114
-
115
- function _cleanup()
116
- {
117
- set +e
118
- local pids
119
- pids=$(jobs -p)
120
- if [[ "$pids" != "" ]]; then
121
- # shellcheck disable=SC2086
122
- kill $pids 2>/dev/null
123
- fi
124
- if [[ $(type -t cleanup) == function ]]; then
125
- cleanup
126
- fi
127
- }
128
-
129
- trap _cleanup EXIT
@@ -1,53 +0,0 @@
1
- #!/usr/bin/env bash
2
- # Do not `set -e` here because debug-console-wrapper.sh
3
- # relies on this fact.
4
-
5
- export DEVDEPS_DEFAULT=no
6
- # shellcheck disable=SC2153
7
- export DEPS_TARGET="$CACHE_DIR/bundle"
8
- export USE_CCACHE=true
9
- export COMPILE_CONCURRENCY=${COMPILE_CONCURRENCY:-2}
10
- export YARN_ARGS="--cache-folder='$CACHE_DIR/yarn'"
11
- export CCACHE_DIR="$CACHE_DIR/ccache"
12
- export CCACHE_COMPRESS=1
13
- export CCACHE_COMPRESSLEVEL=3
14
- export CCACHE_BASEDIR="$PASSENGER_ROOT"
15
- export CCACHE_SLOPPINESS=time_macros
16
- export CCACHE_LOGFILE="$(pwd)/buildout/testlogs/ccache.log"
17
- # We want Bundler invocations to be explicit. For example,
18
- # when running 'rake test:install_deps', we do not want
19
- # to invoke Bundler there because the goal might be to
20
- # install the Rake version as specified in the Gemfile,
21
- # which we may not have yet.
22
- export NOEXEC_DISABLE=1
23
-
24
- if [[ "$EXECUTOR_NUMBER" != "" ]]; then
25
- (( TEST_PORT_BASE=64000+EXECUTOR_NUMBER*10 ))
26
- export TEST_PORT_BASE
27
- fi
28
-
29
- if [[ "$OS" = macos ]]; then
30
- # Ensure that Homebrew tools can be found
31
- export PATH=$PATH:/usr/local/bin
32
- else
33
- export LC_CTYPE=C.UTF-8
34
- fi
35
-
36
- if [[ -f ~/.rvm/scripts/rvm ]]; then
37
- # shellcheck source=/dev/null
38
- source ~/.rvm/scripts/rvm
39
- else
40
- # shellcheck source=/dev/null
41
- source /usr/local/rvm/scripts/rvm
42
- fi
43
-
44
- if [[ "$TEST_RUBY_VERSION" != "" ]]; then
45
- header2 "Using Ruby version $TEST_RUBY_VERSION"
46
- run rvm use "$TEST_RUBY_VERSION"
47
- echo
48
- fi
49
-
50
- # RVM's cd override causes problems (probably thanks to bash
51
- # error handling being weird and quirky:
52
- # https://news.ycombinator.com/item?id=14321213)
53
- unset cd
@@ -1,46 +0,0 @@
1
- #!/usr/bin/env bash
2
-
3
- if ! grep -q passenger.test /etc/hosts; then
4
- header2 "Updating /etc/hosts"
5
- sudo sh -c "cat >> /etc/hosts" <<EOF
6
- 127.0.0.1 passenger.test
7
- 127.0.0.1 mycook.passenger.test
8
- 127.0.0.1 zsfa.passenger.test
9
- 127.0.0.1 norails.passenger.test
10
- 127.0.0.1 1.passenger.test 2.passenger.test 3.passenger.test
11
- 127.0.0.1 4.passenger.test 5.passenger.test 6.passenger.test
12
- 127.0.0.1 7.passenger.test 8.passenger.test 9.passenger.test
13
- EOF
14
- echo
15
- fi
16
-
17
- header2 "Creating test/config.json"
18
- if [[ "$OS" = linux ]]; then
19
- run cp test/config.json.travis test/config.json
20
- else
21
- sed -e "s/_USER_/$USER/" test/config.json.travis-osx > test/config.json
22
- fi
23
- echo "+ Done."
24
- echo
25
-
26
- # Relax permissions on home directory so that the application root
27
- # permission checks pass.
28
- header2 "Relaxing home permission"
29
- run chmod g+x,o+x "$HOME"
30
- echo
31
-
32
- header2 "Removing previous build products"
33
- run rm -rf buildout/*
34
- run mkdir buildout/testlogs
35
- run rm -f test/test.log
36
- run rm -rf /tmp/psg-test-* /tmp/passenger-error-*.html
37
- echo
38
-
39
- # shellcheck source=../lib/set-container-envvars.sh
40
- source "$PASSENGER_ROOT/dev/ci/lib/set-container-envvars.sh"
41
-
42
- header "Running test-specific preparations"
43
- # shellcheck source=/dev/null
44
- source "$PASSENGER_ROOT/dev/ci/tests/$1/setup"
45
- echo '+ Done.'
46
- echo
@@ -1,24 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -eo pipefail
3
-
4
- SELFDIR=$(dirname "$0")
5
- SELFDIR=$(cd "$SELFDIR" && pwd)
6
- PASSENGER_ROOT=$(cd "$SELFDIR/../.." && pwd)
7
- # shellcheck source=lib/functions.sh
8
- source "$SELFDIR/lib/functions.sh"
9
- cd "$PASSENGER_ROOT"
10
-
11
- autodetect_environment
12
- sanity_check_environment
13
- echo
14
-
15
- if [[ "$OS" != macos ]]; then
16
- echo "ERROR: this script can only be run on macOS." >&2
17
- exit 1
18
- fi
19
-
20
- security unlock-keychain -p `cat ~/.password` ~/Library/Keychains/login.keychain
21
-
22
- export CI_COMMAND="./dev/ci/run-tests-natively $*"
23
- exec "$PASSENGER_ROOT/dev/ci/scripts/debug-console-wrapper.sh" \
24
- "$PASSENGER_ROOT/dev/ci/scripts/run-tests-natively-stage2.sh" "$@"
@@ -1,42 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -eo pipefail
3
-
4
- SELFDIR=$(dirname "$0")
5
- SELFDIR=$(cd "$SELFDIR" && pwd)
6
- PASSENGER_ROOT=$(cd "$SELFDIR/../.." && pwd)
7
- # shellcheck source=lib/functions.sh
8
- source "$SELFDIR/lib/functions.sh"
9
- cd "$PASSENGER_ROOT"
10
-
11
- autodetect_environment
12
- sanity_check_environment
13
- echo
14
-
15
- if [[ "$OS" != linux ]]; then
16
- echo "ERROR: this script can only be run on Linux." >&2
17
- exit 1
18
- fi
19
-
20
- if tty -s; then
21
- TTY_ARGS='-t -i'
22
- else
23
- TTY_ARGS=
24
- fi
25
-
26
- run_exec docker run --rm $TTY_ARGS \
27
- -v "$PASSENGER_ROOT:/passenger" \
28
- -v "$CACHE_DIR:/passenger/.ci_cache" \
29
- -e "APP_UID=$(id -u)" \
30
- -e "APP_GID=$(id -g)" \
31
- -e "DEBUG_CONSOLE=$DEBUG_CONSOLE" \
32
- -e "TEST_RUBY_VERSION=$TEST_RUBY_VERSION" \
33
- -e "COMPILE_CONCURRENCY=$COMPILE_CONCURRENCY" \
34
- -e "SUDO=$SUDO" \
35
- phusion/passenger-ci-docker-env:1.0.1 \
36
- /sbin/my_init --skip-runit --skip-startup-files --quiet -- \
37
- /passenger/dev/ci/scripts/inituidgid \
38
- /sbin/setuser app \
39
- /bin/bash -lc 'cd /passenger && exec "$@"' \
40
- ./dev/ci/scripts/docker-entrypoint.sh \
41
- ./dev/ci/scripts/docker-entrypoint.sh \
42
- "$@"
@@ -1,29 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -eo pipefail
3
-
4
- SELFDIR=$(dirname "$0")
5
- SELFDIR=$(cd "$SELFDIR" && pwd)
6
- PASSENGER_ROOT=$(cd "$SELFDIR/../../.." && pwd)
7
- # shellcheck source=lib/functions.sh
8
- source "$SELFDIR/../lib/functions.sh"
9
-
10
- if ! "$@"; then
11
- echo
12
- echo "-----------------------------"
13
- echo
14
- echo "*** An error occurred ***"
15
-
16
- if [[ "$DEBUG_CONSOLE" == 1 ]]; then
17
- echo
18
- echo "*** DEBUG_CONSOLE set to 1, so launching a debugging console..."
19
- echo
20
- # shellcheck source=../lib/set-container-envvars.sh
21
- set +e
22
- source "$PASSENGER_ROOT/dev/ci/lib/set-container-envvars.sh"
23
- header2 "Launching bash"
24
- bash -l
25
- else
26
- echo "If you want to debug this, run '$CI_COMMAND' with the environment variable DEBUG_CONSOLE=1."
27
- fi
28
- exit 1
29
- fi
@@ -1,17 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -eo pipefail
3
-
4
- SELFDIR=/passenger/dev/ci/scripts
5
- PASSENGER_ROOT=/passenger
6
- # shellcheck source=../lib/functions.sh
7
- source "$SELFDIR/../lib/functions.sh"
8
-
9
- # shellcheck source=../lib/setup-container.sh
10
- source "$PASSENGER_ROOT/dev/ci/lib/setup-container.sh"
11
- add_bundler_path_to_gem_path
12
- echo
13
- echo
14
-
15
- header "Running test suite: $1"
16
- # shellcheck source=/dev/null
17
- source "$PASSENGER_ROOT/dev/ci/tests/$1/run"
@@ -1,17 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -eo pipefail
3
-
4
- SELFDIR=/passenger/dev/ci/scripts
5
- PASSENGER_ROOT=/passenger
6
- # shellcheck source=../lib/functions.sh
7
- source "$SELFDIR/../lib/functions.sh"
8
- cd "$PASSENGER_ROOT"
9
-
10
- header "Inside Docker container"
11
-
12
- autodetect_environment
13
- echo
14
-
15
- export CI_COMMAND="./dev/ci/run-tests-with-docker $*"
16
- exec "$PASSENGER_ROOT/dev/ci/scripts/debug-console-wrapper.sh" \
17
- "$PASSENGER_ROOT/dev/ci/scripts/docker-entrypoint-stage2.sh" "$@"
@@ -1,17 +0,0 @@
1
- #!/usr/bin/env bash
2
- set -e
3
-
4
- chown -R "$APP_UID:$APP_GID" /home/app
5
- groupmod -g "$APP_GID" app
6
- usermod -u "$APP_UID" -g "$APP_GID" app
7
-
8
- # There's something strange with either Docker or the kernel, so that
9
- # the 'app' user cannot access its home directory even after a proper
10
- # chown/chmod. We work around it like this.
11
- mv /home/app /home/app2
12
- cp -dpR /home/app2 /home/app
13
- rm -rf /home/app2
14
-
15
- if [[ $# -gt 0 ]]; then
16
- exec "$@"
17
- fi