Вопрос или проблема
После обновления GitLab-ee, Docker, Omnibus с 17.2.9 до 17.3.6 и, наконец, до 17.5.1, когда я открываю файл в своем репозитории в GitLab и нажимаю на Правка -> Открыть в Web IDE (vscode_web_ide
), я попадаю на страницу ошибки 500.
Такое поведение не наблюдалось в 17.2.9 или предыдущих версиях, которые у меня были установлены. Я опубликовал эту проблему как вопрос в GitLab, но не получаю ответа.
Как мне это исправить?
Логи:
==> /var/log/gitlab/gitlab-exporter/current <==
2024-10-29_05:50:26.69914 ::1 - - [29/Oct/2024:05:50:26 UTC] "GET /sidekiq HTTP/1.1" 200 579
2024-10-29_05:50:26.69917 - -> /sidekiq
==> /var/log/gitlab/gitlab-rails/production.log <==
OpenSSL::Cipher::CipherError ():
encryptor (3.0.0) lib/encryptor.rb:98:in final' encryptor (3.0.0) lib/encryptor.rb:98:in crypt'
encryptor (3.0.0) lib/encryptor.rb:49:in decrypt' vendor/gems/attr_encrypted/lib/attr_encrypted.rb:244:in attr_decrypt'
vendor/gems/attr_encrypted/lib/attr_encrypted.rb:333:in attr_decrypt' vendor/gems/attr_encrypted/lib/attr_encrypted.rb:163:in block (2 levels) in attr_encrypted'
activemodel (7.0.8.4) lib/active_model/validator.rb:150:in block in validate' activemodel (7.0.8.4) lib/active_model/validator.rb:149:in each'
activemodel (7.0.8.4) lib/active_model/validator.rb:149:in validate' activesupport (7.0.8.4) lib/active_support/callbacks.rb:423:in block in make_lambda'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:199:in block (2 levels) in halting' activesupport (7.0.8.4) lib/active_support/callbacks.rb:687:in block (2 levels) in default_terminator'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:686:in catch' activesupport (7.0.8.4) lib/active_support/callbacks.rb:686:in block in default_terminator'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:200:in block in halting' activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in block in invoke_before'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in each' activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in invoke_before'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:106:in run_callbacks' activesupport (7.0.8.4) lib/active_support/callbacks.rb:929:in _run_validate_callbacks'
activemodel (7.0.8.4) lib/active_model/validations.rb:406:in run_validations!' activemodel (7.0.8.4) lib/active_model/validations/callbacks.rb:115:in block in run_validations!'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:107:in run_callbacks' activesupport (7.0.8.4) lib/active_support/callbacks.rb:929:in _run_validation_callbacks'
activemodel (7.0.8.4) lib/active_model/validations/callbacks.rb:115:in run_validations!' activemodel (7.0.8.4) lib/active_model/validations.rb:337:in valid?'
activerecord (7.0.8.4) lib/active_record/validations.rb:68:in valid?' activerecord (7.0.8.4) lib/active_record/validations.rb:84:in perform_validations'
activerecord (7.0.8.4) lib/active_record/validations.rb:53:in save!' activerecord (7.0.8.4) lib/active_record/transactions.rb:302:in block in save!'
activerecord (7.0.8.4) lib/active_record/transactions.rb:354:in block in with_transaction_returning_status' activerecord (7.0.8.4) lib/active_record/connection_adapters/abstract/database_statements.rb:314:in transaction'
lib/gitlab/database/load_balancing/connection_proxy.rb:127:in public_send' lib/gitlab/database/load_balancing/connection_proxy.rb:127:in block in write_using_load_balancer'
lib/gitlab/database/load_balancing/load_balancer.rb:141:in block in read_write' lib/gitlab/database/load_balancing/load_balancer.rb:228:in retry_with_backoff'
lib/gitlab/database/load_balancing/load_balancer.rb:130:in read_write' lib/gitlab/database/load_balancing/connection_proxy.rb:126:in write_using_load_balancer'
lib/gitlab/database/load_balancing/connection_proxy.rb:78:in transaction' activerecord (7.0.8.4) lib/active_record/transactions.rb:350:in with_transaction_returning_status'
activerecord (7.0.8.4) lib/active_record/transactions.rb:302:in save!' activerecord (7.0.8.4) lib/active_record/suppressor.rb:54:in save!'
activerecord (7.0.8.4) lib/active_record/persistence.rb:782:in block in update!' activerecord (7.0.8.4) lib/active_record/transactions.rb:354:in block in with_transaction_returning_status'
activerecord (7.0.8.4) lib/active_record/connection_adapters/abstract/database_statements.rb:314:in transaction' lib/gitlab/database/load_balancing/connection_proxy.rb:127:in public_send'
lib/gitlab/database/load_balancing/connection_proxy.rb:127:in block in write_using_load_balancer' lib/gitlab/database/load_balancing/load_balancer.rb:141:in block in read_write'
lib/gitlab/database/load_balancing/load_balancer.rb:228:in retry_with_backoff' lib/gitlab/database/load_balancing/load_balancer.rb:130:in read_write'
lib/gitlab/database/load_balancing/connection_proxy.rb:126:in write_using_load_balancer' lib/gitlab/database/load_balancing/connection_proxy.rb:78:in transaction'
activerecord (7.0.8.4) lib/active_record/transactions.rb:350:in with_transaction_returning_status' activerecord (7.0.8.4) lib/active_record/persistence.rb:780:in update!'
lib/web_ide/default_oauth_application.rb:51:in block in ensure_oauth_application!' app/models/concerns/cross_database_modification.rb:91:in block in transaction'
activerecord (7.0.8.4) lib/active_record/connection_adapters/abstract/transaction.rb:319:in block in within_new_transaction' activesupport (7.0.8.4) lib/active_support/concurrency/load_interlock_aware_monitor.rb:25:in handle_interrupt'
activesupport (7.0.8.4) lib/active_support/concurrency/load_interlock_aware_monitor.rb:25:in block in synchronize' activesupport (7.0.8.4) lib/active_support/concurrency/load_interlock_aware_monitor.rb:21:in handle_interrupt'
activesupport (7.0.8.4) lib/active_support/concurrency/load_interlock_aware_monitor.rb:21:in synchronize' activerecord (7.0.8.4) lib/active_record/connection_adapters/abstract/transaction.rb:317:in within_new_transaction'
activerecord (7.0.8.4) lib/active_record/connection_adapters/abstract/database_statements.rb:316:in transaction' lib/gitlab/database/load_balancing/connection_proxy.rb:127:in public_send'
lib/gitlab/database/load_balancing/connection_proxy.rb:127:in block in write_using_load_balancer' lib/gitlab/database/load_balancing/load_balancer.rb:141:in block in read_write'
lib/gitlab/database/load_balancing/load_balancer.rb:228:in retry_with_backoff' lib/gitlab/database/load_balancing/load_balancer.rb:130:in read_write'
lib/gitlab/database/load_balancing/connection_proxy.rb:126:in write_using_load_balancer' lib/gitlab/database/load_balancing/connection_proxy.rb:78:in transaction'
activerecord (7.0.8.4) lib/active_record/transactions.rb:209:in transaction' lib/gitlab/database.rb:383:in block in transaction'
activesupport (7.0.8.4) lib/active_support/notifications.rb:206:in block in instrument' activesupport (7.0.8.4) lib/active_support/notifications/instrumenter.rb:24:in instrument'
activesupport (7.0.8.4) lib/active_support/notifications.rb:206:in instrument' lib/gitlab/database.rb:382:in transaction'
app/models/concerns/cross_database_modification.rb:82:in transaction' activerecord (7.0.8.4) lib/active_record/transactions.rb:290:in transaction'
lib/web_ide/default_oauth_application.rb:39:in ensure_oauth_application!' app/controllers/ide_controller.rb:48:in ensure_web_ide_oauth_application!'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:400:in block in make_lambda' activesupport (7.0.8.4) lib/active_support/callbacks.rb:180:in block (2 levels) in halting_and_conditional'
actionpack (7.0.8.4) lib/abstract_controller/callbacks.rb:34:in block (2 levels) in <module:Callbacks>' activesupport (7.0.8.4) lib/active_support/callbacks.rb:181:in block in halting_and_conditional'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in block in invoke_before' activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in each'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:595:in invoke_before' activesupport (7.0.8.4) lib/active_support/callbacks.rb:116:in block in run_callbacks'
lib/gitlab/ip_address_state.rb:11:in with' ee/app/controllers/ee/application_controller.rb:45:in set_current_ip_address'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks' app/controllers/application_controller.rb:484:in set_current_admin'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks' lib/gitlab/session.rb:11:in with_session'
app/controllers/application_controller.rb:475:in set_session_storage' activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks'
lib/gitlab/i18n.rb:114:in with_locale' lib/gitlab/i18n.rb:120:in with_user_locale'
app/controllers/application_controller.rb:466:in set_locale' activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks'
marginalia (1.11.1) lib/marginalia.rb:109:in record_query_comment' activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks'
app/controllers/application_controller.rb:459:in set_current_context' activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks'
sentry-rails (5.19.0) lib/sentry/rails/controller_transaction.rb:30:in block in sentry_around_action' sentry-ruby (5.19.0) lib/sentry/hub.rb:102:in with_child_span'
sentry-ruby (5.19.0) lib/sentry-ruby.rb:498:in with_child_span' sentry-rails (5.19.0) lib/sentry/rails/controller_transaction.rb:16:in sentry_around_action'
activesupport (7.0.8.4) lib/active_support/callbacks.rb:127:in block in run_callbacks' activesupport (7.0.8.4) lib/active_support/callbacks.rb:138:in run_callbacks'
actionpack (7.0.8.4) lib/abstract_controller/callbacks.rb:233:in process_action' actionpack (7.0.8.4) lib/action_controller/metal/rescue.rb:23:in process_action'
actionpack (7.0.8.4) lib/action_controller/metal/instrumentation.rb:67:in block in process_action' activesupport (7.0.8.4) lib/active_support/notifications.rb:206:in block in instrument'
activesupport (7.0.8.4) lib/active_support/notifications/instrumenter.rb:24:in instrument' activesupport (7.0.8.4) lib/active_support/notifications.rb:206:in instrument'
actionpack (7.0.8.4) lib/action_controller/metal/instrumentation.rb:66:in process_action' actionpack (7.0.8.4) lib/action_controller/metal/params_wrapper.rb:259:in process_action'
activerecord (7.0.8.4) lib/active_record/railties/controller_runtime.rb:27:in process_action' actionpack (7.0.8.4) lib/abstract_controller/base.rb:151:in process'
actionview (7.0.8.4) lib/action_view/rendering.rb:39:in process' actionpack (7.0.8.4) lib/action_controller/metal.rb:188:in dispatch'
actionpack (7.0.8.4) lib/action_controller/metal.rb:249:in block in dispatch' lib/gitlab/middleware/action_controller_static_context.rb:23:in call'
actionpack (7.0.8.4) lib/action_controller/metal.rb:249:in dispatch' actionpack (7.0.8.4) lib/action_dispatch/routing/route_set.rb:49:in dispatch'
actionpack (7.0.8.4) lib/action_dispatch/routing/route_set.rb:32:in serve' actionpack (7.0.8.4) lib/action_dispatch/journey/router.rb:50:in block in serve'
actionpack (7.0.8.4) lib/action_dispatch/journey/router.rb:32:in each' actionpack (7.0.8.4) lib/action_dispatch/journey/router.rb:32:in serve'
actionpack (7.0.8.4) lib/action_dispatch/routing/route_set.rb:852:in call' gitlab-experiment (0.9.1) lib/gitlab/experiment/middleware.rb:19:in call'
flipper (0.26.2) lib/flipper/middleware/memoizer.rb:72:in memoized_call' flipper (0.26.2) lib/flipper/middleware/memoizer.rb:37:in call'
lib/gitlab/metrics/elasticsearch_rack_middleware.rb:16:in call' lib/gitlab/middleware/sidekiq_shard_awareness_validation.rb:20:in block in call'
lib/gitlab/sidekiq_sharding/validator.rb:42:in enabled' lib/gitlab/middleware/sidekiq_shard_awareness_validation.rb:20:in call'
lib/gitlab/middleware/memory_report.rb:13:in call' lib/gitlab/middleware/speedscope.rb:13:in call'
lib/gitlab/database/load_balancing/rack_middleware.rb:23:in call' lib/gitlab/middleware/rails_queue_duration.rb:33:in call'
lib/gitlab/etag_caching/middleware.rb:21:in call' lib/gitlab/metrics/rack_middleware.rb:16:in block in call'
lib/gitlab/metrics/web_transaction.rb:46:in run' lib/gitlab/metrics/rack_middleware.rb:16:in call'
lib/gitlab/middleware/go.rb:21:in call' lib/gitlab/middleware/query_analyzer.rb:11:in block in call'
lib/gitlab/database/query_analyzer.rb:83:in within' lib/gitlab/middleware/query_analyzer.rb:11:in call'
lib/ci/job_token/middleware.rb:11:in call' batch-loader (2.0.5) lib/batch_loader/middleware.rb:11:in call'
rack-attack (6.7.0) lib/rack/attack.rb:103:in call' apollo_upload_server (2.1.6) lib/apollo_upload_server/middleware.rb:19:in call'
lib/gitlab/middleware/multipart.rb:173:in call' rack-attack (6.7.0) lib/rack/attack.rb:127:in call'
warden (1.2.9) lib/warden/manager.rb:36:in block in call' warden (1.2.9) lib/warden/manager.rb:34:in catch'
warden (1.2.9) lib/warden/manager.rb:34:in call' rack-cors (2.0.2) lib/rack/cors.rb:102:in call'
rack (2.2.9) lib/rack/tempfile_reaper.rb:15:in call' rack (2.2.9) lib/rack/etag.rb:27:in call'
rack (2.2.9) lib/rack/conditional_get.rb:27:in call' rack (2.2.9) lib/rack/head.rb:12:in call'
actionpack (7.0.8.4) lib/action_dispatch/http/permissions_policy.rb:38:in call' actionpack (7.0.8.4) lib/action_dispatch/http/content_security_policy.rb:36:in call'
lib/gitlab/middleware/read_only/controller.rb:50:in call' lib/gitlab/middleware/read_only.rb:18:in call'
lib/gitlab/middleware/unauthenticated_session_expiry.rb:18:in call' rack (2.2.9) lib/rack/session/abstract/id.rb:266:in context'
rack (2.2.9) lib/rack/session/abstract/id.rb:260:in call' actionpack (7.0.8.4) lib/action_dispatch/middleware/cookies.rb:704:in call'
lib/gitlab/middleware/strip_cookies.rb:29:in call' lib/gitlab/middleware/same_site_cookies.rb:27:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/callbacks.rb:27:in block in call' activesupport (7.0.8.4) lib/active_support/callbacks.rb:99:in run_callbacks'
actionpack (7.0.8.4) lib/action_dispatch/middleware/callbacks.rb:26:in call' sentry-rails (5.19.0) lib/sentry/rails/rescued_exception_interceptor.rb:12:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/debug_exceptions.rb:28:in call' lib/gitlab/middleware/path_traversal_check.rb:35:in call'
lib/gitlab/middleware/handle_malformed_strings.rb:21:in call' sentry-ruby (5.19.0) lib/sentry/rack/capture_exceptions.rb:30:in block (2 levels) in call'
sentry-ruby (5.19.0) lib/sentry/hub.rb:258:in with_session_tracking' sentry-ruby (5.19.0) lib/sentry-ruby.rb:411:in with_session_tracking'
sentry-ruby (5.19.0) lib/sentry/rack/capture_exceptions.rb:21:in block in call' sentry-ruby (5.19.0) lib/sentry/hub.rb:59:in with_scope'
sentry-ruby (5.19.0) lib/sentry-ruby.rb:391:in with_scope' sentry-ruby (5.19.0) lib/sentry/rack/capture_exceptions.rb:20:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/show_exceptions.rb:29:in call' lib/gitlab/middleware/basic_health_check.rb:25:in call'
lograge (0.11.2) lib/lograge/rails_ext/rack/logger.rb:15:in call_app' railties (7.0.8.4) lib/rails/rack/logger.rb:25:in block in call'
activesupport (7.0.8.4) lib/active_support/tagged_logging.rb:99:in block in tagged' activesupport (7.0.8.4) lib/active_support/tagged_logging.rb:37:in tagged'
activesupport (7.0.8.4) lib/active_support/tagged_logging.rb:99:in tagged' railties (7.0.8.4) lib/rails/rack/logger.rb:25:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/remote_ip.rb:93:in call' lib/gitlab/middleware/handle_ip_spoof_attack_error.rb:25:in call'
lib/gitlab/middleware/request_context.rb:15:in call' lib/gitlab/middleware/webhook_recursion_detection.rb:15:in call'
request_store (1.5.1) lib/request_store/middleware.rb:19:in call' rack (2.2.9) lib/rack/mature_override.rb:24:in call'
rack (2.2.9) lib/rack/runtime.rb:22:in call' rack-timeout (0.7.0) lib/rack/timeout/core.rb:154:in block in call'
rack-timeout (0.7.0) lib/rack/timeout/support/timeout.rb:19:in timeout' rack-timeout (0.7.0) lib/rack/timeout/core.rb:153:in call'
config/initializers/fix_local_cache_middleware.rb:11:in call' lib/gitlab/middleware/compressed_json.rb:44:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/executor.rb:14:in call' lib/gitlab/middleware/rack_multipart_tempfile_factory.rb:19:in call'
rack (2.2.9) lib/rack/sendfile.rb:110:in call' lib/gitlab/middleware/sidekiq_web_static.rb:20:in call'
lib/gitlab/metrics/requests_rack_middleware.rb:79:in call' gitlab-labkit (0.36.1) lib/labkit/middleware/rack.rb:22:in block in call'
gitlab-labkit (0.36.1) lib/labkit/context.rb:35:in with_context' gitlab-labkit (0.36.1) lib/labkit/middleware/rack.rb:21:in call'
actionpack (7.0.8.4) lib/action_dispatch/middleware/request_id.rb:26:in call' actionpack (7.0.8.4) lib/action_dispatch/middleware/host_authorization.rb:131:in call'
railties (7.0.8.4) lib/rails/engine.rb:530:in call' railties (7.0.8.4) lib/rails/railtie.rb:226:in public_send'
railties (7.0.8.4) lib/rails/railtie.rb:226:in method_missing' lib/gitlab/middleware/release_env.rb:13:in call'
rack (2.2.9) lib/rack/urlmap.rb:74:in block in call' rack (2.2.9) lib/rack/urlmap.rb:58:in each'
rack (2.2.9) lib/rack/urlmap.rb:58:in call' puma (6.4.3) lib/puma/configuration.rb:272:in call'
puma (6.4.3) lib/puma/request.rb:100:in block in handle_request' puma (6.4.3) lib/puma/thread_pool.rb:378:in with_force_shutdown'
puma (6.4.3) lib/puma/request.rb:99:in handle_request' puma (6.4.3) lib/puma/server.rb:464:in process_client'
puma (6.4.3) lib/puma/server.rb:245:in block in run' puma (6.4.3) lib/puma/thread_pool.rb:155:in block in spawn_thread'
==> /var/log/gitlab/gitlab-workhorse/current <==
{"backend_id":"rails","content_type":"text/html; charset=utf-8","correlation_id":"01JBBD6MCDVN5E5M60A619DCB9","duration_ms":649,"host":"gitlab.REDACTED.net:8443","level":"info","method":"GET","msg":"access","proto":"HTTP/1.1","referrer":"https://gitlab.REDACTED.net:8443/REDACTED/documentation/-/blob/main/.gitlab-ci.yml?ref_type=heads","remote_addr":"REDACTED_IP:0","remote_ip":"REDACTED_IP","route":"^/-/","route_id":"dash","status":500,"system":"http","time":"2024-10-29T05:50:26Z","ttfb_ms":649,"uri":"/-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml","user_agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0","written_bytes":1624}
==> /var/log/gitlab/nginx/gitlab_access.log <==
REDACTED_IP - - [29/Oct/2024:05:50:26 +0000] "GET /-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml HTTP/2.0" 500 1624 "https://gitlab.REDACTED.net:8443/REDACTED/documentation/-/blob/main/.gitlab-ci.yml" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0" -
==> /var/log/gitlab/gitlab-workhorse/current <==
{"correlation_id":"01JBBD6N1KZTCQV207EN7SJB92","encoding":"","file":"/opt/gitlab/embedded/service/gitlab-rails/public/-/error-illustrations/error-500-lg.svg","level":"info","method":"GET","msg":"Send static file","time":"2024-10-29T05:50:26Z","uri":"/-/error-illustrations/error-500-lg.svg"}
{"backend_id":"rails","content_type":"image/svg+xml","correlation_id":"01JBBD6N1KZTCQV207EN7SJB92","duration_ms":0,"host":"gitlab.REDACTED.net:8443","level":"info","method":"GET","msg":"access","proto":"HTTP/1.1","referrer":"https://gitlab.REDACTED.net:8443/-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml","remote_addr":"REDACTED_IP:0","remote_ip":"REDACTED_IP","route":"^/-/","route_id":"dash","status":200,"system":"http","time":"2024-10-29T05:50:26Z","ttfb_ms":0,"uri":"/-/error-illustrations/error-500-lg.svg","user_agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0","written_bytes":6506}
==> /var/log/gitlab/nginx/gitlab_access.log <==
REDACTED_IP - - [29/Oct/2024:05:50:26 +0000] "GET /-/error-illustrations/error-500-lg.svg HTTP/2.0" 200 6506 "https://gitlab.REDACTED.net:8443/-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0" -
==> /var/log/gitlab/gitlab-exporter/current <==
2024-10-29_05:50:26.97736 ::1 - - [29/Oct/2024:05:50:26 UTC] "GET /database HTTP/1.1" 200 2230
2024-10-29_05:50:26.97739 - -> /database
==> /var/log/gitlab/gitlab-workhorse/current <==
{"backend_id":"rails","content_type":"text/html","correlation_id":"01JBBD6N2BDGFBZE6KE7H99K00","duration_ms":135,"host":"gitlab.REDACTED.net:8443","level":"info","method":"GET","msg":"access","proto":"HTTP/1.1","referrer":"https://gitlab.REDACTED.net:8443/-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml","remote_addr":"REDACTED_IP:0","remote_ip":"REDACTED_IP","route":"","route_id":"default","status":301,"system":"http","time":"2024-10-29T05:50:27Z","ttfb_ms":135,"uri":"/favicon.ico","user_agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0","written_bytes":192}
==> /var/log/gitlab/nginx/gitlab_access.log <==
REDACTED_IP - - [29/Oct/2024:05:50:27 +0000] "GET /favicon.ico HTTP/2.0" 301 192 "https://gitlab.REDACTED.net:8443/-/ide/project/REDACTED/documentation/edit/main/-/.gitlab-ci.yml" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0" -
Rails Console:
irb(main):001:0> Feature.all.each { |feature| puts "#{feature.name}: #{feature.enabled?}" }
vscode_web_ide: true
ci_job_artifacts_backlog_work: true
=>
[#<Flipper::Feature:792080 name="vscode_web_ide", state=:on, enabled_gate_names=[:boolean], adapter=:memoizable>,
#<Flipper::Feature:792100 name="ci_job_artifacts_backlog_work", state=:on, enabled_gate_names=[:boolean], adapter=:memoizable>,
irb(main):002:0> Feature.enabled?(:vscode_web_ide)
=> true
Ответ или решение
После обновления GitLab с версии 17.2.9 на 17.3.6 и последующего обновления до 17.5.1 возникла проблема с доступом к Web IDE, при попытке открыть редактор возникает ошибка 500. Давайте разберем, как можно решить эту проблему.
Шаг 1. Анализ журналов ошибок
Прежде всего, необходимо проанализировать логи GitLab для определения причины ошибки:
-
Лог
production.log
показывает, что возникла ошибкаOpenSSL::Cipher::CipherError
, возникающая при попытке расшифровки данных. Это может свидетельствовать о несоответствии версий шифрования между базой данных и кодом приложения. Убедитесь, что у вас установлены совместимые библиотеки шифрования, которые соответствуют версии вашего GitLab. -
Лог
gitlab-workhorse.log
и другие логи тоже могут дать представление о проблемах, связанных с маршрутизацией или доступом к ресурсам. Здесь важнее всего обратить внимание на статус ответа, возвращаемого веб-сервером (в данном случае это 500).
Шаг 2. Проверка настроек конфигурации
-
Конфигурационный файл GitLab: Проверьте файл конфигурации (
/etc/gitlab/gitlab.rb
). Убедитесь, что все параметры корректны. Особенно обратите внимание на настройкиexternal_url
иgitlab_rails['gitlab_shell']
. Если вы изменяли какие-то параметры во время обновления, это могло повлиять на работу Web IDE. -
Настройки шифрования: Если использование сторонних библиотек для шифрования (например,
attr_encrypted
) вызывает проблемы, подумайте о необходимости обновления или изменения этих настроек. Проверьте, правильно ли заданы ключи шифрования и аутентификации вgitlab.rb
.
Шаг 3. Проверка функциональности
Выполните следующие команды в Rails консоли, чтобы убедиться, что функциональное состояние Web IDE в норме:
Feature.all.each { |feature| puts "#{feature.name}: #{feature.enabled?}" }
Убедитесь, что vscode_web_ide: true
, чтобы убедиться, что функция включена, и доступна для использования. Если функция отключена, ее можно активировать с помощью команды:
Feature.enable(:vscode_web_ide)
Шаг 4. Обновление и перезапуск сервисов
Сделайте следующее:
- Запустите команду
gitlab-ctl reconfigure
, чтобы система пересобрала конфигурацию на основе файлаgitlab.rb
. - Перезапустите все сервисы GitLab с помощью команды:
gitlab-ctl restart
Шаг 5. Проверка разрешений
Убедитесь, что у пользователя, под которым работает GitLab, есть все необходимые разрешения для чтения и записи данных в каталогах приложения и базы данных.
Шаг 6. Восстановление из резервной копии (если необходимо)
Если шаги выше не помогают и ситуация не улучшается, возможно, стоит рассмотреть откат на предыдущую рабочую версию GitLab (например, на 17.2.9) с помощью резервной копии, если такая имеется.
Заключение
Если ни один из вышеперечисленных шагов не помогает в решении проблемы, рекомендуется обратиться в службу поддержки GitLab или на официальные форумы, где можно получить профессиональную помощь. Важно помнить, что ведение актуального и безопасного программного обеспечения требует постоянного внимания к обновлениям и изменениям в конфигурации.