0%

55. 搭建网址

  • root命令

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
     1  apt update
    2 apt upgrade
    3 adduser lqr
    4 usermod -aG sudo lqr
    5 adduser test
    6 usermod -aG root test
    7 su test
    8 ls
    9 sudo rm -r nmap.tar.gz
    10 ls
    11 sudo rm -r python-nmap-0.1.4.tar.gz
    12 ls
    13 history
    14 userdel -r test
    15 ls
    16 cd ..
    17 cd ~
    18 ls
    19 userdel -r test
    20 history
    21 test
    22 ls
    23 cd /home
    24 ls
    25 userdel -r test
    26 ls
    27 adduser test
    28 usermod -aG sudo test
    29 su test
    30 history
  • lqr命令

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    154
    155
    156
    157
    158
    159
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    171
    172
    173
    174
    175
    176
    177
    178
    179
    180
    181
    182
    183
    184
    185
    186
    187
    188
    189
    190
    191
    192
    193
    194
    195
    196
    197
    198
    199
    200
    201
    202
    203
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
    215
    216
    217
    218
    219
    220
    221
    222
    223
    224
    225
    226
    227
    228
    229
    230
    231
    232
    233
    234
    235
    236
    237
    238
    239
    240
    241
    242
    243
    244
    245
    246
    247
    248
    249
    250
    251
    252
    253
    254
    255
    256
    257
    258
    259
    260
    261
    262
    263
    264
    265
    266
    267
    268
    269
    270
    271
    272
    273
    274
    275
    276
    277
    278
    279
    280
    281
    282
    283
    284
    285
    286
    287
    288
    289
    290
    291
    292
    293
    294
    295
    296
    297
    298
    299
    300
    301
    302
    303
    304
    305
    306
    307
    308
    309
    310
    311
    312
    313
    314
    315
    316
    317
    318
    319
    320
    321
    322
    323
    324
    325
    326
    327
    328
    329
    330
    331
    332
    333
    334
    335
    336
    337
    338
    339
    340
    341
    342
    343
    344
    345
    346
    347
    348
    349
    350
    351
    352
    353
    354
    355
    356
    357
    358
    359
    360
    361
    362
    363
    364
    365
    366
    367
    368
    369
    370
    371
    372
    373
    374
    375
    376
    377
    378
    379
    380
    381
    382
    383
    384
    385
    386
    387
    388
    389
    390
    391
    392
    393
    394
    395
    396
    397
    398
    399
    400
    401
    402
    403
    404
    405
    406
    407
    408
    409
    410
    411
    412
    413
    414
    415
    416
    417
    418
    419
    420
    421
    422
    423
    424
    425
    426
    427
    428
    429
    430
    431
    432
    433
    434
    435
    436
    437
    438
    439
    440
    441
    442
    443
    444
    445
    446
    447
    448
    449
    450
    451
    452
    453
    454
    455
    456
    457
    458
    459
    460
    461
    462
    463
    464
    465
    466
    467
    468
    469
    470
    471
    472
    473
    1  clear
    2 sudo apt install nginx
    3 sudo ufw allow 22
    4 sudo ufw allow 80
    5 sudo ufw allow 443
    6 sudo ufw enable
    7 sudo ufw state
    8 sudo ufw status
    9 sudo apt install python3-pip
    10 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
    11 pip3 install pipenv
    12 flask init
    13 flask forge
    14 flask run
    15 exit
    16 flask init
    17 cd /et
    18 cd /etc
    19 cd supervisor/
    20 ls
    21 cat supervisord.conf
    22 sudo service supervisor restart
    23 cd /etc/nginx
    24 ls
    25 cd sites-enabled/
    26 ls
    27 cat record-it
    28 sudo ufw status
    29 sudo service nginx restart
    30 sudo supervisorctl update
    31 sudo supervisorctl record-it start
    32 sudo supervisorctl
    33 pip3 update
    34 sudo pip3 install --upgrade pip
    35 sudo nano /usr/bin/pip3
    36 sudo pip3 install --upgrade pip
    37 pip3
    38 pip3 -V
    39 sudo service supervisor restart
    40 sudo service nginx restart
    41 sudo supervisorctl
    42 ls
    43 cd ..
    44 ls
    45 cd /etc/supervisor/
    46 ls
    47 sudo nano supervisord.conf
    48 sudo ufw allow 9001
    49 ls
    50 sudo ufw status
    51 cd
    52 exit
    53 cd record-it
    54 ls
    55 pipenv install --dev
    56 pipenv shell
    57 cd ..
    58 sudo nginx -t
    59 cd /etc/nginx
    60 ls
    61 cd sites-enabled/
    62 ls
    63 sudo nano record-it
    64 ls
    65 sudo mv default
    66 ls
    67 sudo mv default
    68 sudo mv --help
    69 ls
    70 cat default
    71 sudo mv --help
    72 sudo mv default
    73 cler
    74 clear
    75 ls
    76 cd ~
    77 sudo apt install supervisor
    78 cd /etc/supervisor/
    79 ls
    80 cd conf.d
    81 ls
    82 sudo nano record-it.conf
    83 cd ..
    84 ls
    85 sudo nano supervisord.conf
    86 sudo supervisorctl
    87 sudo nano supervisord.conf
    88 sudo nano record-it.conf
    89 ls
    90 cd conf.d
    91 ls
    92 sudo nano record-it.conf
    93 cd ..
    94 ls
    95 sudo rm record-it.conf
    96 ls
    97 sudo supervisorctl
    98 sudo supervisorctl reread
    99 sudo supervisorctl update
    100 sudo supervisorctl
    101 sudo service nginx restart
    102 cd /etc/nginx
    103 ls
    104 cd conf.d
    105 ls
    106 cd ..
    107 cd sites-enabled/
    108 ls
    109 sudo rm default
    110 ls
    111 cd ..
    112 cd /etc/supervisor/
    113 ls
    114 sudo supervisorctl
    115 cd /etc/nginx
    116 cd sites-enabled/
    117 ls
    118 cat record-it
    119 sudo nginx 0t
    120 sudo nginx -t
    121 sudo service nginx re
    122 sudo service nginx restart
    123 sudo nginx -t
    124 ls
    125 sudo service supervisor restart
    126 sudo supervisorctl
    127 cd ~
    128 cd record-it/
    129 cd..
    130 cd ..
    131 sudo supervisorctl
    132 cd ~/record-it/
    133 ls
    134 cd server/
    135 ls
    136 sudo vim nginx.config
    137 sudo vim supervisor.ini
    138 cd ~
    139 sudo supervisor
    140 sudo supervisorctl
    141 pip3 install pipenv
    142 cd record-i
    143 sudo service supervisor restart
    144 sudo supervisorctl
    145 cd record-it/
    146 pip3 install pipenv
    147 pipenv shell
    148 sudo ufw status
    149 cd ~
    150 ls
    151 cd /etc/supervisor/
    152 ls
    153 cat supervisord.conf
    154 sudo service supervisor res
    155 sudo service supervisor restart
    156 sudo service nginx restart
    157 sudo supervisorctl
    158 cd ~/record-it/
    159 ls
    160 pip3 install pipenv
    161 pipenv -V
    162 pipenv --version
    163 sudo supervisorctl
    164 cd ~
    165 sudo nano /etc/supervisor/conf.d/record-it.conf
    166 pip3 install uwsgi
    167 sudo pip3 install uwsgi
    168 sudo service supervisor restart
    169 sudo service nginx restart
    170 sudo nginx -t
    171 sudo supervisorctl
    172 cd /etc/nginx
    173 ls
    174 cd sites-enabled/
    175 ls
    176 cd conf.s
    177 cd conf.d
    178 ls
    179 cd .. conf.d
    180 ls
    181 cd conf.d/
    182 ls
    183 cd /etc/supervisor/
    184 ls
    185 cd conf.d/
    186 ls
    187 cat record-it.conf
    188 cd /etc/nginx/
    189 ls
    190 cat nginx.conf
    191 cd sites-enabled/
    192 ls
    193 cat record-it
    194 ls
    195 cd ..
    196 ls
    197 cd conf.d
    198 ls
    199 cd ..
    200 ls
    201 clear
    202 ls
    203 cd sites-enabled/
    204 ls
    205 cat record-it
    206 cd /etc/nginx/
    207 ls
    208 cd conf.d/
    209 ls
    210 cd /etc/supervisor/
    211 ls
    212 cd conf.d/
    213 ls
    214 cat record-it.conf
    215 sudo nginx -t
    216 sudo service nginx restart
    217 sudo service supervisor restart
    218 sudo nginx -t
    219 ls
    220 sudo supervisorctl
    221 ls
    222 cd ..
    223 ls
    224 cat supervisord.conf
    225 cd .
    226 cd..
    227 cd ..
    228 ls
    229 cd nginx/
    230 ls
    231 cd sites-enabled/
    232 ls
    233 cat record-it
    234 uwsgi
    235 uwsgi -V
    236 uwsgi --version
    237 sudo nginx -t
    238 cd /etc/supervisor/
    239 ls
    240 cd conf.d
    241 ls
    242 car record-it.conf
    243 cat record-it.conf
    244 clear
    245 cat sup
    246 cat record-it.conf
    247 sudo supervisorctl reread
    248 sudo supervisorctl update
    249 sudo supervisorctl record-it stop
    250 sudo supervisorctl record-it start
    251 cd ..
    252 cat supervisord.conf
    253 sudo supervisorctl
    254 su
    255 su root
    256 flask init
    257 flask forge
    258 flask run
    259 exit
    260 flask init
    261 clear
    262 flask init
    263 pip3 install pipenv
    264 pipenv --version
    265 pip uninstall pipenv
    266 pip3 install pipenv
    267 sudo pip3 install pipenv
    268 ls
    269 cd record-it/
    270 ls
    271 pipenv install --dev
    272 ls
    273 pipenv install --dev
    274 sudo service nginx restart
    275 sudo nginx -y
    276 sudo nginx -t
    277 sudo service supervisor restart
    278 sudo supervisorctl
    279 cd ~
    280 sudo supervisorctl
    281 cd record-it/
    282 ls
    283 pipenv install --dev
    284 pipenv shell
    285 ls
    286 pipenv shell
    287 pipenv rm
    288 pipenv shell
    289 pipenv init
    290 flask init
    291 flask forge
    292 flask run
    293 sudo service nginx restart
    294 sudo service supervisor restart
    295 sudo service nginx restart
    296 ls
    297 clar
    298 clear
    299 pip3 list
    300 cd record-it/
    301 ls
    302 pipenv install --dev
    303 pipenv shell
    304 sudo service supervisor restart
    305 service nginx restart
    306 sudo service nginx restart
    307 cd /etc/nginx
    308 ls
    309 cd sites-
    310 cd sites-enabled/
    311 ls
    312 cat record-it
    313 cd ~
    314 sudo supervisor
    315 sudo supervisorctl
    316 pip3 install dotenv
    317 sudo pip3 install dotenv
    318 sudo service nginx restart
    319 nginx error log
    320 sudo nginx error log
    321 sudo service supervisor restart
    322 sudo supervisorctl
    323 cd ..
    324 sudo pip3 install Jinja2
    325 sudo pip3 install flask
    326 sudo pip3 install flask-babel
    327 sudo pip3 install flask-apscheduler
    328 exit
    329 pip3 install uwsgi
    330 exit
    331 clear
    332 ping 39.105.48.114
    333 sudo supervisorctl
    334 python3
    335 pip3 uninstall dotenv
    336 sudo pip3 uninstall dotenv
    337 sudo pip3 install python-dotenv
    338 sudo service nginx restart
    339 sudo service supervisor restart
    340 sudo supervisorctl
    341 pip3 install python-click
    342 sudo pip3 install python-click
    343 sudo pip3 install click
    344 sudo service supervisor restart
    345 sudo service nginx restart
    346 sudo supervisorctl
    347 sudo pip3 install flask
    348 sudo service supervisor restart
    349 sudo service nginx restart
    350 sudo supervisorctl
    351 sudo pip3 uninstall flask
    352 sudo pip3 install python-flask
    353 pip3 install flask
    354 sudo pip3 install flask
    355 sudo pip3 install flask_babel
    356 sudo supervisorctl
    357 cd record-it/
    358 ls
    359 pipenv shell
    360 pip3 list
    361 cd ..
    362 sudo pip3 install apscheduler
    363 sudo pip3 install flask-apscheduler
    364 sudo pip3 install flask-caching
    365 sudo pip3 install flask-login
    366 sudo pip3 install flask-sqlalchemy
    367 sudo pip3 install flask-wtf
    368 sudo pip3 install bootstrap-flask
    369 sudo pip3 install flask-ckeditor
    370 sudo pip3 install faker
    371 sudo pip3 install flask-moment
    372 sudo pip3 install pandas
    373 sudo pip3 install openpyxl
    374 sudo service supervisor restart
    375 sudo service nginx restart
    376 sudo supervisor
    377 sudo supervisorctl
    378 pip install dot-python
    379 sudo pip3 install dot-Ppython
    380 sudo pip3 install dot-Python
    381 sudo pip3 install dotenv-Python
    382 sudo pip3 install dot-python
    383 cd record-it/
    384 ls
    385 sudo nano .env
    386 ls
    387 sudo vim .env
    388 ls
    389 sudo vim .env
    390 ls
    391 sudo vim .env
    392 ls
    393 sudo vim .env
    394 sudo service nginx restart
    395 sudo service supervisor restart
    396 cd ..
    397 cd record-it/
    398 nano .env
    399 sudo vim .env
    400 sudo service supervisor restart
    401 sudo service nginx restart
    402 sudo supervisorctl
    403 whereis uwsgi
    404 cd /usr/local/bin/uwsgi
    405 ls
    406 cd /usr/local/bin/uwsgi
    407 cd /usr/local
    408 ls
    409 cd bin
    410 ls
    411 cd uwsgi
    412 sudo cd uwsgi
    413 cd ~'
    414 cd ~
    415 cd ~
    416 uwsgi -s /tmp/uwsgi.sock -M -p 4 -t 30 --limit-as 128 -R 10000 -d /var/log/uwsgi.log --vhost --uid www --gid www --python-autoreload 1
    417 tail -f /tmp/uwsgi.log
    418 tail -f /usr/local/bin/uwsgi/uwsgi.log
    419 pip3 uninstall uwsgi
    420 sudo pip3 uninstall uwsgi
    421 ls
    422 pip3 list
    423 apt-get install build-essential python-dev
    424 sudo apt-get install build-essential python-dev
    425 pip3
    426 pip3 -V
    427 pip3 install uwsgi
    428 sudo pip3 install uwsgi
    429 mkdir test
    430 ls
    431 cd test
    432 nano foobar.py
    433 uwsgi --http :9090 --wsgi-file foobar.py
    434 cd
    435 sudo service nginx restart
    436 sudo service supervisor restart
    437 sudo supervisorctl
    438 cd record-it/
    439 ls
    440 pipenv shell
    441 sudo service supervisor restart
    442 sudo service nginx restart
    443 sudo supervisorctl
    444 flask init
    445 flask forge
    446 flask run
    447 exit
    448 sudo nginx -t
    449 sudo service nginx restart '
    450 sudo service nginx restart
    451 sudo service supervisor restart
    452 sudo nginx -t
    453 cd record-it
    454 pipenv shell
    455 l
    456 ls
    457 sudo service nginx restart
    458 sudo service supervisor restart
    459 clear
    460 cd ..
    461 ls
    462 cd record-it
    463 ls
    464 cd record-it
    465 ls
    466 sudo nano .env
    467 pipenv shell
    468 flask init
    469 flask forge
    470 flask run
    471 sudo service nginx restart
    472 sudo service supervisor restart
    473 history
  • test 命令

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    1  ls
    2 cd test
    3 clearclear
    4 clear
    5 wget http://xael.org/norman/python/python-nmap/python-nmap-0.1.4.tar.gz -o nmap.tar.gz
    6 ls
    7 tar
    8 tar --version
    9 tar -xzf nmap.tar.gz
    10 ls
    11 sudo apt install tar
    12 ls
    13 tar -xzf nmap.tar.gz
    14 ls
    15 tar -zxvf nmap.tar.gz
    16 ls
    17 tar --V
    18 tar -V
    19 tar --version
    20 tar -zxvf nmap.tar.gz
    21 tar -xvf nmap.tar.gz
    22 tar zxvf nmap.tar.gz
    23 tar -xvf nmap.tar.gz
    24 tar xvf nmap.tar.gz
    25 ls
    26 tar xvf python-nmap-0.1.4.tar.gz
    27 ls
    28 cd python-nmap-0.1.4/
    29 ls
    30 python setup.py in
    31 python setup.py install
    32 sudo python setup.py install
    33 ls
    34 easy_install python-nmap
    35 sudo easy_install python-nmap
    36 cd ..
    37 ls
    38 sudo easy_install pyPdf python-nmap pygeoip mechanize BeautifulSoup4
    39 sudo apt-get install python-bluez bluetooth python-obexftp
    40 ls
    41 mkdir demo
    42 ls
    43 cd demo
    44 echo print \"Hello world\" > hello.py
    45 l
    46 python hello.py
    47 python
    48 import socket
    49 python
    50 ls
    51 nano hello.py