@@ -10,12 +10,26 @@ | |||||
</parent> | </parent> | ||||
<version>1.3.0</version> | <version>1.3.0</version> | ||||
<modelVersion>4.0.0</modelVersion> | <modelVersion>4.0.0</modelVersion> | ||||
<artifactId>docker-demo</artifactId> | <artifactId>docker-demo</artifactId> | ||||
<build> | <build> | ||||
<finalName>jdchain-demo</finalName> | <finalName>jdchain-demo</finalName> | ||||
<plugins> | <plugins> | ||||
<plugin> | |||||
<groupId>org.apache.maven.plugins</groupId> | |||||
<artifactId>maven-compiler-plugin</artifactId> | |||||
<version>3.8.1</version> | |||||
<configuration> | |||||
<source>1.8</source> | |||||
<target>1.8</target> | |||||
<encoding>UTF-8</encoding> | |||||
<optimize>false</optimize> | |||||
<debug>true</debug> | |||||
<showDeprecation>false</showDeprecation> | |||||
<showWarnings>false</showWarnings> | |||||
</configuration> | |||||
</plugin> | |||||
<plugin> | <plugin> | ||||
<artifactId>maven-resources-plugin</artifactId> | <artifactId>maven-resources-plugin</artifactId> | ||||
<version>3.0.2</version> | <version>3.0.2</version> | ||||
@@ -5,6 +5,7 @@ RUN yum install wget -y \ | |||||
&& wget -O /etc/yum.repos.d/epel-7.repo http://mirrors.aliyun.com/repo/epel-7.repo \ | && wget -O /etc/yum.repos.d/epel-7.repo http://mirrors.aliyun.com/repo/epel-7.repo \ | ||||
&& yum install java net-tools nc crontabs expect unzip -y \ | && yum install java net-tools nc crontabs expect unzip -y \ | ||||
&& yum install langpacks-zh_CN.noarch -y \ | && yum install langpacks-zh_CN.noarch -y \ | ||||
&& yum install dos2unix -y \ | |||||
&& echo "LANG=zh_CN.utf8" >> /etc/locale.conf \ | && echo "LANG=zh_CN.utf8" >> /etc/locale.conf \ | ||||
&& source /etc/locale.conf \ | && source /etc/locale.conf \ | ||||
&& yum clean all | && yum clean all | ||||
@@ -21,6 +22,7 @@ ENV SERVER_NAME_PEER=deploy-peer | |||||
ENV SERVER_NAME_GW=deploy-gateway | ENV SERVER_NAME_GW=deploy-gateway | ||||
COPY script/* /export/jdchain/ | COPY script/* /export/jdchain/ | ||||
RUN dos2unix /export/jdchain/*.sh | |||||
RUN chmod +x /export/jdchain/*.sh | RUN chmod +x /export/jdchain/*.sh | ||||
# ports | # ports | ||||
@@ -162,12 +162,7 @@ public abstract class SDK_Base_Demo { | |||||
System.out.println("contract's address=" + contractAddress); | System.out.println("contract's address=" + contractAddress); | ||||
// 生成发布合约操作 | // 生成发布合约操作 | ||||
if(contractParams.isHasVersion()){ | |||||
// txTpl.contracts().deploy(contractParams.contractIdentity, contractCode, contractParams.version); | |||||
} else { | |||||
txTpl.contracts().deploy(contractParams.contractIdentity, contractCode); | |||||
} | |||||
txTpl.contracts().deploy(contractParams.contractIdentity, contractCode); | |||||
// 生成预发布交易; | // 生成预发布交易; | ||||
commit(txTpl,contractParams.getSignAdminKey()); | commit(txTpl,contractParams.getSignAdminKey()); | ||||