test drone
continuous-integration/drone/push Build is passing Details

main
lzwang 2022-09-03 00:18:31 +08:00
parent f4f4d0b773
commit bb41c58cd0
8 changed files with 83 additions and 0 deletions

View File

@ -11,7 +11,12 @@ steps: # 定义管道的执行步骤
- hostname - hostname
- echo "********************" - echo "********************"
# - name: "测试Python用例"
# image: python:3.10
- name: "测试微信推送" - name: "测试微信推送"
# https://plugins.drone.io/plugins/wechat-2
image: clem109/drone-wechat image: clem109/drone-wechat
settings: settings:
corpid: corpid:

8
.idea/.gitignore vendored Normal file
View File

@ -0,0 +1,8 @@
# 默认忽略的文件
/shelf/
/workspace.xml
# 基于编辑器的 HTTP 客户端请求
/httpRequests/
# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

8
.idea/ci-test.iml Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="jdk" jdkName="Python 3.10 (ci-test)" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

View File

@ -0,0 +1,6 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>

4
.idea/misc.xml Normal file
View File

@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.10 (ci-test)" project-jdk-type="Python SDK" />
</project>

8
.idea/modules.xml Normal file
View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/ci-test.iml" filepath="$PROJECT_DIR$/.idea/ci-test.iml" />
</modules>
</component>
</project>

6
.idea/vcs.xml Normal file
View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

38
Dockerfile Normal file
View File

@ -0,0 +1,38 @@
FROM python:3.10
# image info
LABEL Project="PythonUniversal"
LABEL Author="lzwang"
LABEL Email="zhuangwang82@gmail.com"
LABEL Version="20220903"
# setup volume
VOLUME /project
# setup workdir
WORKDIR /project
# setup mirrors of pip
# https://mirrors.tuna.tsinghua.edu.cn/help/pypi/
RUN pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
# setup timezone
RUN cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
&& date
# setup mirrors of apt
# https://mirrors.tuna.tsinghua.edu.cn/help/debian/
RUN echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free" > /etc/apt/sources.list \
&& echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free" >> /etc/apt/sources.list \
&& echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free" >> /etc/apt/sources.list \
&& echo "deb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free" >> /etc/apt/sources.list
# update apt packages
RUN apt-get update -y && apt-get upgrade -y \
&& apt-get install apt-utils -y \
&& rm -rf /var/lib/apt/lists/*
# setup alias
RUN echo "alias ll='ls -la'" >> /root/.bashrc
CMD ["python3"]