shipit-cli 0.6.1__tar.gz → 0.7.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/PKG-INFO +3 -1
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/pyproject.toml +3 -1
- shipit_cli-0.7.1/src/shipit/assets/wordpress/install.sh +33 -0
- shipit_cli-0.7.1/src/shipit/assets/wordpress/wp-config.php +133 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/cli.py +243 -116
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/generator.py +27 -16
- shipit_cli-0.7.1/src/shipit/procfile.py +106 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/base.py +19 -3
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/gatsby.py +18 -6
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/hugo.py +6 -2
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/laravel.py +17 -6
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/mkdocs.py +16 -7
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/node_static.py +18 -6
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/php.py +39 -10
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/python.py +54 -14
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/registry.py +2 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/providers/staticfile.py +18 -6
- shipit_cli-0.7.1/src/shipit/providers/wordpress.py +88 -0
- shipit_cli-0.7.1/src/shipit/version.py +5 -0
- shipit_cli-0.6.1/src/shipit/version.py +0 -5
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/.gitignore +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/README.md +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/__init__.py +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/src/shipit/assets/php/php.ini +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/tests/test_examples_build.py +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/tests/test_generate_shipit_examples.py +0 -0
- {shipit_cli-0.6.1 → shipit_cli-0.7.1}/tests/test_version.py +0 -0
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: shipit-cli
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.7.1
|
|
4
4
|
Summary: Add your description here
|
|
5
5
|
Project-URL: homepage, https://wasmer.io
|
|
6
6
|
Project-URL: repository, https://github.com/wasmerio/shipit
|
|
7
7
|
Project-URL: Changelog, https://github.com/wasmerio/shipit/changelog
|
|
8
8
|
Requires-Python: >=3.10
|
|
9
|
+
Requires-Dist: dotenv>=0.9.9
|
|
9
10
|
Requires-Dist: pyyaml>=6.0.2
|
|
11
|
+
Requires-Dist: requests>=2.32.5
|
|
10
12
|
Requires-Dist: rich>=14.1.0
|
|
11
13
|
Requires-Dist: sh>=2.2.2
|
|
12
14
|
Requires-Dist: starlark-pyo3>=2025.1
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "shipit-cli"
|
|
3
|
-
version = "0.
|
|
3
|
+
version = "0.7.1"
|
|
4
4
|
description = "Add your description here"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
requires-python = ">=3.10"
|
|
7
7
|
dependencies = [
|
|
8
|
+
"dotenv>=0.9.9",
|
|
8
9
|
"pyyaml>=6.0.2",
|
|
10
|
+
"requests>=2.32.5",
|
|
9
11
|
"rich>=14.1.0",
|
|
10
12
|
"sh>=2.2.2",
|
|
11
13
|
"starlark-pyo3>=2025.1",
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Needed to get the WP-CLI commands to avoid asking for the TTY size, which
|
|
2
|
+
# doesn't work because we don't have the stty command it uses.
|
|
3
|
+
export COLUMNS=80
|
|
4
|
+
|
|
5
|
+
echo "Creating required directories..."
|
|
6
|
+
|
|
7
|
+
mkdir -p wp-content/plugins
|
|
8
|
+
echo "" > wp-content/plugins/.keep
|
|
9
|
+
|
|
10
|
+
mkdir -p wp-content/upgrade
|
|
11
|
+
echo "" > wp-content/upgrade/.keep
|
|
12
|
+
|
|
13
|
+
echo "Installing WordPress core..."
|
|
14
|
+
|
|
15
|
+
wp-cli core install \
|
|
16
|
+
--url="$WASMER_APP_URL" \
|
|
17
|
+
--title="$WP_SITE_TITLE" \
|
|
18
|
+
--admin_user="$WP_ADMIN_USERNAME" \
|
|
19
|
+
--admin_password="$WP_ADMIN_PASSWORD" \
|
|
20
|
+
--admin_email="$WP_ADMIN_EMAIL" \
|
|
21
|
+
--locale="$WP_LOCALE"
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
if [ -z "$WASMER_FIRST_DEPLOYMENT" ]; then
|
|
25
|
+
wp-cli core update-db
|
|
26
|
+
fi
|
|
27
|
+
|
|
28
|
+
echo "Installing theme..."
|
|
29
|
+
wp-cli wasmer-aio-install install \
|
|
30
|
+
--locale="$WP_LOCALE" \
|
|
31
|
+
--theme=twentytwentyfive || true
|
|
32
|
+
|
|
33
|
+
echo "Installation complete"
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
<?php
|
|
2
|
+
|
|
3
|
+
define( 'WP_AUTO_UPDATE_CORE', false); // Disable automatic aupdates and checks
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* The base configuration for WordPress
|
|
7
|
+
*
|
|
8
|
+
* The wp-config.php creation script uses this file during the installation.
|
|
9
|
+
* You don't have to use the web site, you can copy this file to "wp-config.php"
|
|
10
|
+
* and fill in the values.
|
|
11
|
+
*
|
|
12
|
+
* This file contains the following configurations:
|
|
13
|
+
*
|
|
14
|
+
* * Database settings
|
|
15
|
+
* * Secret keys
|
|
16
|
+
* * Database table prefix
|
|
17
|
+
* * ABSPATH
|
|
18
|
+
*
|
|
19
|
+
* @link https://wordpress.org/support/article/editing-wp-config-php/
|
|
20
|
+
*
|
|
21
|
+
* @package WordPress
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
function get_env_var(string $name, string $default = ''): string
|
|
26
|
+
{
|
|
27
|
+
if (isset($_ENV[$name])) {
|
|
28
|
+
return $_ENV[$name];
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
$stderr = fopen("php://stderr", "wb");
|
|
32
|
+
fwrite($stderr, "Configuration error: environment variable " . $name . " not provided. Using default value: " . $default . PHP_EOL);
|
|
33
|
+
fclose($stderr);
|
|
34
|
+
|
|
35
|
+
return $default;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// ** Database settings - You can get this info from your web host ** //
|
|
39
|
+
/** The name of the database for WordPress */
|
|
40
|
+
define( 'DB_NAME', get_env_var('DB_NAME', 'wordpress') );
|
|
41
|
+
|
|
42
|
+
/** Database username */
|
|
43
|
+
define( 'DB_USER', get_env_var('DB_USERNAME', 'root') );
|
|
44
|
+
|
|
45
|
+
/** Database password */
|
|
46
|
+
define( 'DB_PASSWORD', get_env_var('DB_PASSWORD', '') );
|
|
47
|
+
|
|
48
|
+
/** Database hostname */
|
|
49
|
+
define( 'DB_HOST', get_env_var('DB_HOST', '127.0.0.1') . ":" . get_env_var('DB_PORT', '3306') );
|
|
50
|
+
|
|
51
|
+
define('MYSQL_CLIENT_FLAGS', MYSQLI_CLIENT_SSL);
|
|
52
|
+
|
|
53
|
+
/** Database charset to use in creating database tables. */
|
|
54
|
+
define( 'DB_CHARSET', 'utf8' );
|
|
55
|
+
|
|
56
|
+
/** The database collate type. Don't change this if in doubt. */
|
|
57
|
+
define( 'DB_COLLATE', 'utf8mb4_general_ci' );
|
|
58
|
+
|
|
59
|
+
// define('WP_ALLOW_REPAIR', true);
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
// define('DB_DIR', dirname(dirname(__FILE__)) . '/db/');
|
|
63
|
+
|
|
64
|
+
/**#@+
|
|
65
|
+
* Authentication unique keys and salts.
|
|
66
|
+
*
|
|
67
|
+
* Change these to different unique phrases! You can generate these using
|
|
68
|
+
* the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service}.
|
|
69
|
+
*
|
|
70
|
+
* You can change these at any point in time to invalidate all existing cookies.
|
|
71
|
+
* This will force all users to have to log in again.
|
|
72
|
+
*
|
|
73
|
+
* @since 2.6.0
|
|
74
|
+
*/
|
|
75
|
+
define('AUTH_KEY', get_env_var('AUTH_KEY', 'no secret provided'));
|
|
76
|
+
define('SECURE_AUTH_KEY', get_env_var('SECURE_AUTH_KEY', 'no secret provided'));
|
|
77
|
+
define('LOGGED_IN_KEY', get_env_var('LOGGED_IN_KEY', 'no secret provided'));
|
|
78
|
+
define('NONCE_KEY', get_env_var('NONCE_KEY', 'no secret provided'));
|
|
79
|
+
define('AUTH_SALT', get_env_var('AUTH_SALT', 'no secret provided'));
|
|
80
|
+
define('SECURE_AUTH_SALT', get_env_var('SECURE_AUTH_SALT', 'no secret provided'));
|
|
81
|
+
define('LOGGED_IN_SALT', get_env_var('LOGGED_IN_SALT', 'no secret provided'));
|
|
82
|
+
define('NONCE_SALT', get_env_var('NONCE_SALT', 'no secret provided'));
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
$scheme = isset( $_SERVER['HTTPS'] ) && '1' === (string) $_SERVER['HTTPS'] ? "https://" : "http://";
|
|
86
|
+
|
|
87
|
+
if (!defined('WP_HOME')) {
|
|
88
|
+
define( 'WP_HOME', isset($_SERVER['HTTP_HOST']) ? ($scheme . $_SERVER['HTTP_HOST'] ): "http://localhost");
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
define( 'WP_SITEURL', WP_HOME . '/' );
|
|
92
|
+
|
|
93
|
+
define( 'WP_MEMORY_LIMIT', '256M' );
|
|
94
|
+
define( 'WP_MAX_MEMORY_LIMIT', '256M' );
|
|
95
|
+
define( 'WP_POST_REVISIONS', false );
|
|
96
|
+
|
|
97
|
+
/**#@-*/
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* WordPress database table prefix.
|
|
101
|
+
*
|
|
102
|
+
* You can have multiple installations in one database if you give each
|
|
103
|
+
* a unique prefix. Only numbers, letters, and underscores please!
|
|
104
|
+
*/
|
|
105
|
+
$table_prefix = 'wp_';
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* For developers: WordPress debugging mode.
|
|
109
|
+
*
|
|
110
|
+
* Change this to true to enable the display of notices during development.
|
|
111
|
+
* It is strongly recommended that plugin and theme developers use WP_DEBUG
|
|
112
|
+
* in their development environments.
|
|
113
|
+
*
|
|
114
|
+
* For information on other constants that can be used for debugging,
|
|
115
|
+
* visit the documentation.
|
|
116
|
+
*
|
|
117
|
+
* @link https://wordpress.org/support/article/debugging-in-wordpress/
|
|
118
|
+
*/
|
|
119
|
+
define( 'WP_DEBUG', false );
|
|
120
|
+
|
|
121
|
+
/* Add any custom values between this line and the "stop editing" line. */
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
/* That's all, stop editing! Happy publishing. */
|
|
126
|
+
|
|
127
|
+
/** Absolute path to the WordPress directory. */
|
|
128
|
+
if ( ! defined( 'ABSPATH' ) ) {
|
|
129
|
+
define( 'ABSPATH', __DIR__ . '/' );
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
/** Sets up WordPress vars and included files. */
|
|
133
|
+
require_once ABSPATH . 'wp-settings.php';
|