5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-16 23:26:22 +00:00

Merge branch 'issue-10464' into panel.sutty.nl

This commit is contained in:
f 2023-03-30 14:55:15 -03:00
commit 000b60ec94
4 changed files with 3 additions and 6 deletions

View file

@ -28,8 +28,6 @@ class SitesController < ApplicationController
@site = Site.new
authorize @site
@site.deploys.build type: 'DeployLocal'
end
def create

View file

@ -84,7 +84,8 @@ class DeployLocal < Deploy
'AIRBRAKE_PROJECT_KEY' => site.airbrake_api_key,
'JEKYLL_ENV' => Rails.env,
'LANG' => ENV['LANG'],
'YARN_CACHE_FOLDER' => yarn_cache_dir
'YARN_CACHE_FOLDER' => yarn_cache_dir,
'GEMS_SOURCE' => ENV['GEMS_SOURCE']
})
end

View file

@ -14,6 +14,7 @@ SiteService = Struct.new(:site, :usuarie, :params, keyword_init: true) do
self.site = Site.new params
add_role temporal: false, rol: 'usuarie'
site.deploys.build type: 'DeployLocal'
sync_nodes
I18n.with_locale(usuarie.lang.to_sym || I18n.default_locale) do

View file

@ -158,9 +158,6 @@
= f.fields_for :deploys do |deploy|
= render "deploys/#{deploy.object.type.underscore}",
deploy: deploy, site: site
- else
= f.fields_for :deploys do |deploy|
= deploy.hidden_field :type
.form-group
= f.submit submit, class: 'btn btn-lg btn-block'