Skip to content

Commit

Permalink
Merge pull request #169 from personium/develop
Browse files Browse the repository at this point in the history
Release v2.1.0
  • Loading branch information
yoh1496 authored Oct 27, 2022
2 parents f845e7c d7929dd commit c07e299
Show file tree
Hide file tree
Showing 28 changed files with 249 additions and 80 deletions.
12 changes: 12 additions & 0 deletions 3-tier/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 1,12 @@
ansible.log

personium_regression.sh

# binary files
resource/ap/opt/tomcat/webapps/personium-core.war
resource/ap/opt/tomcat/webapps/personium-engine.war

# certifications
resource/ap/opt/x509/unit-self-sign.crt
resource/ap/opt/x509/unit.csr
resource/ap/opt/x509/unit.key
4 changes: 2 additions & 2 deletions 3-tier/Ansible_Settings_Instruction.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 16,11 @@ Below are the files where modification is required.
* Example

```yaml
ansible_ssh_user={Ansible_Execution_User}
master_token={Master_Token}

# should be changed to

ansible_ssh_user=ec2-user
master_token=abc123
```

* Modify the hosts file as per instruction below
Expand Down
18 changes: 9 additions & 9 deletions 3-tier/bastion.yml
Original file line number Diff line number Diff line change
@@ -1,13 1,13 @@
# Copyright FUJITSU LIMITED 2015-2017.

- include: ./tasks/bastion/git_clone.yml
- include: ./tasks/bastion/init_maven.yml
- include: ./tasks/bastion/mvn_package.yml
vars:
build_mod: core
- include: ./tasks/bastion/download_personium.yml
# - include: ./tasks/bastion/git_clone.yml
# - include: ./tasks/bastion/init_maven.yml
# - include: ./tasks/bastion/mvn_package.yml
# vars:
# build_mod: core

- include: ./tasks/bastion/mvn_package.yml
vars:
build_mod: engine
# - include: ./tasks/bastion/mvn_package.yml
# vars:
# build_mod: engine
- include: ./tasks/bastion/init_personium_regression.yml

14 changes: 7 additions & 7 deletions 3-tier/group_vars/ap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 17,13 @@ cache_port: 11212
cache_manager: memcached


tomcat_version: 9.0.27
commons_daemon_version : 1.2.2
activemq_version: 5.15.8
tomcat_version: 9.0.68
commons_daemon_version: 1.3.1
activemq_version: 5.15.14

# engine extensions
install_engine_extensions: yes
ex_ew_services_ver: 1.0.2
ex_httpclient_ver: 1.1.5
ex_mailsender_ver: 1.5.3
ex_slack_ver: 1.0.2
ex_ew_services_ver: 1.0.3
ex_httpclient_ver: 1.2.0
ex_mailsender_ver: 1.5.4
ex_slack_ver: 1.0.3
6 changes: 4 additions & 2 deletions 3-tier/group_vars/bastion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 2,8 @@

tag_ServerType: bastion

personium_core_version : master
personium_core_version: 1.8.0
personium_core_sha256: 1457ed813f079ee34ea12835b892543189f84a8a6819b7eff011d41b5b87c65d

personium_engine_version : master
personium_engine_version: 1.6.0
personium_engine_sha256: 0ec57828248b728bb6eb0c36e8071222677f1f7ff16b28f7a7ec90703e1fc4a1
2 changes: 0 additions & 2 deletions 3-tier/group_vars/es.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 7,3 @@ version: 6.6.1

# elasticsearch heapsize
es_heapsize: 3328


2 changes: 1 addition & 1 deletion 3-tier/group_vars/web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 2,5 @@

tag_ServerType: web

nginx_version: 1.14.2
nginx_version: 1.23.2
nginx_hm_version: 0.33
3 changes: 1 addition & 2 deletions 3-tier/resource/ap/opt/logback/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 24,7 @@
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} [%thread] [%-5level] %logger{0} %msg%n</pattern>
</encoder>
</appender>
<!--
Provisional response to separate EventAPI output destinations into separate files -->
<!-- Provisional response to separate EventAPI output destinations into separate files -->
<appender name="FILE_USER" class="ch.qos.logback.core.rolling.RollingFileAppender">
<file>/personium/personium-core/log/personium-user.log</file>
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
Expand Down
3 changes: 1 addition & 2 deletions 3-tier/resource/ap/opt/tomcat/bin/setenv.sh.j2
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 32,7 @@ export JAVA_OPTS=" \
-Xms{{ tomcat_xms }} -Xmx{{ tomcat_xmx }} \
-XX:MetaspaceSize={{ tomcat_metaspace_size }} -XX:MaxMetaspaceSize={{ tomcat_max_metaspace_size }} \
-XX: HeapDumpOnOutOfMemoryError \
-XX: PrintGCDetails \
-XX: PrintGCTimeStamps \
-Xlog:gc*:file=$CATALINA_BASE/logs/gc_%p_%t.log::filecount=5,filesize=10k:time \
-Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true \
-Dlogback.configurationFile=/opt/logback/logback.xml \
-Dio.personium.configurationFile=/personium/personium-core/conf/18888/personium-unit-config.properties \
Expand Down
8 changes: 4 additions & 4 deletions 3-tier/resource/web/opt/nginx/conf/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 79,10 @@ http {
}

location / {
# If a character that can not be used as a URL is passed, it will return a response code 400
# Characters that can not be used as URLs conform to RFC 2396
# For characters not defined in RFC within the range of ASCII code
# Double-byte characters and multibyte characters are excluded from checking
# If a character that can not be used as a URL is passed, it will return a response code 400
# Characters that can not be used as URLs conform to RFC 2396
# For characters not defined in RFC within the range of ASCII code
# Double-byte characters and multibyte characters are excluded from checking
if ($request_uri ~ [\x00-\x20\x22\x3c\x3e\x5b-\x5e\x60\x7b-\x7d\x7f]) {
return 400;
}
Expand Down
8 changes: 4 additions & 4 deletions 3-tier/tasks/ap/personium_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 48,10 @@
group: personium
mode: '0644'
with_items:
- "https://personium.io/mvnrepo/io/personium/personium-ex-ew-services/{{ ex_ew_services_ver }}/personium-ex-ew-services-{{ ex_ew_services_ver }}-libs.jar"
- "https://personium.io/mvnrepo/io/personium/personium-ex-httpclient/{{ ex_httpclient_ver }}/personium-ex-httpclient-{{ ex_httpclient_ver }}-libs.jar"
- "https://personium.io/mvnrepo/io/personium/personium-ex-mailsender/{{ ex_mailsender_ver }}/personium-ex-mailsender-{{ ex_mailsender_ver }}-libs.jar"
- "https://personium.io/mvnrepo/io/personium/personium-ex-slack/{{ ex_slack_ver}}/personium-ex-slack-{{ ex_slack_ver }}-libs.jar"
- "https://github.com/personium/personium-ex-ew-services/releases/download/v{{ ex_ew_services_ver }}/personium-ex-ew-services-{{ ex_ew_services_ver }}-libs.jar"
- "https://github.com/personium/personium-ex-httpclient/releases/download/v{{ ex_httpclient_ver }}/personium-ex-httpclient-{{ ex_httpclient_ver }}-libs.jar"
- "https://github.com/personium/personium-ex-mailsender/releases/download/v{{ ex_mailsender_ver }}/personium-ex-mailsender-{{ ex_mailsender_ver }}-libs.jar"
- "https://github.com/personium/personium-ex-slack-messenger/releases/download/v{{ ex_slack_ver }}/personium-ex-slack-messenger-{{ ex_slack_ver }}-libs.jar"
when: install_engine_extensions | bool

- name: Start tomcat
Expand Down
16 changes: 16 additions & 0 deletions 3-tier/tasks/bastion/download_personium.yml
Original file line number Diff line number Diff line change
@@ -0,0 1,16 @@
# Copyright FUJITSU LIMITED 2015-2022.
---

- name: Download personium war from github
ansible.builtin.get_url:
url: https://github.com/personium/personium-core/releases/download/v{{ personium_core_version }}/personium-core-{{ personium_core_version }}.war
dest: ./resource/ap/opt/tomcat/webapps/personium-core.war
checksum: "sha256:{{ personium_core_sha256 }}"
mode: 0644

- name: Download personium war from github
ansible.builtin.get_url:
url: https://github.com/personium/personium-engine/releases/download/v{{ personium_engine_version }}/personium-engine-{{ personium_engine_version }}.war
dest: ./resource/ap/opt/tomcat/webapps/personium-engine.war
checksum: "sha256:{{ personium_engine_sha256 }}"
mode: 0644
18 changes: 12 additions & 6 deletions 3-tier/tasks/common/init_jdk.yml
Original file line number Diff line number Diff line change
@@ -1,19 1,25 @@
# Copyright FUJITSU LIMITED 2015-2019.
# Copyright FUJITSU LIMITED 2015-2022.

- name: Download JDK
command: 'wget -q -O /usr/src/jdk8u192-b12.tar.gz https://github.com/AdoptOpenJDK/openjdk8-binaries/releases/download/jdk8u192-b12/OpenJDK8U-jdk_x64_linux_hotspot_8u192b12.tar.gz creates=/usr/src/jdk8u192-b12.tar.gz'
ansible.builtin.get_url:
url: https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.4.1+1/OpenJDK17U-jdk_x64_linux_hotspot_17.0.4.1_1.tar.gz
dest: /usr/src/jdk-17.0.4.1 1.tar.gz
mode: 0660

- name: Expand JDK
command: "tar -xzf /usr/src/jdk8u192-b12.tar.gz -C /usr/src creates=/usr/src/jdk8u192-b12"
ansible.builtin.unarchive:
src: /usr/src/jdk-17.0.4.1 1.tar.gz
dest: /usr/src
remote_src: true

- name: Change owner JDK
file: "state=directory path=/usr/src/jdk8u192-b12 owner=root group=root recurse=yes"
file: "state=directory path=/usr/src/jdk-17.0.4.1 1 owner=root group=root recurse=yes"

- name: Deploy JDK
command: "mv /usr/src/jdk8u192-b12 /opt creates=/opt/jdk8u192-b12"
command: "mv /usr/src/jdk-17.0.4.1 1 /opt creates=/opt/jdk-17.0.4.1 1"

- name: Create smlink /opt/jdk
file: "state=link src=/opt/jdk8u192-b12 dest=/opt/jdk"
file: "state=link src=/opt/jdk-17.0.4.1 1 dest=/opt/jdk"

- name: Add JDK to environment variable
copy: src=./resource/common/etc/bashrc dest=/etc/bashrc owner=root group=root mode=0644
9 changes: 4 additions & 5 deletions 3-tier/tasks/nfs/init_memcached_env_os.yml
Original file line number Diff line number Diff line change
@@ -1,15 1,15 @@
# Copyright FUJITSU LIMITED 2015.
# Copyright FUJITSU LIMITED 2015-2017.

- name: Create group
group: name=memcached gid=2040 state=present

- name: Create user
user: name=memcached uid=2040 shell=/sbin/nologin group=memcached home=/opt/var/lib/memcached comment="Memcached Administrator" createhome=no

- name: Create /opt/var/lib
- name: Create /opt/var/lib directory
file: "state=directory path=/opt/var/lib owner=root group=root"

- name: Create Home directory
- name: Create home directory
file: "state=directory path=/opt/var/lib/memcached owner=memcached group=memcached recurse=yes"

- name: Create /personium/memcached directory
Expand All @@ -18,6 18,5 @@
- name: Create /personium/memcached/log directory
file: state=directory path=/personium/memcached/log owner=memcached group=memcached mode=0755

- name: Create /var/run/memcached
- name: Create /var/run/memcached directory
file: state=directory path=/var/run/memcached owner=memcached group=memcached mode=0755

102 changes: 102 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 1,102 @@
## 2.1.0

Compatible Personium version: 1.8.0

Enhancement:

- Update Java version to 17. #161
- Update middlewares. #167

MISC:

- Downloading war files from GitHub releases. #166
- Downloading extension jar files from GitHub releases. #163

See: https://github.com/personium/ansible/milestone/6?closed=1

## 2.0.11

See: https://github.com/personium/ansible/milestone/8?closed=1

## 2.0.10

See: https://github.com/personium/ansible/milestone/5?closed=1

## 2.0.9

See: https://github.com/personium/ansible/milestone/4?closed=1

## 2.0.8a

Bug fixes:

- Fix web_private_ip. #107

## 2.0.8

Enhancement:

- Fix static_inventory/hosts uses many duplicated variables #99
- Separation of bastion and web #97
- X-Personium-RequestKey header output in nginx logs #89
- Upgrade middlewares #103

BugFixes:

- SSH user is hard-coded. #98

## 2.0.7

Support percell fqdn
Corresponded to ElasticSearch 6.6.1

## 2.0.6

Corresponded to ElasticSearch 5.6.14

## 2.0.5

Corresponded to OpenJDK 8.
Corresponded to tomcat 9.c

## 2.0.4

Merge pull request #43 from naoya-mokudai/develop

Fix URL mistake

## 2.0.3

Merge pull request #33 from personium/2.0.3_dev

2.0.3 release

## 2.0.2

Release v2.0.2

## 2.0.1

Changing the specification key of host file.

This ansible has already been confirmed with Personium v1.5.3.

## 2.0.0

ansible for Personium v1.5.2 or later.

## 1.5.1

ansible for Personium v1.5.1 #13

## 1.5.0

ansible for Personium v1.5.0 #11

## 1.4.5

Core and Engine version used for ansible are fixed to 1.4.5.

## 1.4.3

Optimized for Personium v1.4.3.
12 changes: 12 additions & 0 deletions all-in-one/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 1,12 @@
ansible.log

personium_regression.sh

# binary files
resource/ap/opt/tomcat/webapps/personium-core.war
resource/ap/opt/tomcat/webapps/personium-engine.war

# certifications
resource/ap/opt/x509/unit-self-sign.crt
resource/ap/opt/x509/unit.csr
resource/ap/opt/x509/unit.key
18 changes: 10 additions & 8 deletions all-in-one/bastion.yml
Original file line number Diff line number Diff line change
@@ -1,12 1,14 @@
# Copyright FUJITSU LIMITED 2015-2017.

- include: ./tasks/bastion/git_clone.yml
- include: ./tasks/bastion/init_maven.yml
- include: ./tasks/bastion/download_personium.yml

- include: ./tasks/bastion/mvn_package.yml
vars:
build_mod: core
# - include: ./tasks/bastion/git_clone.yml
# - include: ./tasks/bastion/init_maven.yml

- include: ./tasks/bastion/mvn_package.yml
vars:
build_mod: engine
# - include: ./tasks/bastion/mvn_package.yml
# vars:
# build_mod: core

# - include: ./tasks/bastion/mvn_package.yml
# vars:
# build_mod: engine
14 changes: 7 additions & 7 deletions all-in-one/group_vars/ap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 17,13 @@ cache_port: 11212
cache_manager: memcached


tomcat_version: 9.0.27
commons_daemon_version : 1.2.2
activemq_version: 5.15.8
tomcat_version: 9.0.68
commons_daemon_version: 1.3.1
activemq_version: 5.15.14

# engine extensions
install_engine_extensions: yes
ex_ew_services_ver: 1.0.2
ex_httpclient_ver: 1.1.5
ex_mailsender_ver: 1.5.3
ex_slack_ver: 1.0.2
ex_ew_services_ver: 1.0.3
ex_httpclient_ver: 1.2.0
ex_mailsender_ver: 1.5.4
ex_slack_ver: 1.0.3
6 changes: 4 additions & 2 deletions all-in-one/group_vars/bastion.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 2,8 @@

tag_ServerType: bastion

personium_core_version : master
personium_core_version: 1.8.0
personium_core_sha256: 1457ed813f079ee34ea12835b892543189f84a8a6819b7eff011d41b5b87c65d

personium_engine_version : master
personium_engine_version: 1.6.0
personium_engine_sha256: 0ec57828248b728bb6eb0c36e8071222677f1f7ff16b28f7a7ec90703e1fc4a1
Loading

0 comments on commit c07e299

Please sign in to comment.