Skip to content

Commit 266287c

Browse files
committed
feat: edit ccapi to be just an extension
Signed-off-by: osamamagdy <osamamagdy174@gmail.com>
1 parent 189cdac commit 266287c

38 files changed

+65
-2478
lines changed

samples/application/ccapi/Dockerfile

Lines changed: 20 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -31,29 +31,32 @@ COPY . .
3131
# Build the Go ccapi
3232
RUN go build -o ccapi
3333

34-
# Use an official Alpine runtime as a parent image
35-
FROM alpine:latest
34+
# # Use an official Alpine runtime as a parent image
35+
# FROM alpine:latest
3636

37-
ENV PATH="${PATH}:/usr/bin/"
37+
# ENV PATH="${PATH}:/usr/bin/"
3838

39-
RUN apk update
39+
# RUN apk update
4040

41-
RUN apk add \
42-
docker \
43-
openrc \
44-
git \
45-
gcc \
46-
gcompat \
47-
libc-dev \
48-
libc6-compat \
49-
libstdc++ && \
50-
ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
41+
# RUN apk add \
42+
# docker \
43+
# openrc \
44+
# git \
45+
# gcc \
46+
# gcompat \
47+
# libc-dev \
48+
# libc6-compat \
49+
# libstdc++ && \
50+
# ln -s /lib/libc.so.6 /usr/lib/libresolv.so.2
5151

52-
# Set the working directory to /rest-server
53-
WORKDIR /rest-server
52+
# # Set the working directory to /rest-server
53+
# WORKDIR /rest-server
5454

5555
# Copy the ccapi binary from the build container to the current directory in the Alpine container
56-
COPY --from=build /rest-server/ccapi /usr/bin/ccapi
56+
RUN ls -l
57+
RUN pwd
58+
59+
RUN cp ./ccapi /usr/bin/ccapi
5760

5861
# Run the ccapi binary
5962
CMD ["ccapi"]

samples/application/ccapi/chaincode/event.go

Lines changed: 0 additions & 145 deletions
This file was deleted.

samples/application/ccapi/chaincode/eventHandler.go

Lines changed: 0 additions & 97 deletions
This file was deleted.

samples/application/ccapi/chaincode/invoke.go

Lines changed: 0 additions & 37 deletions
This file was deleted.

samples/application/ccapi/chaincode/invokeFPC.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ package chaincode
99
import (
1010
"net/http"
1111

12-
"github.com/hyperledger-labs/ccapi/common"
12+
"github.com/hyperledger/fabric-private-chaincode/samples/application/ccapi/common"
1313
)
1414

1515
func InvokeFpc(channelName string, chaincodeName string, txname string, args [][]byte) ([]byte, int, error) {

samples/application/ccapi/chaincode/invokeFPCDefault.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ package chaincode
99
import (
1010
"net/http"
1111

12-
"github.com/hyperledger-labs/ccapi/common"
12+
"github.com/hyperledger/fabric-private-chaincode/samples/application/ccapi/common"
1313
)
1414

1515
func InvokeFpcDefault(txname string, args [][]byte) ([]byte, int, error) {

0 commit comments

Comments
 (0)