bayserver-docker-wordpress 2.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/baykit/bayserver/docker/word_press/word_press_docker.rb +57 -0
- metadata +57 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 87741e1c82a8fcb48105d32487405b1e3655c8e44144b51cb8d52422466c5f22
|
4
|
+
data.tar.gz: be9c69954fe6104e530201f0dfe5edf2be27c2cc68b20c333ad096602f63c897
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 3cfc4839ee51efa77a7b288c53467fc4978f58d49a9f848e97dc0f5459138a3bb7efc33ddf45b018b84ce9864b0b11145cea62d277e9567a5b838a9a893a6afb
|
7
|
+
data.tar.gz: c595aac1f57628cf75a518d970651fd612aa7058808f789df35fc67d506e5f12afb827ac48334cd184b5e194bee061d679c0039b7e849c92c0cbc2cc256e81e0
|
@@ -0,0 +1,57 @@
|
|
1
|
+
require 'baykit/bayserver/docker/base/reroute_base'
|
2
|
+
|
3
|
+
module Baykit
|
4
|
+
module BayServer
|
5
|
+
module Docker
|
6
|
+
module WordPress
|
7
|
+
class WordPressDocker < Baykit::BayServer::Docker::Base::RerouteBase
|
8
|
+
include Baykit::BayServer::Bcf
|
9
|
+
include Baykit::BayServer::Util
|
10
|
+
include Baykit::BayServer::Agent
|
11
|
+
|
12
|
+
attr :town_path
|
13
|
+
|
14
|
+
def init(elm, parent)
|
15
|
+
super
|
16
|
+
|
17
|
+
@town_path = parent.location
|
18
|
+
end
|
19
|
+
|
20
|
+
def reroute(twn, uri)
|
21
|
+
|
22
|
+
uri_parts = uri.split("?")
|
23
|
+
uri2 = uri_parts[0]
|
24
|
+
if !match(uri2)
|
25
|
+
return uri
|
26
|
+
end
|
27
|
+
|
28
|
+
rel_path = uri2[twn.name.length .. -1]
|
29
|
+
if rel_path.start_with?("/")
|
30
|
+
rel_path = rel_path[1 .. -1]
|
31
|
+
end
|
32
|
+
|
33
|
+
rel_parts = rel_path.split("/")
|
34
|
+
check_path = ""
|
35
|
+
|
36
|
+
rel_parts.each do | path_item |
|
37
|
+
if StringUtil.set? check_path
|
38
|
+
check_path += "/"
|
39
|
+
end
|
40
|
+
check_path += path_item
|
41
|
+
|
42
|
+
if File.exist?("#{twn.location}/#{check_path}")
|
43
|
+
return uri
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
if !File.exist?("#{twn.location}/#{rel_path}")
|
48
|
+
return "#{twn.name}index.php/#{uri[twn.name.length .. -1]}"
|
49
|
+
else
|
50
|
+
return uri
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|
57
|
+
end
|
metadata
ADDED
@@ -0,0 +1,57 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: bayserver-docker-wordpress
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 2.2.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Michisuke-P
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2023-08-29 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bayserver-core
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - '='
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 2.2.0
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - '='
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 2.2.0
|
27
|
+
description: WordPress docker of BayServer
|
28
|
+
email: michisukep@gmail.com
|
29
|
+
executables: []
|
30
|
+
extensions: []
|
31
|
+
extra_rdoc_files: []
|
32
|
+
files:
|
33
|
+
- lib/baykit/bayserver/docker/word_press/word_press_docker.rb
|
34
|
+
homepage: https://baykit.yokohama
|
35
|
+
licenses:
|
36
|
+
- MIT
|
37
|
+
metadata: {}
|
38
|
+
post_install_message:
|
39
|
+
rdoc_options: []
|
40
|
+
require_paths:
|
41
|
+
- lib
|
42
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
43
|
+
requirements:
|
44
|
+
- - ">="
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '0'
|
47
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
48
|
+
requirements:
|
49
|
+
- - ">="
|
50
|
+
- !ruby/object:Gem::Version
|
51
|
+
version: '0'
|
52
|
+
requirements: []
|
53
|
+
rubygems_version: 3.1.6
|
54
|
+
signing_key:
|
55
|
+
specification_version: 4
|
56
|
+
summary: WordPress docker of BayServer
|
57
|
+
test_files: []
|