Skip to content

Commit

Permalink
Modified MIMEParser class for upload of larger files and multiple fil…
Browse files Browse the repository at this point in the history
…es (#132)

* modified MIMEParser class for upload of larger files and multiple files

Co-authored-by: Per Malmberg
  • Loading branch information
squonk11 authored Jun 13, 2020
1 parent 2dcef56 commit c6e1a1d
Show file tree
Hide file tree
Showing 22 changed files with 884 additions and 143 deletions.
7 changes: 4 additions & 3 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
// Sets the run context to one level up instead of the .devcontainer folder.
"context": "..",

// "image": "permalmberg/smooth:latest",
"image": "permalmberg/smooth:latest",

// Update the 'dockerFile' property if you aren't using the standard 'Dockerfile' filename.
"dockerFile": "../CI/docker-image/Dockerfile",
//"dockerFile": "../CI/docker-image/Dockerfile",

// Set *default* container specific settings.json values on container create.
"settings": {
Expand All @@ -27,7 +27,8 @@

// Uncomment when using a ptrace-based debugger like C++, Go, and Rust
// "runArgs": [ "--cap-add=SYS_PTRACE", "--security-opt", "seccomp=unconfined" ],
"runArgs": [ "--device=/dev/ttyUSB1" ]
//"runArgs": [ "--device=/dev/ttyUSB1" ]
"runArgs": [ "-p", "8080:8080/tcp", "-p", "8443:8443/tcp" ]

// Uncomment to use the Docker CLI from inside the container. See https://aka.ms/vscode-remote/samples/docker-in-docker.
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],
Expand Down
1 change: 1 addition & 0 deletions .vscode/c_cpp_properties.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
"cStandard": "c11",
"cppStandard": "c++17",
"defines": [
"ESP_PLATFORM=0"
],
"browse": {
"path": [
Expand Down
27 changes: 27 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "(gdb) Launch",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/test/http_files_upload_test/http_files_upload_test.elf",
"args": [],
"stopAtEntry": false,
"cwd": "${workspaceFolder}",
"environment": [],
"externalConsole": false,
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
}
]
}
]
}
5 changes: 3 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"cmake.saveBeforeBuild": true,
"cmake.parallelJobs": 4,
"cmake.configureSettings": {
"ESP_PLATFORM": 1
"ESP_PLATFORM": 0
},
"files.associations": {
"typeinfo": "cpp",
Expand Down Expand Up @@ -72,5 +72,6 @@
"unordered_set": "cpp",
"future": "cpp",
"iomanip": "cpp"
}
},
"python.pythonPath": "/usr/local/bin/python"
}
9 changes: 8 additions & 1 deletion CI/docker-image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ RUN apt update \
libmbedtls-dev \
gcc-8 \
g++-8 \
gdb \
libssl-dev \
make \
libz-dev \
Expand All @@ -50,7 +51,9 @@ RUN wget https://www.python.org/ftp/python/3.8.2/Python-3.8.2.tar.xz \
&& cd .. \
&& rm -rf Python-3.8.2 \
&& rm -rf Python-3.8.2.tar \
&& ln -s /usr/local/bin/python3 /usr/local/bin/python
&& ln -s /usr/local/bin/python3 /usr/local/bin/python \
&& pip3 install --upgrade pip \
&& pip3 install pylint requests

# ESP-IDF
RUN cd / \
Expand Down Expand Up @@ -96,5 +99,9 @@ RUN echo ". $IDF_PATH/export.sh" >> ~/.bashrc
# Set locale so that "idf-py menuconfig" can be run.
RUN echo 'export LC_ALL="C.UTF-8"' >> ~/.bashrc && echo 'export LC_CTYPE="C.UTF-8"' >> ~/.bashrc

EXPOSE 80
EXPOSE 8080
EXPOSE 443
EXPOSE 8443

CMD [ "/bin/bash" ]
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ limitations under the License.
cmake_minimum_required(VERSION 3.10)
set(CMAKE_CXX_STANDARD 17)


# Select the test project to build
set(selected_test_project starter_example)

Expand All @@ -39,6 +40,7 @@ list(APPEND available_tests
server_socket_test
secure_server_socket_test
http_server_test
http_files_upload_test
destructing_event_queues
destructing_subscribing_event_queues
security
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Below is the list of individuals that have contributed to the project.
|Name|Contribution details
|----|----|
|[Per Malmberg](https://github.com/PerMalmberg)|Author and maintainer|
|[squonk11](https://github.com/squonk11)|[PR#65](https://github.com/PerMalmberg/Smooth/pull/65), [PR#114](https://github.com/PerMalmberg/Smooth/pull/114)|
|[squonk11](https://github.com/squonk11)|[PR#65](https://github.com/PerMalmberg/Smooth/pull/65), [PR#114](https://github.com/PerMalmberg/Smooth/pull/114)|, [PR#132](https://github.com/PerMalmberg/Smooth/pull/132)|
|[KerryRJ](https://github.com/KerryRJ)|[PR#71](https://github.com/PerMalmberg/Smooth/pull/71)|
|[jeremyjh](https://github.com/jeremyjh)|[PR#87](https://github.com/PerMalmberg/Smooth/pull/87)|
|[COM8](https://github.com/COM8)|[PR#98](https://github.com/PerMalmberg/Smooth/pull/98)|
Expand Down
Loading

0 comments on commit c6e1a1d

Please sign in to comment.